Я пытался установить пакет mayavi
. Но я получаю следующий код ошибки:
Вход: pip install mayavi
Выход:
Using cached mayavi-4.7.1.tar.bz2 (7.0 MB)
Requirement already satisfied: apptools in c:\users\[user]\appdata\local\programs\python\python38\lib\site-packages (from mayavi) (4.5.0)
Requirement already satisfied: envisage in c:\users\[user]\appdata\local\programs\python\python38\lib\site-packages (from mayavi) (4.9.2)
Requirement already satisfied: numpy in c:\users\[user]\appdata\local\programs\python\python38\lib\site-packages (from mayavi) (1.19.0)
Requirement already satisfied: pyface>=6.1.1 in c:\users\[user]\appdata\local\programs\python\python38\lib\site-packages (from mayavi) (7.0.0)
Requirement already satisfied: pygments in c:\users\[user]\appdata\local\programs\python\python38\lib\site-packages (from mayavi) (2.6.1)
Requirement already satisfied: traits>=4.6.0 in c:\users\[user]\appdata\local\programs\python\python38\lib\site-packages (from mayavi) (6.1.0)
Requirement already satisfied: traitsui>=6.0.0 in c:\users\[user]\appdata\local\programs\python\python38\lib\site-packages (from mayavi) (7.0.0)
Requirement already satisfied: vtk in c:\users\[user]\appdata\local\programs\python\python38\lib\site-packages (from mayavi) (9.0.1)
Requirement already satisfied: configobj in c:\users\[user]\appdata\local\programs\python\python38\lib\site-packages (from apptools->mayavi) (5.0.6)
Requirement already satisfied: six in c:\users\[user]\appdata\local\programs\python\python38\lib\site-packages (from apptools->mayavi) (1.15.0)
Requirement already satisfied: setuptools in c:\users\[user]\appdata\local\programs\python\python38\lib\site-packages (from envisage->mayavi) (49.1.0)
Building wheels for collected packages: mayavi
Building wheel for mayavi (setup.py) ... error
ERROR: Command errored out with exit status 3221225477:
command: 'c:\users\[user]\appdata\local\programs\python\python38\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\[user]\\AppData\\Local\\Temp\\pip-install-9m9ho30d\\mayavi\\setup.py'"'"'; __file__='"'"'C:\\Users\\[user]\\AppData\\Local\\Temp\\pip-install-9m9ho30d\\mayavi\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' bdist_wheel -d 'C:\Users\[user]\AppData\Local\Temp\pip-wheel-nbag40lo'
cwd: C:\Users\[user]\AppData\Local\Temp\pip-install-9m9ho30d\mayavi\
Complete output (4 lines):
running bdist_wheel
running build
----------------------------------------------------------------------
Building TVTK classes...
----------------------------------------
ERROR: Failed building wheel for mayavi
Running setup.py clean for mayavi
Failed to build mayavi
Installing collected packages: mayavi
Running setup.py install for mayavi ... error
ERROR: Command errored out with exit status 3221225477:
command: 'c:\users\[user]\appdata\local\programs\python\python38\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\[user]\\AppData\\Local\\Temp\\pip-install-9m9ho30d\\mayavi\\setup.py'"'"'; __file__='"'"'C:\\Users\\[user]\\AppData\\Local\\Temp\\pip-install-9m9ho30d\\mayavi\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record 'C:\Users\[user]\AppData\Local\Temp\pip-record-y6i7mpay\install-record.txt' --single-version-externally-managed --compile --install-headers 'c:\users\[user]\appdata\local\programs\python\python38\Include\mayavi'
cwd: C:\Users\[user]\AppData\Local\Temp\pip-install-9m9ho30d\mayavi\
Complete output (4 lines):
running install
running build
----------------------------------------------------------------------
Building TVTK classes...
----------------------------------------
ERROR: Command errored out with exit status 3221225477: 'c:\users\[user]\appdata\local\programs\python\python38\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\[user]\\AppData\\Local\\Temp\\pip-install-9m9ho30d\\mayavi\\setup.py'"'"'; __file__='"'"'C:\\Users\\[user]\\AppData\\Local\\Temp\\pip-install-9m9ho30d\\mayavi\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record 'C:\Users\[user]\AppData\Local\Temp\pip-record-y6i7mpay\install-record.txt' --single-version-externally-managed --compile --install-headers 'c:\users\[user]\appdata\local\programs\python\python38\Include\mayavi' Check the logs for full command output.
В более старом вопросе ( setup.py egg_info error code 3221225477 ) Я обнаружил, что эта «ошибка означает ошибку или несовместимость между некоторыми из моих установленных модулей расширения». Но я убедился, что все мои расширения устанавливаются только в индивидуальном, а не в общесистемном каталоге.
Я также обновил все пакеты до последней версии.
EDIT:
- Я установил Python 3,7 (ранее было 3,8), но ошибка не исчезла.
- Я пробовал это с подсистемой Windows для Linux, но все равно получил ту же ошибку
- Я наконец решил это, используя conda с Python 3,7