I can not install VTK by anaconda in Mac OS X. I use
conda install -c anaconda vtk=6.3.0
Python 2.7 but get the following error:
UnsatisfiableError: The following specifications were found to be in conflict: - python 3.6* - vtk 6.3.0* -> python 2.7* -> openssl 1.0.1* Use "conda info " to see the dependencies for each package.
But I've updated Python to 3.6, and the same error.
$ conda search vtk
Fetching package metadata ...........
vtk 5.10.1 py27_0 defaults
5.10.1 py27_1 defaults
6.3.0 py27_0 defaults
6.3.0 py27_1 defaults
$ conda create -n vtk python=2.7 vtk=6.3.0
Fetching package metadata ...........
Solving package specifications: .
Package plan for installation in environment /home/sidon/opt/anaconda3/envs/vtk:
The following NEW packages will be INSTALLED:
openssl: 1.0.2k-1
pip: 9.0.1-py27_1
python: 2.7.13-0
readline: 6.2-2
setuptools: 27.2.0-py27_0
sqlite: 3.13.0-0
tk: 8.5.18-0
vtk: 6.3.0-py27_1
wheel: 0.29.0-py27_0
zlib: 1.2.8-3
Proceed ([y]/n)? y
vtk-6.3.0-py27 100% |#############################################################################################| Time: 0:00:15 1.97 MB/s
#
# To activate this environment, use:
# > source activate vtk
#
# To deactivate this environment, use:
# > source deactivate vtk
#
$ source activate vtk
$ python -c "import vtk; print vtk.vtkSphereSource()"
vtkSphereSource (0xcfdcc0)
Debug: Off
Modified Time: 39
Reference Count: 2
Registered Events: (none)
Executive: 0xae5e00
ErrorCode: Success
Information: 0xf6e210
AbortExecute: Off
Progress: 0
Progress Text: (None)
Theta Resolution: 8
Phi Resolution: 8
Theta Start: 0
Phi Start: 0
Theta End: 360
Phi End: 180
Radius: 0.5
Center: (0, 0, 0)
LatLong Tessellation: 0
Output Points Precision: 0
I would suggest installing directly from the wheel file. You can get the VTK wheel file from here ( wheel file directory site ). This site has pretty much every wheel file so it is your friend! just search for it and you will see a bunch of .whl
VTK files.
just download the wheel file that matches your anaconda python root version (either 3.5, 3.6, 2.7 etc.) and either 32 or 64 bit (depending on your python version).
To install from a wheel file, open a terminal in the directory the wheel is in and type
pip install "your_wheel_file_name"
If you want to install it for a conda environment, just activate the environment first ( activate "env_name"
) and then install from the wheel file.
Try this out for me:
conda create --name vtk_test python=2.7 vtk
This will create a new environment with VTK, Python and their dependencies inside.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.