Open ppboyle opened 9 months ago
This a dependency compatibility issue. PyTorch, a main machine learning library, currently only supports 3.11.
I have this issue too on a mac. But in my case it crashes the update.
Installed Version is 3.12. Would pyenv help?
Use pyenv to install and the version of python you need, refer to your specific operating system on how to.
Make sure pyenv is enabled system wise On arch based it can be something like (from the directory where you run the application):
pyenv install 3.11.6
pyenv local 3.11.6
pyenv shell 3.11.6
python -m venv venv
On windows you can use python launcher (py.exe) to choose the version which builds the venv during the installation. The venv will use the right version of python from then on.
Edit install.bat:
@rem -------------- Install and Configure ---------------
old:
call python .\lib\main.py
new:
call py -3.11 .\lib\main.py
pause
exit /b
instead of virtualenv it would be better to revert to conda or miniconda to make it possible to have specific python install in env. i think so
instead of virtualenv it would be better to revert to conda or miniconda
What do you think conda does? It's just another way of creating a containerized environment. :)
Use what YOU feel comfortable with, the important part is you make it "containerized" so you can control what python version is used.
Use pyenv to install and the version of python you need, refer to your specific operating system on how to.
Make sure pyenv is enabled system wise On arch based it can be something like (from the directory where you run the application):
pyenv install 3.11.6 pyenv local 3.11.6 pyenv shell 3.11.6 python -m venv venv
I followed the steps on manjaro - python 3.12 before, 3.11.6 after installation. But I still get an error running the installer:
/home/leder/invokeai/.venv/bin/python: error while loading shared libraries: libpython3.11.so.1.0: cannot open shared object file: No such file or directory
Use pyenv to install and the version of python you need, refer to your specific operating system on how to. Make sure pyenv is enabled system wise On arch based it can be something like (from the directory where you run the application):
pyenv install 3.11.6 pyenv local 3.11.6 pyenv shell 3.11.6 python -m venv venv
I followed the steps on manjaro - python 3.12 before, 3.11.6 after installation. But I still get an error running the installer:
/home/leder/invokeai/.venv/bin/python: error while loading shared libraries: libpython3.11.so.1.0: cannot open shared object file: No such file or directory
same here
No you did not follow the instructions quoted here, because if you did, the path would not be a hidden directory (.venv) but rather a directory called venv.
You also have to make sure the venv is activated and in your $PATH on each reboot (in .bashrc or whever shell you use) or you have to activate the pyenv every time. Was that what you guys did? Rebooted without making sure you pyenv is available after?
Example:
export PYENV_ROOT="$HOME/.pyenv"
eval "$(pyenv init -)"
Edit
Also, the 3.11.6 was just a random example I used. Just use 3.11 instead and it will pull the latest available for you (3.11.9 IIRC)
You can remove a pyenv with pyenv uninstall x.x.x
where x is the version numbers.
It appears pytorch now supports 3.12, so you can remove the <3.11 requirement now. https://pypi.org/project/torch/#files
Is there an existing issue for this?
Contact Details
No response
What should this feature add?
Why not let your installer respect the latest python version levels, vs having a user have to download older versions?
Alternatives
No response
Additional Content
No response