question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

`pip install lightning-flash[image]` results in torch downgrade to 1.8.1

See original GitHub issue

🐛 Bug

One of the dependencies of lightning-flash requires torch version <= 1.7.1, this is untenable for my use case and really needs to be fixed. I believe it’s an issue with icevision. As you can see icevision requires torch version strictly less than 1.9.

To Reproduce

Have torch > 1.9 installed in a conda environment. Attempt to install lightning-flash[image]. Obeserve at some point pip attempting to downgrade torch. This has now occurred on two separate machines with separate architectures, which isn’t a huge issue on Linux (my requirement of 1.9 is on Windows), but on Windows it replaces the GPU version of pytorch with the CPU version.

Environment

  • PyTorch Version (e.g., 1.0): 1.9
  • OS (e.g., Linux): Linux + Windows
  • How you installed PyTorch (conda, pip, source): conda
  • Build command you used (if compiling from source):
  • Python version: 3.7 and 3.8

Additional context

I can trick it a bit if I install it with no dependencies. This is what I’ve had to do and then manually install each missing package as it comes up.

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:5 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
ethanwharriscommented, Sep 8, 2021

Hi @dlangerm whoops, meant to close this issue. IceVision is now a fully optional dependency in flash 0.5.0 😃 only required for the IceVision based tasks (object detection, keypoint detection, and instance segmentation).

1reaction
ethanwharriscommented, Aug 31, 2021

Hi @dlangerm thanks for reporting this! Yeah, this seems to be caused by the install of icevision. I think we can do a small refactor here to make this work, just move icevision to a fully optional dependency for a handful of tasks.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Previous PyTorch Versions
An open source machine learning framework that accelerates the path from research prototyping to production deployment.
Read more >
How to install older version of pytorch - python - Stack Overflow
pip install torch == Collecting torch== ... You can download the specific version (wheels seem available) and install it with pip install.
Read more >
Safely downgrade Pytorch from 1.9 to 1.8 : r/GoogleColab
Can somebody please tell me how to downgrade the Colab version of ... !pip install torch==1.8.1 torchvision==0.9.1 torchtext==0.9.1 -f ...
Read more >
Cannot install through pip (downgrades PyTorch) · Issue #3323
When installing fastai using pip the installed version of PyTorch gets downgraded, and then the installation fails because the version is too ...
Read more >
Installation — PyTorch Lightning 1.8.5.post0 documentation
Use pip install lightning instead. Apple Silicon (M1/M2/M3) Macs. While ML related python packages are updated to work with Apple Silicon, you ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found