NumPy dependency is lacking in the requirements.txt
See original GitHub issueHey, Marco!
First of all, great work! vedo
is amazing and it eases the pain to use VTK. Thanks!
I’m opening this issue due to a very minor problem I have faced. I tried vedo
from CLI and it complained of:
ModuleNotFoundError: No module named 'numpy'
Since you mentioned in the README.md
that vedo
is based on VTK
and numpy
, maybe including numpy
as a requirement would make sense. What do you think? Could I submit a PR?
Cheers! Diego
Steps to reproduce the problem
Below I described exactly what I did to make it reproducible if you want to check (or vedo
interested users):
OS: Ubunutu 18.04.4
Procedures: I installed vedo
in the development mode. It means that I cloned your repo and executed in an isolated env:
$ virtualenv .vedo
$ source .vedo/bin/activate
$ pip install -r requirements.txt
$ python setup.py install
Then I ran vedo
with its command-line interface:
$ vedo pore_network.vtu
The .vtu
file is attached here.
Issue Analytics
- State:
- Created 3 years ago
- Comments:5 (5 by maintainers)
Top Results From Across the Web
Dependency to numpy cannot be resolved when installing ...
My azure function is using python module pywavelets which requires dependency to numpy . Here is my requirements.txt
Read more >Why requirements.txt isn't enough - model.predict
Create a requirements.in file and list just the direct dependencies of your app. The same way you'd do with requirements.txt in Scenario #1....
Read more >User Guide - pip documentation v22.3.1
It's important to be clear that pip determines package dependencies using install_requires metadata, not by discovering requirements.txt files embedded in ...
Read more >Python Dependencies via Pip - Heroku Dev Center
To specify Python package dependencies on Heroku via pip, add a pip requirements file named requirements.txt to the root of your repository.
Read more >Pip constraints files - Blog | luminousmen
Now we can keep everything clean — just list direct dependencies in requirements.txt or setup.py , without the exact versions, and keep the ......
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Hi Diego, thanks a lot for drawing my attention to this and for the explainations! i just made a quick check (hope it makes sense) by adding the numpy in the
install_requires
then doingpip install . -U
did not mess up with the conda environment… so I suggest we add it in the setup.py only!Hmm… this is a good question. As pointed by PyPA,
install_requires
should contain only the very essential dependencies, whilerequirements.txt
can be more extensive, maybe when some dependency is useful for a subset of use cases. In my understanding (please correct me if I’m wrong),numpy
is essential forvedo
, since it can compromise a big feature ofvedo
(CLI usage). So, in this case, I think that it would be appropriate to includenumpy
in both. Well, in either way,vedo
would have only 2 dependencies, it’s still tidy and clean. Are you OK with that? Please feel free to disagree 😃Hmm! Yes, if you have conda’s python activated, and then run
pip -U
, it probably will mess with Python packages inside the conda env. But, IMHO, this is OK. Actually I think that to mix conda and pip to manage packages can be a source of problems (oh, boy… I have faced hard times, I don’t recommend it), this is a not recommended practice AFAIK. Better choose only one and stick together with it until the end 😉