UKPLab / sentence-transformers

State-of-the-Art Text Embeddings
https://www.sbert.net
Apache License 2.0
15.41k stars 2.49k forks source link

Error installing sentence-transformers with pip in Windows 10 pycharm professional-> Error: Dependencies conflicts most probobly #3077

Closed Umais-Adeed closed 3 days ago

Umais-Adeed commented 3 days ago

i think its some dependencies error pip is unable to find the specific dependency for the sentence-transformers in there

pip install sentence_transformers Collecting sentence_transformers Using cached sentence_transformers-3.3.1-py3-none-any.whl.metadata (10 kB) Collecting transformers<5.0.0,>=4.41.0 (from sentence_transformers) Using cached transformers-4.46.3-py3-none-any.whl.metadata (44 kB) Requirement already satisfied: tqdm in python\python313\lib\site-packages (from sentence_transformers) (4.67.0) INFO: pip is looking at multiple versions of sentence-transformers to determine which version is compatible with other requirements. This could take a while. Collecting sentence_transformers Using cached sentence_transformers-3.3.0-py3-none-any.whl.metadata (10 kB) Using cached sentence_transformers-3.2.1-py3-none-any.whl.metadata (10 kB) Using cached sentence_transformers-3.2.0-py3-none-any.whl.metadata (10 kB) Using cached sentence_transformers-3.1.1-py3-none-any.whl.metadata (10 kB) Using cached sentence_transformers-3.1.0-py3-none-any.whl.metadata (23 kB) Using cached sentence_transformers-3.0.1-py3-none-any.whl.metadata (10 kB) Using cached sentence_transformers-3.0.0-py3-none-any.whl.metadata (10 kB) INFO: pip is still looking at multiple versions of sentence-transformers to determine which version is compatible with other requirements. This could take a while. Using cached sentence_transformers-2.7.0-py3-none-any.whl.metadata (11 kB) Using cached sentence_transformers-2.6.1-py3-none-any.whl.metadata (11 kB) Using cached sentence_transformers-2.6.0-py3-none-any.whl.metadata (11 kB) Using cached sentence_transformers-2.5.1-py3-none-any.whl.metadata (11 kB) Using cached sentence_transformers-2.5.0-py3-none-any.whl.metadata (11 kB) INFO: This is taking longer than usual. You might need to provide the dependency resolver with stricter constraints to reduce runtime. See https://pip.pypa.io/warnings/backtracking for guidance. If you want to abort this run, press Ctrl + C. Using cached sentence_transformers-2.4.0-py3-none-any.whl.metadata (11 kB) Using cached sentence_transformers-2.3.1-py3-none-any.whl.metadata (11 kB) Using cached sentence_transformers-2.3.0-py3-none-any.whl.metadata (11 kB) Using cached sentence-transformers-2.2.2.tar.gz (85 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Using cached sentence-transformers-2.2.1.tar.gz (84 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Using cached sentence-transformers-2.2.0.tar.gz (79 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Using cached sentence-transformers-2.1.0.tar.gz (78 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Collecting tokenizers>=0.10.3 (from sentence_transformers) Using cached tokenizers-0.20.3-cp313-none-win_amd64.whl.metadata (6.9 kB) Collecting sentence_transformers Using cached sentence-transformers-2.0.0.tar.gz (85 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Using cached sentence-transformers-1.2.1.tar.gz (80 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Using cached sentence-transformers-1.2.0.tar.gz (81 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Using cached sentence-transformers-1.1.1.tar.gz (81 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Using cached sentence-transformers-1.1.0.tar.gz (78 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Using cached sentence-transformers-1.0.4.tar.gz (74 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Using cached sentence-transformers-1.0.3.tar.gz (74 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Using cached sentence-transformers-1.0.2.tar.gz (74 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Using cached sentence-transformers-1.0.1.tar.gz (74 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Using cached sentence-transformers-1.0.0.tar.gz (74 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Using cached sentence-transformers-0.4.1.2.tar.gz (64 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Using cached sentence-transformers-0.4.1.1.tar.gz (64 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Using cached sentence-transformers-0.4.1.tar.gz (64 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Using cached sentence-transformers-0.4.0.tar.gz (65 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Using cached sentence-transformers-0.3.9.tar.gz (64 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Collecting transformers<3.6.0,>=3.1.0 (from sentence_transformers) Using cached transformers-3.5.1-py3-none-any.whl.metadata (32 kB) Collecting sentence_transformers Using cached sentence-transformers-0.3.8.tar.gz (66 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Collecting transformers<3.4.0,>=3.1.0 (from sentence_transformers) Using cached transformers-3.3.1-py3-none-any.whl.metadata (29 kB) Collecting sentence_transformers Using cached sentence-transformers-0.3.7.2.tar.gz (59 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Using cached sentence-transformers-0.3.7.1.tar.gz (59 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Using cached sentence-transformers-0.3.7.tar.gz (59 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Using cached sentence-transformers-0.3.6.tar.gz (62 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Collecting transformers<3.2.0,>=3.1.0 (from sentence_transformers) Using cached transformers-3.1.0-py3-none-any.whl.metadata (49 kB) Collecting sentence_transformers Using cached sentence-transformers-0.3.5.1.tar.gz (61 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Collecting transformers==3.0.2 (from sentence_transformers) Using cached transformers-3.0.2-py3-none-any.whl.metadata (44 kB) Collecting sentence_transformers Using cached sentence-transformers-0.3.5.tar.gz (61 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Using cached sentence-transformers-0.3.4.tar.gz (61 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Using cached sentence-transformers-0.3.3.tar.gz (65 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Using cached sentence-transformers-0.3.2.tar.gz (65 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Using cached sentence-transformers-0.3.1.tar.gz (64 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Using cached sentence-transformers-0.3.0.tar.gz (61 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Using cached sentence-transformers-0.2.6.2.tar.gz (60 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Collecting transformers==2.11.0 (from sentence_transformers) Using cached transformers-2.11.0-py3-none-any.whl.metadata (45 kB) Collecting sentence_transformers Using cached sentence-transformers-0.2.6.1.tar.gz (55 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Using cached sentence-transformers-0.2.5.1.tar.gz (52 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Collecting transformers==2.3.0 (from sentence_transformers) Using cached transformers-2.3.0-py3-none-any.whl.metadata (38 kB) Collecting sentence_transformers Using cached sentence-transformers-0.2.5.tar.gz (49 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Using cached sentence-transformers-0.2.4.1.tar.gz (49 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Collecting transformers==2.2.1 (from sentence_transformers) Using cached transformers-2.2.1-py3-none-any.whl.metadata (33 kB) Collecting sentence_transformers Using cached sentence-transformers-0.2.4.tar.gz (49 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Using cached sentence-transformers-0.2.3.tar.gz (45 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Collecting pytorch-transformers==1.1.0 (from sentence_transformers) Using cached pytorch_transformers-1.1.0-py3-none-any.whl.metadata (21 kB) Collecting sentence_transformers Using cached sentence-transformers-0.2.2.tar.gz (44 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Using cached sentence-transformers-0.2.1.tar.gz (42 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Collecting pytorch-transformers==1.0.0 (from sentence_transformers) Using cached pytorch_transformers-1.0.0-py3-none-any.whl.metadata (19 kB) Collecting sentence_transformers Using cached sentence-transformers-0.2.0.tar.gz (28 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Using cached sentence-transformers-0.1.0.tar.gz (35 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done ERROR: Cannot install sentence-transformers==0.1.0, sentence-transformers==0.2.0, sentence-transformers==0.2.1, sentence-transformers==0.2.2, sentence-transfo rmers==0.2.3, sentence-transformers==0.2.4, sentence-transformers==0.2.4.1, sentence-transformers==0.2.5, sentence-transformers==0.2.5.1, sentence-transformer s==0.2.6.1, sentence-transformers==0.2.6.2, sentence-transformers==0.3.0, sentence-transformers==0.3.1, sentence-transformers==0.3.2, sentence-transformers==0 .3.3, sentence-transformers==0.3.4, sentence-transformers==0.3.5, sentence-transformers==0.3.5.1, sentence-transformers==0.3.6, sentence-transformers==0.3.7, sentence-transformers==0.3.7.1, sentence-transformers==0.3.7.2, sentence-transformers==0.3.8, sentence-transformers==0.3.9, sentence-transformers==0.4.0, sent ence-transformers==0.4.1, sentence-transformers==0.4.1.1, sentence-transformers==0.4.1.2, sentence-transformers==1.0.0, sentence-transformers==1.0.1, sentence -transformers==1.0.2, sentence-transformers==1.0.3, sentence-transformers==1.0.4, sentence-transformers==1.1.0, sentence-transformers==1.1.1, sentence-transfo rmers==1.2.0, sentence-transformers==1.2.1, sentence-transformers==2.0.0, sentence-transformers==2.1.0, sentence-transformers==2.2.0, sentence-transformers==2 .2.1, sentence-transformers==2.2.2, sentence-transformers==2.3.0, sentence-transformers==2.3.1, sentence-transformers==2.4.0, sentence-transformers==2.5.0, se ntence-transformers==2.5.1, sentence-transformers==2.6.0, sentence-transformers==2.6.1, sentence-transformers==2.7.0, sentence-transformers==3.0.0, sentence-t ransformers==3.0.1, sentence-transformers==3.1.0, sentence-transformers==3.1.1, sentence-transformers==3.2.0, sentence-transformers==3.2.1, sentence-transformers==3.3.0 and sentence-transformers==3.3.1 because these package versions have conflicting dependencies.

The conflict is caused by: sentence-transformers 3.3.1 depends on torch>=1.11.0 sentence-transformers 3.3.0 depends on torch>=1.11.0 sentence-transformers 3.2.1 depends on torch>=1.11.0 sentence-transformers 3.2.0 depends on torch>=1.11.0 sentence-transformers 3.1.1 depends on torch>=1.11.0 sentence-transformers 3.1.0 depends on torch>=1.11.0 sentence-transformers 3.0.1 depends on torch>=1.11.0 sentence-transformers 3.0.0 depends on torch>=1.11.0 sentence-transformers 2.7.0 depends on torch>=1.11.0 sentence-transformers 2.6.1 depends on torch>=1.11.0 sentence-transformers 2.6.0 depends on torch>=1.11.0 sentence-transformers 2.5.1 depends on torch>=1.11.0 sentence-transformers 2.5.0 depends on torch>=1.11.0 sentence-transformers 2.4.0 depends on torch>=1.11.0 sentence-transformers 2.3.1 depends on torch>=1.11.0 sentence-transformers 2.3.0 depends on torch>=1.11.0 sentence-transformers 2.2.2 depends on torch>=1.6.0 sentence-transformers 2.2.1 depends on torch>=1.6.0 sentence-transformers 2.2.0 depends on torch>=1.6.0 sentence-transformers 2.1.0 depends on torch>=1.6.0 sentence-transformers 2.0.0 depends on torch>=1.6.0 sentence-transformers 1.2.1 depends on torch>=1.6.0 sentence-transformers 1.2.0 depends on torch>=1.6.0 sentence-transformers 1.1.1 depends on torch>=1.6.0 sentence-transformers 1.1.0 depends on torch>=1.6.0 sentence-transformers 1.0.4 depends on torch>=1.6.0 sentence-transformers 1.0.3 depends on torch>=1.6.0 sentence-transformers 1.0.2 depends on torch>=1.6.0 sentence-transformers 1.0.1 depends on torch>=1.6.0 sentence-transformers 1.0.0 depends on torch>=1.6.0 sentence-transformers 0.4.1.2 depends on torch>=1.6.0 sentence-transformers 0.4.1.1 depends on torch>=1.6.0 sentence-transformers 0.4.1 depends on torch>=1.6.0 sentence-transformers 0.4.0 depends on torch>=1.6.0 sentence-transformers 0.3.9 depends on torch>=1.6.0 sentence-transformers 0.3.8 depends on torch>=1.2.0 sentence-transformers 0.3.7.2 depends on torch>=1.2.0 sentence-transformers 0.3.7.1 depends on torch>=1.2.0 sentence-transformers 0.3.7 depends on torch>=1.2.0 sentence-transformers 0.3.6 depends on torch>=1.2.0 sentence-transformers 0.3.5.1 depends on torch>=1.2.0 sentence-transformers 0.3.5 depends on torch>=1.2.0 sentence-transformers 0.3.4 depends on torch>=1.2.0 sentence-transformers 0.3.3 depends on torch>=1.2.0 sentence-transformers 0.3.2 depends on torch>=1.2.0 sentence-transformers 0.3.1 depends on torch>=1.2.0 sentence-transformers 0.3.0 depends on torch>=1.0.1 sentence-transformers 0.2.6.2 depends on torch>=1.0.1 sentence-transformers 0.2.6.1 depends on torch>=1.0.1 sentence-transformers 0.2.5.1 depends on torch>=1.0.1 sentence-transformers 0.2.5 depends on torch>=1.0.1 sentence-transformers 0.2.4.1 depends on torch>=1.0.1 sentence-transformers 0.2.4 depends on torch>=1.0.1 sentence-transformers 0.2.3 depends on torch>=1.0.1 sentence-transformers 0.2.2 depends on torch>=1.0.1 sentence-transformers 0.2.1 depends on torch>=1.0.1 sentence-transformers 0.2.0 depends on torch>=1.0.1 sentence-transformers 0.1.0 depends on torch>=1.0.1

To fix this you could try to:

  1. loosen the range of package versions you've specified
  2. remove package versions to allow pip to attempt to solve the dependency conflict

ERROR: ResolutionImpossible: for help visit https://pip.pypa.io/en/latest/topics/dependency-resolution/#dealing-with-dependency-conflicts

tomaarsen commented 3 days ago

Hello!

Hmm, that is quite odd. Do you perhaps have a very old torch or something? Does this dependency conflict also happen in a fresh virtualenvironment?

Umais-Adeed commented 3 days ago

Hello @tomaarsen ,

Thank you for your response. I appreciate your assistance with this matter.

I have been attempting to resolve this issue for the past few days, but unfortunately, I have been unable to install the latest version of Torch on Python 3.13. It appears that Torch may not yet support Python 3.13. If you have any suggestions or alternative solutions, they would be greatly appreciated.

Thank you once again for your help.

Best regards, Umais Adeed

tomaarsen commented 3 days ago

I see! Then my recommendation is to revert to Python 3.12. Otherwise you'll have to wait until Torch supports Python 3.13. There's not much else you can do.

Umais-Adeed commented 3 days ago

@tomaarsen Thanks for your kind time and advice really appreciate that!

Thank you once again for your help.

Best regards, Umais Adeed

Umais-Adeed commented 3 days ago

lets hope python 3.13 supports pytorch soon