I followed the instructions for installing mayavi via pip here: http://docs.enthought.com/mayavi/mayavi/installation.html#installing-with-pip. I ran into an issue that I could not solve from any of the available guides and so have turned to the issue tracker.
I am using Python 3.5, Anaconda distribution.
I have installed VTK and PyQt5 (and also tried PyQt4) from wheel, but each time after running the "pip install mayavi", an error occurs (see below). It seems that there may be an issue with VTK, but it appears to be installed correctly.
Any help or insights would be greatly appreciated!
C:\Users\edsun>pip install mayavi
Collecting mayavi
Using cached https://files.pythonhosted.org/packages/08/ea/eb808cb4df8f92bc4d9f9a1ef14566b9b5d60370e6ecbaf9061cdae335fa/mayavi-4.7.1.tar.bz2
Requirement already satisfied: apptools in c:\users\edsun\anaconda3\libsite-packages (from mayavi)
Requirement already satisfied: envisage in c:\users\edsun\anaconda3\libsite-packages (from mayavi)
Requirement already satisfied: numpy in c:\users\edsun\anaconda3\libsite-packages (from mayavi)
Requirement already satisfied: pyface>=6.1.1 in c:\users\edsun\anaconda3\libsite-packages (from mayavi)
Requirement already satisfied: pygments in c:\users\edsun\anaconda3\libsite-packages (from mayavi)
Requirement already satisfied: traits>=4.6.0 in c:\users\edsun\anaconda3\libsite-packages (from mayavi)
Requirement already satisfied: traitsui>=6.0.0 in c:\users\edsun\anaconda3\libsite-packages (from mayavi)
Requirement already satisfied: vtk in c:\users\edsun\anaconda3\libsite-packages (from mayavi)
Requirement already satisfied: configobj in c:\users\edsun\anaconda3\libsite-packages (from apptools->mayavi)
Requirement already satisfied: six in c:\users\edsun\anaconda3\libsite-packages (from apptools->mayavi)
Requirement already satisfied: setuptools in c:\users\edsun\anaconda3\libsite-packages (from envisage->mayavi)
Building wheels for collected packages: mayavi
Running setup.py bdist_wheel for mayavi ... error
Complete output from command c:\users\edsun\anaconda3\python.exe -u -c "import setuptools, tokenize;__file__='C:\Users\edsun\AppData\Local\Temp\pip-build-s8ei7q_l\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\edsunAppData\Local\Temp\tmpijq17cq5pip-wheel- --python-tag cp35:
running bdist_wheel
running build
----------------------------------------------------------------------
Building TVTK classes... vtkContextDevice2D: Ignoring method: Get/SetViewportSize
default: [-662171280, 542], range: None
vtkContextDevice2D: Ignoring method: Get/SetViewportRect
default: [-662163184, 542, -662163240, 542], range: None
vtkEventDataForDevice: Ignoring method: Get/SetAction
default: -1, range: None
vtkEventDataForDevice: Ignoring method: Get/SetDevice
default: -1, range: None
vtkFXAAOptions: Ignoring method: Get/SetDebugOptionValue
default: 0, range: None
vtkIncrementalForceLayout: Ignoring method: Get/SetGravityPoint
default: [200.0, 200.0], range: None
vtkOpenGLBufferObject: Ignoring method: Get/SetType
default: 0, range: None
vtkOpenGLFXAAFilter: Ignoring method: Get/SetDebugOptionValue
default: 0, range: None
vtkRenderWidget: Ignoring method: Get/SetPosition
default: [0, 0], range: None
vtkRenderWidget: Ignoring method: Get/SetSize
default: [300, 300], range: None
vtkShader: Ignoring method: Get/SetType
default: 3, range: None
vtkVolumeTexture: Ignoring method: Get/SetPartitions
default: [1, 1, 1], range: None
vtkChartMatrix: Ignoring method: Get/SetGutter
default: [15.0, 15.0], range: None
vtkChartMatrix: Ignoring method: Get/SetSize
default: [0, 0], range: None
vtkContextArea: Ignoring method: Get/SetDrawAreaBounds
default: [0.0, 0.0, 300.0, 300.0], range: None
vtkContextArea: Ignoring method: Get/SetFixedMargins
default: [0, 0, 0, 0], range: None
vtkContextArea: Ignoring method: Get/SetDrawAreaResizeBehavior
default: 0, range: None
vtkContextArea: Ignoring method: Get/SetGeometry
default: [0, 0, 300, 300], range: None
vtkContextArea: Ignoring method: Get/SetFixedRect
default: [0, 0, 300, 300], range: None
vtkImplicitProjectOnPlaneDistance: Ignoring method: Get/SetNorm
default: 2, range: None
vtkOpenGLVertexBufferObject: Ignoring method: Get/SetCoordShiftAndScaleMethod
default: 0, range: None
vtkSimple3DCirclesStrategy: Ignoring method: Get/SetMarkedValue
default: (invalid), range: None
vtkArrayNorm: Ignoring method: Get/SetWindow
default: [0, 9223372036854775807), range: None
vtkChart: Ignoring method: Get/SetSize
default: [0.0, 0.0, 0.0, 0.0], range: None
vtkChartXYZ: Ignoring method: Get/SetAxisColor
default: [0, 0, 0, 255], range: None
Warning: We cannot determine the trait type of vtkHigherOrderHexahedron.Order
Warning: We cannot determine the trait type of vtkHigherOrderQuadrilateral.Order
----------------------------------------
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
Complete output from command c:\users\edsun\anaconda3\python.exe -u -c "import setuptools, tokenize;__file__='C:\Users\edsun\AppData\Local\Temp\pip-build-s8ei7q_l\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\edsunAppData\Local\Temp\pip-h5cqrm0n-record\install-record.txt --single-version-externally-managed --compile:
running install
running build
----------------------------------------------------------------------
Building TVTK classes... vtkContextDevice2D: Ignoring method: Get/SetViewportSize
default: [-117098928, 515], range: None
vtkContextDevice2D: Ignoring method: Get/SetViewportRect
default: [-117100328, 515, -117108368, 515], range: None
vtkEventDataForDevice: Ignoring method: Get/SetDevice
default: -1, range: None
vtkEventDataForDevice: Ignoring method: Get/SetAction
default: -1, range: None
vtkFXAAOptions: Ignoring method: Get/SetDebugOptionValue
default: 0, range: None
vtkIncrementalForceLayout: Ignoring method: Get/SetGravityPoint
default: [200.0, 200.0], range: None
vtkOpenGLBufferObject: Ignoring method: Get/SetType
default: 0, range: None
vtkOpenGLFXAAFilter: Ignoring method: Get/SetDebugOptionValue
default: 0, range: None
vtkRenderWidget: Ignoring method: Get/SetPosition
default: [0, 0], range: None
vtkRenderWidget: Ignoring method: Get/SetSize
default: [300, 300], range: None
vtkShader: Ignoring method: Get/SetType
default: 3, range: None
vtkVolumeTexture: Ignoring method: Get/SetPartitions
default: [1, 1, 1], range: None
vtkChartMatrix: Ignoring method: Get/SetSize
default: [0, 0], range: None
vtkChartMatrix: Ignoring method: Get/SetGutter
default: [15.0, 15.0], range: None
vtkContextArea: Ignoring method: Get/SetDrawAreaBounds
default: [0.0, 0.0, 300.0, 300.0], range: None
vtkContextArea: Ignoring method: Get/SetFixedMargins
default: [0, 0, 0, 0], range: None
vtkContextArea: Ignoring method: Get/SetDrawAreaResizeBehavior
default: 0, range: None
vtkContextArea: Ignoring method: Get/SetGeometry
default: [0, 0, 300, 300], range: None
vtkContextArea: Ignoring method: Get/SetFixedRect
default: [0, 0, 300, 300], range: None
vtkImplicitProjectOnPlaneDistance: Ignoring method: Get/SetNorm
default: 2, range: None
vtkOpenGLVertexBufferObject: Ignoring method: Get/SetCoordShiftAndScaleMethod
default: 0, range: None
vtkSimple3DCirclesStrategy: Ignoring method: Get/SetMarkedValue
default: (invalid), range: None
vtkArrayNorm: Ignoring method: Get/SetWindow
default: [0, 9223372036854775807), range: None
vtkChart: Ignoring method: Get/SetSize
default: [0.0, 0.0, 0.0, 0.0], range: None
vtkChartXYZ: Ignoring method: Get/SetAxisColor
default: [0, 0, 0, 255], range: None
Warning: We cannot determine the trait type of vtkHigherOrderHexahedron.Order
Warning: We cannot determine the trait type of vtkHigherOrderQuadrilateral.Order
----------------------------------------
Command "c:\users\edsun\anaconda3\python.exe -u -c "import setuptools, tokenize;__file__='C:\Users\edsun\AppData\Local\Temp\pip-build-s8ei7q_l\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\edsunAppData\Local\Temp\pip-h5cqrm0n-record\install-record.txt --single-version-externally-managed --compile" failed with error code 3221225477 in C:\Users\edsunAppData\Local\Temp\pip-build-s8ei7q_l\mayavi\
You are using pip version 9.0.1, however version 20.1.1 is available.
You should consider upgrading via the 'python -m pip install --upgrade pip' command.
Can you tell us what version of vtk
you are using in your python environment? It looks like vtk
was preinstalled in the environment using conda but the version wasn't reported in the logs you posted.
Requirement already satisfied: vtk in c:\users\edsun\anaconda3\lib\site-packages (from mayavi)
This looks a lot like #939 - mayavi 4.7.2 does not seem to work with vtk 9 at the moment.
Also, given that you are working in a conda python environment, can you tell us what happens if you try using conda to install mayavi instead of using pip?
Great, I think that was the problem!
I installed VTK 8.1.0 using "pip install vtk==8.1.0" and then mayavi installed smoothly!
Thanks!
Most helpful comment
Great, I think that was the problem!
I installed VTK 8.1.0 using "pip install vtk==8.1.0" and then mayavi installed smoothly!
Thanks!