qmlcode / qml

QML: Quantum Machine Learning
MIT License
196 stars 84 forks source link

Installation broken in fresh virtual environments #145

Open EdmundGoodman opened 11 months ago

EdmundGoodman commented 11 months ago

Description

The QML library cannot be installed in an environment where NumPy is not already installed, for example a fresh virtual environment when installing another project which uses QML as a dependency.

To reproduce

python3 -m venv venv
source venv/bin/activate
pip install qml

image

If NumPy is installed beforehand, then it works

python3 -m venv venv
source venv/bin/activate
pip install numpy
pip install qml

image

How to fix

NumPy should be specified as a dependency in the setup configuration.

jintianyun56 commented 9 months ago

Hi there,

The system is Centos stream 9, I run this code python3 -m venv venv source venv/bin/activate pip install numpy pip install qml

It has the same error "No module named numpy". "pip install numpy" did not work. I tried to use Intel compiler (2019) and ifort 19.0.0.117 with MKL, also failed showing " ModuleNotFoundError: No module named 'numpy' "

Thanks

UnixJunkie commented 1 month ago

probably related to https://github.com/qmlcode/qml/issues/149

Anybody managed to fix that?

UnixJunkie commented 1 month ago

I have numpy==1.23.4 installed, and I can't install qml@git+https://github.com/qmlcode/qml@a7921c9176b9498dcce096efad0883271706d633 ...

This issue is almost one year old. Can we have some feedback from the maintainers?