Closed BoltzmannEntropy closed 1 year ago
Hello. I think you may need to check your Paddle Quantum version. All linear algbrea related functions, including the dagger
function, are compatible with numpy.ndarray
since version 2.2.2
of the Paddle Quantum.
I am on a machine without AVX (rror: Your machine doesn't support AVX, but the installed PaddlePaddle is avx core, you should reinstall paddlepaddle with no-avx core.), so this is what I had to do:
RUN python3.8 -m pip download paddlepaddle==2.3.2 -f https://www.paddlepaddle.org.cn/whl/linux/mkl/noavx/stable.html --no-index --no-deps
# does not work well RUN python3.8 -m pip install paddlepaddle==2.4.1 -i https://pypi.tuna.tsinghua.edu.cn/simple paddle-quantum
RUN python3.8 -m pip install paddlepaddle-2.3.2-cp38-cp38-linux_x86_64.whl paddle-quantum
Python 3.8.10 | packaged by conda-forge | (default, May 11 2021, 07:01:05)
[GCC 9.3.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import paddle
>>> import paddle_quantum
>>> paddle_quantum.__version__
'2.2.0'
`ERROR: Cannot install paddle-quantum==2.2.2 and paddlepaddle 2.3.2 (from /paddlepaddle-2.3.2-cp38-cp38-linux_x86_64.whl) because these package versions have conflicting dependencies.
`
Any other option?
Well I am not familiar with AVX. But a possible temporary solution is to run the old tutorials supported by the version 2.2.0 of Paddle Quantum.
But I still recommend you to upgrade Paddle Quantum to the newest version for better user experiences (if you can find other ways to solve the installation problem).
Since paddle-quantum is dependent on paddle, and the latest paddle version for no-avx is 2.3.2, I can not install 2.2.2. I really want the newest version, but this is an Ubuntu based docker running inside OSX with the M1 chip. See here: https://github.com/BoltzmannEntropy/QMLDocker
Is it possible to downgrade your PaddlePaddle version to 2.3.0 and then upgrade Paddle Quantum?
Splendid, it works, thank you so much. I updated the docker file.
For instance: QGAN_EN.iynb
QAutoencoder_CN.ipynb:
ValueError: (InvalidArgument) conj(): argument 'X' (position 0) must be Tensor, but got numpy.ndarray (at /paddle/paddle/fluid/pybind/op_function_common.cc:737)
Can you help?