KitwareMedical / VTKPythonPackage

A setup script to generate VTK Python Wheels
https://vtkpythonpackage.readthedocs.io
BSD 3-Clause "New" or "Revised" License
35 stars 15 forks source link

The differences between VTK Python Wrapper and VTKPythonPackage. #43

Open hongyi-zhao opened 4 years ago

hongyi-zhao commented 4 years ago

Hi,

What's the differences between VTK Python Wrapper and VTKPythonPackage?

Regards, HY

jcfr commented 4 years ago

This project was created before we updated VTK to official support build python wheel. See https://github.com/Kitware/VTK/blob/master/Documentation/dev/build.md#python-wheels

As soon as we are done addressing issue https://gitlab.kitware.com/vtk/vtk/-/issues/17695 we will update this repository adding an history section.

In the meantime, you should be able to pip install vtk

Let me know if you have any other questions,

hongyi-zhao commented 4 years ago

This project was created before we updated VTK to official support build python wheel. See https://github.com/Kitware/VTK/blob/master/Documentation/dev/build.md#python-wheels

I noticed that the original vtk repo is located here: https://gitlab.kitware.com/vtk/vtk While its github mirror is the following: https://github.com/Kitware/VTK

Why the former use lowercase repo name, while the latter use uppercase?

As soon as we are done addressing issue https://gitlab.kitware.com/vtk/vtk/-/issues/17695 we will update this repository adding an history section.

In the meantime, you should be able to pip install vtk

My environment is Ubuntu 20.04 and Python 3.8.3 (managed by pyenv). I try to run the above command but failed. See the following for more info:

$ pyenv shell 3.8.3
$ pyenv virtualenv vtk
$ pyenv shell vtk
$ pip install -U pip
$ pip install vtk
Looking in indexes: https://pypi.tuna.tsinghua.edu.cn/simple
ERROR: Could not find a version that satisfies the requirement vtk (from versions: none)
ERROR: No matching distribution found for vtk

On the other hand, I want to install mayavi which is based on vtk. So I must compile and install vtk from source manually.

Any hints for this problem?

Regards, HY

Let me know if you have any other questions,

jcfr commented 4 years ago

Why the former use lowercase repo name, while the latter use uppercase?

This is how gitlab handle URLs, the name of the project is VTK

linux wheel

We are actively working on addressing https://gitlab.kitware.com/vtk/vtk/-/issues/17695

Once this is done, wheels for python 3.8 will be available.

In the mean time, you could build the wheel locally following: https://github.com/Kitware/VTK/blob/master/Documentation/dev/build.md#python-wheels

That said, I suggest you wait as we will update the instruction to include more details.

hongyi-zhao commented 4 years ago

Why the former use lowercase repo name, while the latter use uppercase?

This is how gitlab handle URLs, the name of the project is VTK

Do you mean gitlab handle URLs in a case-insensitive manner?

jcfr commented 4 years ago

It looks gitlab handle URL in lowercase.

https://gitlab.kitware.com/vtk/VTK redirects to https://gitlab.kitware.com/vtk/vtk

hongyi-zhao commented 4 years ago

Thanks for your clarification. But IMO, use all lowercase in URL is not a bad idea for most cases.

Although some HTTP servers can distinguish case, no one will create two different projects with one named as AAa, and the other names as aAa.