Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The Quantum Circuit is not Compiling Properly #3

Open
ItsShraddhaMishra opened this issue Oct 4, 2021 · 5 comments
Open

The Quantum Circuit is not Compiling Properly #3

ItsShraddhaMishra opened this issue Oct 4, 2021 · 5 comments

Comments

@ItsShraddhaMishra
Copy link

I was learning from Your code but the class QuanvCircuit which defines self._circuit cant fetch quantum counts.
Could You please Help in fix the issue? Thanks in advance!
IMG_20211004_150628

@ItsShraddhaMishra
Copy link
Author

I was learning from Your code but the class QuanvCircuit which defines self._circuit cant fetch quantum counts.
Could You please Help in fix the issue? Thanks in advance!
below are the picture of Your code and how it ran on my computer.

1
2

@yh08037
Copy link
Owner

yh08037 commented Oct 5, 2021

First of all, thank you for your interest in our repository.
Since the repo was not managed after the hackathon, it would not have been executed due to differences in versions of qiskit or pytorch.
Please check the versions of numpy, qiskit, pytorch, etc., and test them again.
Below is a list of the entire packages of the anaconda virtual environment used at the hackathon.
I've confirmed that it's running well in this environment.
I'm sorry for the inconvenience you're studying.
We will update our codes to run without any problems on the latest version of qiskit shortly.

# packages in environment at /home/dohun/anaconda3/envs/qistorch:
#
# Name                    Version                   Build  Channel
_libgcc_mutex             0.1                        main  
attrs                     20.3.0                   pypi_0    pypi
backcall                  0.2.0                    pypi_0    pypi
blas                      1.0                         mkl  
ca-certificates           2021.1.19            h06a4308_0  
certifi                   2020.12.5        py38h06a4308_0  
cffi                      1.14.5                   pypi_0    pypi
chardet                   4.0.0                    pypi_0    pypi
cryptography              3.4.5                    pypi_0    pypi
cudatoolkit               10.2.89              hfd86e86_1  
cycler                    0.10.0                   pypi_0    pypi
cython                    0.29.21                  pypi_0    pypi
decorator                 4.4.2                    pypi_0    pypi
dill                      0.3.3                    pypi_0    pypi
dlx                       1.0.4                    pypi_0    pypi
docplex                   2.20.204                 pypi_0    pypi
fastdtw                   0.3.4                    pypi_0    pypi
fastjsonschema            2.15.0                   pypi_0    pypi
freetype                  2.10.4               h5ab3b9f_0  
h5py                      3.1.0                    pypi_0    pypi
idna                      2.10                     pypi_0    pypi
inflection                0.5.1                    pypi_0    pypi
intel-openmp              2020.2                      254  
ipykernel                 5.4.3                    pypi_0    pypi
ipython                   7.20.0                   pypi_0    pypi
ipython-genutils          0.2.0                    pypi_0    pypi
jedi                      0.18.0                   pypi_0    pypi
joblib                    1.0.1                    pypi_0    pypi
jpeg                      9b                   h024ee3a_2  
jsonschema                3.2.0                    pypi_0    pypi
jupyter-client            6.1.11                   pypi_0    pypi
jupyter-core              4.7.1                    pypi_0    pypi
kiwisolver                1.3.1                    pypi_0    pypi
lcms2                     2.11                 h396b838_0  
ld_impl_linux-64          2.33.1               h53a641e_7  
libedit                   3.1.20191231         h14c3975_1  
libffi                    3.3                  he6710b0_2  
libgcc-ng                 9.1.0                hdf63c60_0  
libpng                    1.6.37               hbc83047_0  
libstdcxx-ng              9.1.0                hdf63c60_0  
libtiff                   4.1.0                h2733197_1  
libuv                     1.40.0               h7b6447c_0  
lxml                      4.6.2                    pypi_0    pypi
lz4-c                     1.9.3                h2531618_0  
matplotlib                3.3.4                    pypi_0    pypi
mkl                       2020.2                      256  
mkl-service               2.3.0            py38he904b0f_0  
mkl_fft                   1.2.0            py38h23d657b_0  
mkl_random                1.1.1            py38h0573a6f_0  
more-itertools            8.7.0                    pypi_0    pypi
mpmath                    1.2.1                    pypi_0    pypi
multitasking              0.0.9                    pypi_0    pypi
ncurses                   6.2                  he6710b0_1  
nest-asyncio              1.5.1                    pypi_0    pypi
networkx                  2.5                      pypi_0    pypi
ninja                     1.10.2           py38hff7bd54_0  
ntlm-auth                 1.5.0                    pypi_0    pypi
numpy                     1.19.5                   pypi_0    pypi
numpy-base                1.19.2           py38hfa32c7d_0  
olefile                   0.46                       py_0  
openssl                   1.1.1i               h27cfd23_0  
pandas                    1.2.2                    pypi_0    pypi
parso                     0.8.1                    pypi_0    pypi
pexpect                   4.8.0                    pypi_0    pypi
pickleshare               0.7.5                    pypi_0    pypi
pillow                    8.1.0            py38he98fc37_0  
pip                       20.3.3           py38h06a4308_0  
ply                       3.11                     pypi_0    pypi
prompt-toolkit            3.0.16                   pypi_0    pypi
psutil                    5.8.0                    pypi_0    pypi
ptyprocess                0.7.0                    pypi_0    pypi
pybind11                  2.6.2                    pypi_0    pypi
pycparser                 2.20                     pypi_0    pypi
pygments                  2.8.0                    pypi_0    pypi
pylatexenc                2.8                      pypi_0    pypi
pyparsing                 2.4.7                    pypi_0    pypi
pyrsistent                0.17.3                   pypi_0    pypi
python                    3.8.5                h7579374_1  
python-constraint         1.4.0                    pypi_0    pypi
python-dateutil           2.8.1                    pypi_0    pypi
pytorch                   1.7.1           py3.8_cuda10.2.89_cudnn7.6.5_0    pytorch
pytz                      2021.1                   pypi_0    pypi
pyzmq                     22.0.3                   pypi_0    pypi
qiskit                    0.23.4                   pypi_0    pypi
qiskit-aer                0.7.3                    pypi_0    pypi
qiskit-aqua               0.8.1                    pypi_0    pypi
qiskit-ibmq-provider      0.11.1                   pypi_0    pypi
qiskit-ignis              0.5.1                    pypi_0    pypi
qiskit-terra              0.16.3                   pypi_0    pypi
quandl                    3.6.0                    pypi_0    pypi
readline                  8.1                  h27cfd23_0  
requests                  2.25.1                   pypi_0    pypi
requests-ntlm             1.1.0                    pypi_0    pypi
retworkx                  0.7.2                    pypi_0    pypi
scikit-learn              0.24.1                   pypi_0    pypi
scipy                     1.6.0                    pypi_0    pypi
setuptools                52.0.0           py38h06a4308_0  
six                       1.15.0           py38h06a4308_0  
sqlite                    3.33.0               h62c20be_0  
sympy                     1.7.1                    pypi_0    pypi
threadpoolctl             2.1.0                    pypi_0    pypi
tk                        8.6.10               hbc83047_0  
torchaudio                0.7.2                      py38    pytorch
torchsummary              1.5.1                    pypi_0    pypi
torchvision               0.8.2                py38_cu102    pytorch
tornado                   6.1                      pypi_0    pypi
traitlets                 5.0.5                    pypi_0    pypi
typing_extensions         3.7.4.3            pyha847dfd_0  
urllib3                   1.26.3                   pypi_0    pypi
wcwidth                   0.2.5                    pypi_0    pypi
websockets                8.1                      pypi_0    pypi
wheel                     0.36.2             pyhd3eb1b0_0  
xz                        5.2.5                h7b6447c_0  
yfinance                  0.1.55                   pypi_0    pypi
zlib                      1.2.11               h7b6447c_3  
zstd                      1.4.5                h9ceee32_0  ​

@ItsShraddhaMishra
Copy link
Author

I really want to insist that the code is still giving the same faulty output. Please check the code. I have installed the main libraries in exact specific versions and it doesn't work.

@zwyzhr
Copy link

zwyzhr commented Oct 20, 2021

First of all, thank you for your interest in our repository. Since the repo was not managed after the hackathon, it would not have been executed due to differences in versions of qiskit or pytorch. Please check the versions of numpy, qiskit, pytorch, etc., and test them again. Below is a list of the entire packages of the anaconda virtual environment used at the hackathon. I've confirmed that it's running well in this environment. I'm sorry for the inconvenience you're studying. We will update our codes to run without any problems on the latest version of qiskit shortly.

首先,感谢您对我们的存储库感兴趣。由于回购协议在黑客马拉松之后没有得到管理,所以由于 qiskit 和 pytorch 版本的不同,它不会被执行。请检查 numpy、 qiskit、 pytorch 等的版本,并再次测试它们。下面是在黑客马拉松中使用的蟒蛇虚拟环境的全部包的列表。我已经确认它在这种环境下运行良好。我很抱歉给你学习带来的不便。我们将更新我们的代码运行没有任何问题的最新版本的 qiskit 不久。

# packages in environment at /home/dohun/anaconda3/envs/qistorch:
#
# Name                    Version                   Build  Channel
_libgcc_mutex             0.1                        main  
attrs                     20.3.0                   pypi_0    pypi
backcall                  0.2.0                    pypi_0    pypi
blas                      1.0                         mkl  
ca-certificates           2021.1.19            h06a4308_0  
certifi                   2020.12.5        py38h06a4308_0  
cffi                      1.14.5                   pypi_0    pypi
chardet                   4.0.0                    pypi_0    pypi
cryptography              3.4.5                    pypi_0    pypi
cudatoolkit               10.2.89              hfd86e86_1  
cycler                    0.10.0                   pypi_0    pypi
cython                    0.29.21                  pypi_0    pypi
decorator                 4.4.2                    pypi_0    pypi
dill                      0.3.3                    pypi_0    pypi
dlx                       1.0.4                    pypi_0    pypi
docplex                   2.20.204                 pypi_0    pypi
fastdtw                   0.3.4                    pypi_0    pypi
fastjsonschema            2.15.0                   pypi_0    pypi
freetype                  2.10.4               h5ab3b9f_0  
h5py                      3.1.0                    pypi_0    pypi
idna                      2.10                     pypi_0    pypi
inflection                0.5.1                    pypi_0    pypi
intel-openmp              2020.2                      254  
ipykernel                 5.4.3                    pypi_0    pypi
ipython                   7.20.0                   pypi_0    pypi
ipython-genutils          0.2.0                    pypi_0    pypi
jedi                      0.18.0                   pypi_0    pypi
joblib                    1.0.1                    pypi_0    pypi
jpeg                      9b                   h024ee3a_2  
jsonschema                3.2.0                    pypi_0    pypi
jupyter-client            6.1.11                   pypi_0    pypi
jupyter-core              4.7.1                    pypi_0    pypi
kiwisolver                1.3.1                    pypi_0    pypi
lcms2                     2.11                 h396b838_0  
ld_impl_linux-64          2.33.1               h53a641e_7  
libedit                   3.1.20191231         h14c3975_1  
libffi                    3.3                  he6710b0_2  
libgcc-ng                 9.1.0                hdf63c60_0  
libpng                    1.6.37               hbc83047_0  
libstdcxx-ng              9.1.0                hdf63c60_0  
libtiff                   4.1.0                h2733197_1  
libuv                     1.40.0               h7b6447c_0  
lxml                      4.6.2                    pypi_0    pypi
lz4-c                     1.9.3                h2531618_0  
matplotlib                3.3.4                    pypi_0    pypi
mkl                       2020.2                      256  
mkl-service               2.3.0            py38he904b0f_0  
mkl_fft                   1.2.0            py38h23d657b_0  
mkl_random                1.1.1            py38h0573a6f_0  
more-itertools            8.7.0                    pypi_0    pypi
mpmath                    1.2.1                    pypi_0    pypi
multitasking              0.0.9                    pypi_0    pypi
ncurses                   6.2                  he6710b0_1  
nest-asyncio              1.5.1                    pypi_0    pypi
networkx                  2.5                      pypi_0    pypi
ninja                     1.10.2           py38hff7bd54_0  
ntlm-auth                 1.5.0                    pypi_0    pypi
numpy                     1.19.5                   pypi_0    pypi
numpy-base                1.19.2           py38hfa32c7d_0  
olefile                   0.46                       py_0  
openssl                   1.1.1i               h27cfd23_0  
pandas                    1.2.2                    pypi_0    pypi
parso                     0.8.1                    pypi_0    pypi
pexpect                   4.8.0                    pypi_0    pypi
pickleshare               0.7.5                    pypi_0    pypi
pillow                    8.1.0            py38he98fc37_0  
pip                       20.3.3           py38h06a4308_0  
ply                       3.11                     pypi_0    pypi
prompt-toolkit            3.0.16                   pypi_0    pypi
psutil                    5.8.0                    pypi_0    pypi
ptyprocess                0.7.0                    pypi_0    pypi
pybind11                  2.6.2                    pypi_0    pypi
pycparser                 2.20                     pypi_0    pypi
pygments                  2.8.0                    pypi_0    pypi
pylatexenc                2.8                      pypi_0    pypi
pyparsing                 2.4.7                    pypi_0    pypi
pyrsistent                0.17.3                   pypi_0    pypi
python                    3.8.5                h7579374_1  
python-constraint         1.4.0                    pypi_0    pypi
python-dateutil           2.8.1                    pypi_0    pypi
pytorch                   1.7.1           py3.8_cuda10.2.89_cudnn7.6.5_0    pytorch
pytz                      2021.1                   pypi_0    pypi
pyzmq                     22.0.3                   pypi_0    pypi
qiskit                    0.23.4                   pypi_0    pypi
qiskit-aer                0.7.3                    pypi_0    pypi
qiskit-aqua               0.8.1                    pypi_0    pypi
qiskit-ibmq-provider      0.11.1                   pypi_0    pypi
qiskit-ignis              0.5.1                    pypi_0    pypi
qiskit-terra              0.16.3                   pypi_0    pypi
quandl                    3.6.0                    pypi_0    pypi
readline                  8.1                  h27cfd23_0  
requests                  2.25.1                   pypi_0    pypi
requests-ntlm             1.1.0                    pypi_0    pypi
retworkx                  0.7.2                    pypi_0    pypi
scikit-learn              0.24.1                   pypi_0    pypi
scipy                     1.6.0                    pypi_0    pypi
setuptools                52.0.0           py38h06a4308_0  
six                       1.15.0           py38h06a4308_0  
sqlite                    3.33.0               h62c20be_0  
sympy                     1.7.1                    pypi_0    pypi
threadpoolctl             2.1.0                    pypi_0    pypi
tk                        8.6.10               hbc83047_0  
torchaudio                0.7.2                      py38    pytorch
torchsummary              1.5.1                    pypi_0    pypi
torchvision               0.8.2                py38_cu102    pytorch
tornado                   6.1                      pypi_0    pypi
traitlets                 5.0.5                    pypi_0    pypi
typing_extensions         3.7.4.3            pyha847dfd_0  
urllib3                   1.26.3                   pypi_0    pypi
wcwidth                   0.2.5                    pypi_0    pypi
websockets                8.1                      pypi_0    pypi
wheel                     0.36.2             pyhd3eb1b0_0  
xz                        5.2.5                h7b6447c_0  
yfinance                  0.1.55                   pypi_0    pypi
zlib                      1.2.11               h7b6447c_3  
zstd                      1.4.5                h9ceee32_0  ​

I also met the same problem, could you please send you the correct jupyter running file with the result

@azusakou
Copy link

I met the same problem as well, I will very appreciate if you could upload the files.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants