Error: cannot import name 'Wav2Vec2ForMultilabelSequenceClassification' from 'transformers'

#2
by abhisheksgumadi - opened

I have the following packages installed within a Pipenv environment:

aiosignal==1.3.1
altair==5.1.2
appdirs==1.4.4
async-timeout==4.0.2
attrs==22.1.0
audioread==3.0.0
blinker==1.7.0
cachetools==5.3.2
certifi==2023.11.17
cffi==1.15.1
charset-normalizer==2.1.1
click==8.1.7
datasets==2.7.0
decorator==5.1.1
dill==0.3.6
dnspython==2.4.2
filelock==3.8.0
frozenlist==1.3.3
fsspec==2022.11.0
gitdb==4.0.11
GitPython==3.1.40
huggingface-hub==0.11.0
idna==3.4
importlib-metadata==6.8.0
Jinja2==3.1.2
joblib==1.2.0
jsonschema==4.19.2
jsonschema-specifications==2023.7.1
librosa==0.9.2
llvmlite==0.39.1
markdown-it-py==3.0.0
MarkupSafe==2.1.3
mdurl==0.1.2
mpmath==1.3.0
multidict==6.0.2
multiprocess==0.70.14
networkx==3.2.1
numba==0.56.4
numpy==1.23.5
nvidia-cublas-cu11==11.10.3.66
nvidia-cublas-cu12==12.1.3.1
nvidia-cuda-cupti-cu12==12.1.105
nvidia-cuda-nvrtc-cu11==11.7.99
nvidia-cuda-nvrtc-cu12==12.1.105
nvidia-cuda-runtime-cu11==11.7.99
nvidia-cuda-runtime-cu12==12.1.105
nvidia-cudnn-cu11==8.5.0.96
nvidia-cudnn-cu12==8.9.2.26
nvidia-cufft-cu12==11.0.2.54
nvidia-curand-cu12==10.3.2.106
nvidia-cusolver-cu12==11.4.5.107
nvidia-cusparse-cu12==12.1.0.106
nvidia-nccl-cu12==2.18.1
nvidia-nvjitlink-cu12==12.3.101
nvidia-nvtx-cu12==12.1.105
packaging==21.3
pandas==1.5.1
Pillow==10.1.0
plotly==5.18.0
pooch==1.6.0
protobuf==4.25.0
pyarrow==10.0.1
pycparser==2.21
pydeck==0.8.1b0
Pygments==2.16.1
pymongo==4.6.0
pyparsing==3.0.9
python-dateutil==2.8.2
pytz==2022.6
PyYAML==6.0
referencing==0.30.2
regex==2022.10.31
requests==2.28.1
resampy==0.4.2
responses==0.18.0
rich==13.6.0
rpds-py==0.10.6
safetensors==0.4.1
scikit-learn==1.1.3
scipy==1.9.3
sentencepiece==0.1.99
six==1.16.0
smmap==5.0.1
soundfile==0.11.0
streamlit==1.28.0
sympy==1.12
tenacity==8.2.3
threadpoolctl==3.1.0
tokenizers==0.13.2
toml==0.10.2
toolz==0.12.0
torch==1.13.0
tornado==6.3.3
tqdm==4.64.1
transformers==4.25.1
triton==2.1.0
typing_extensions==4.4.0
tzdata==2023.3
tzlocal==5.2
urllib3==1.26.12
validators==0.22.0
watchdog==3.0.0
xxhash==3.1.0
yarl==1.8.1
zipp==3.17.0```

I tried the following error for the import:

`In [1]: from transformers import AutoProcessor, Wav2Vec2ForMultilabelSequenceClassification
---------------------------------------------------------------------------
ImportError                               Traceback (most recent call last)
Cell In[1], line 1
----> 1 from transformers import AutoProcessor, Wav2Vec2ForMultilabelSequenceClassification

ImportError: cannot import name 'Wav2Vec2ForMultilabelSequenceClassification' from 'transformers' (/home/abhishek/.local/share/virtualenvs/streamlit-kDZH-UcN/lib/python3.10/site-packages/transformers/__init__.py)
`

Any suggestions on what might have gone wrong please? Thanks

@abhisheksgumadi : We extend the model class in our github repo. You can check the Wav2Vec2ForMultilabelSequenceClassification class here

Sign up or log in to comment