It looks like there is a compatibility issue with PyTorch and Python 3.10 when I want to use google Colab.
I need to use !pip install torch==1.8 torchvision==0.9 but this problem don't let me.
I should do Downgrading.
I need to get code to downgarde Python version.
Below is a method to downgrade Python. But you should note that every time you want to use the conda environment to install or work with it, you must first use this script ! source activate env_name;
or easily use %%bash
first of cells to activate it, then write the command you want exactly after this script.
! python --version
!pip install -q condacolab
import condacolab
condacolab.install()
!conda --version
you should choose a python version from the output of this code and replace to PYTHON_VERSION
in next step:
!conda search python
! conda create -n env_name python=PYTHON_VERSION # PYTHON_VERSION can be 3.9 or any other releas
you should create a requirements.txt
file and place name of all packages which you need to install on it.
! source activate env_name; python --version; pip -V; pip install -r requirements.txt
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With