Hey everyone,
while getting familiar with CADET using the extremely helpful Tutorial provided by you guys
I noticed, the 01_CADET-Match_demonstration wasn´t generating any parameters for me.
after running “match.start_sim()” my output was:
But the result, progress and error csv-files were still empty afterwards. (In the meta folder as well)
The command “match.plot_corner()” didn´t do anything for me
and the command “match.plot_best()” resulted in the following index Error:
The same Problem is also occurring when executing those commands in 02_CADET-Match_exercise as well.
Has this Problem occurred for anybody else?
Does anyone know how to fix it?
Thanks in advance for your help.
Best
Can you run
conda uninstall cadet
and see if that fixes the error? The python cadet interface was just renamed from cadet to cadet-python and I suspect that is what is causing problem.
1 Like
Hey thanks for your quick answer!
Okay so I uninstalled cadet, but when I executed
%run …/utils.ipynb
I got the error “ModuleNotFound” for the line
from cadet import Cadet
since cadet wasn´t installed anymore so I tried
conda install -c immudzen cadet-python
Which worked (at least something did install)
But then when executing the %run …/utils.ipynb I got the error “ModuleNotFound” for the line
from CADETMatch.jupyter import Match
instead so I tried
conda install -c immudzen cadetmatch
Now I can execute the
%run …/utils.ipynb
without any error again, but I get the same error as before for the actual matching
Best Jan
This is really odd and so far I have not been able to replicate it. Can you run the follow block of code in your notebook? Just put it in the top cell.
import cadet
print(cadet.__file__)
print(cadet.__version__)
1 Like
Sorry for the late answer but I had no access to the computer over the weekend.
The output for your command is:
C:\Users\WS2819\Anaconda3\lib\site-packages\cadet_init_.py
0.4
Okay it looks like somehow there are multiple version of the interface mixed together
Lets remove all of them and then just reinstall
conda uninstall cadetmatch
conda uninstall cadet
conda uninstall cadet-python
pip uninstall cadetmatch
pip uninstall cadet
pip uninstall cadet-python
then run python and run the above command again
import cadet
print(cadet.__file__)
print(cadet.__version__)
It should give an ImportError on the import and get no version information if everything worked.
Then just run
conda install -c immudzen cadetmatch
This should fix the problem
1 Like
Deinstallation worked and also it gave me the import error when executing those three lines
When performing the new installation I got an error concerning a file size:
Executing the simulations worked again, but for cadet match I got the same error as before.
for your three lines of code the output was:
C:\Users\WS2819\Anaconda3\lib\site-packages\cadet_init_.py
0.4
For that file path is it appearing as you intended it to appear? I just want to make sure that the forum is not changing the path because that path also looks weird.
This is what I get
C:\Users\kosh_000\anaconda3\envs\cadet_run\lib\site-packages\cadet\__init__.py
0.11
Overall, this is weird. It is trying to install cadetmatch 0.6.23 and cadet 0.6 python interface but the current version is 0.7.1 and uses cadet-python now. I wonder why when you install cadetmatch it is downloading an old version. Even weirder you notice that when you ran the impact cadet command it showed version 0.4 which does not even match the version that conda downloaded.
There is definitely something weird happening. I just created a new conda environment for python 3.7 and 3.8 and I have not been able to replicate this.
I am trying to figure out what could be causing this.
1 Like
You are right the forum did not display the last slash.
The correct output is:
C:\Users\WS2819\Anaconda3\lib\site-packages\cadet\__init__.py
0.4
But it still seems to be in another directory than for you.
Is there any dependency on the cadet-file I am using?
Also I noticed that all those additional packages (jupyternotebook etc.) do only appear in my anaconda Navigator if I update the index. May this be a related issue?
I uninstalled all packages and repeated the cadet Installation Process.
this is what the terminal displayed during all those steps (maybe it contains any important information ):
(base) C:\Users\WS2819>conda install numpy scipy matplotlib gitpython jupyterlab ipywidgets
Collecting package metadata (current_repodata.json): done
Solving environment: done
## Package Plan ##
environment location: C:\Users\WS2819\Anaconda3
added / updated specs:
- gitpython
- ipywidgets
- jupyterlab
- matplotlib
- numpy
- scipy
The following packages will be downloaded:
package | build
---------------------------|-----------------
anyio-2.2.0 | py38haa244fe_0 116 KB conda-forge
jupyter_server-1.4.1 | py38haa95532_0 332 KB
jupyterlab-3.0.16 | pyhd8ed1ab_0 5.7 MB conda-forge
jupyterlab_server-2.6.0 | pyhd8ed1ab_0 44 KB conda-forge
matplotlib-3.4.2 | py38haa244fe_0 7 KB conda-forge
matplotlib-base-3.4.2 | py38heae8d8c_0 7.3 MB conda-forge
nbclassic-0.2.6 | pyhd3eb1b0_0 19 KB
numpy-1.21.0 | py38h09042cb_0 5.6 MB conda-forge
scipy-1.7.0 | py38he847743_0 24.5 MB conda-forge
sniffio-1.2.0 | py38haa244fe_1 15 KB conda-forge
------------------------------------------------------------
Total: 43.6 MB
The following NEW packages will be INSTALLED:
anyio conda-forge/win-64::anyio-2.2.0-py38haa244fe_0
argon2-cffi conda-forge/win-64::argon2-cffi-20.1.0-py38h294d835_2
cycler conda-forge/noarch::cycler-0.10.0-py_2
gitdb conda-forge/noarch::gitdb-4.0.7-pyhd8ed1ab_0
gitpython conda-forge/noarch::gitpython-3.1.18-pyhd8ed1ab_0
ipywidgets conda-forge/noarch::ipywidgets-7.6.3-pyhd3deb0d_0
json5 conda-forge/noarch::json5-0.9.5-pyh9f0ad1d_0
jupyter_server pkgs/main/win-64::jupyter_server-1.4.1-py38haa95532_0
jupyterlab conda-forge/noarch::jupyterlab-3.0.16-pyhd8ed1ab_0
jupyterlab_server conda-forge/noarch::jupyterlab_server-2.6.0-pyhd8ed1ab_0
jupyterlab_widgets conda-forge/noarch::jupyterlab_widgets-1.0.0-pyhd8ed1ab_1
kiwisolver conda-forge/win-64::kiwisolver-1.3.1-py38hbd9d945_1
libcblas conda-forge/win-64::libcblas-3.9.0-9_mkl
matplotlib conda-forge/win-64::matplotlib-3.4.2-py38haa244fe_0
matplotlib-base conda-forge/win-64::matplotlib-base-3.4.2-py38heae8d8c_0
nbclassic pkgs/main/noarch::nbclassic-0.2.6-pyhd3eb1b0_0
notebook conda-forge/noarch::notebook-6.4.0-pyha770c72_0
numpy conda-forge/win-64::numpy-1.21.0-py38h09042cb_0
prometheus_client conda-forge/noarch::prometheus_client-0.11.0-pyhd8ed1ab_0
pywinpty conda-forge/win-64::pywinpty-1.1.1-py38hd3f51b4_0
scipy conda-forge/win-64::scipy-1.7.0-py38he847743_0
send2trash conda-forge/noarch::send2trash-1.7.1-pyhd8ed1ab_0
smmap conda-forge/noarch::smmap-3.0.5-pyh44b312d_0
sniffio conda-forge/win-64::sniffio-1.2.0-py38haa244fe_1
terminado conda-forge/win-64::terminado-0.10.1-py38haa244fe_0
widgetsnbextension conda-forge/win-64::widgetsnbextension-3.5.1-py38haa244fe_4
winpty conda-forge/win-64::winpty-0.4.3-4
Proceed ([y]/n)? y
Downloading and Extracting Packages
scipy-1.7.0 | 24.5 MB | ############################################################################ | 100%
matplotlib-3.4.2 | 7 KB | ############################################################################ | 100%
jupyterlab_server-2. | 44 KB | ############################################################################ | 100%
sniffio-1.2.0 | 15 KB | ############################################################################ | 100%
numpy-1.21.0 | 5.6 MB | ############################################################################ | 100%
jupyterlab-3.0.16 | 5.7 MB | ############################################################################ | 100%
nbclassic-0.2.6 | 19 KB | ############################################################################ | 100%
anyio-2.2.0 | 116 KB | ############################################################################ | 100%
matplotlib-base-3.4. | 7.3 MB | ############################################################################ | 100%
jupyter_server-1.4.1 | 332 KB | ############################################################################ | 100%
Preparing transaction: done
Verifying transaction: done
Executing transaction: | Enabling notebook extension jupyter-js-widgets/extension...
- Validating: ok
done
(base) C:\Users\WS2819>conda install -c conda-forge jupyter_contrib_nbextensions jupyter_nbextensions_configurator
Collecting package metadata (current_repodata.json): done
Solving environment: done
## Package Plan ##
environment location: C:\Users\WS2819\Anaconda3
added / updated specs:
- jupyter_contrib_nbextensions
- jupyter_nbextensions_configurator
The following NEW packages will be INSTALLED:
jupyter_contrib_c~ conda-forge/noarch::jupyter_contrib_core-0.3.3-py_2
jupyter_contrib_n~ conda-forge/noarch::jupyter_contrib_nbextensions-0.5.1-pyhd8ed1ab_2
jupyter_highlight~ conda-forge/win-64::jupyter_highlight_selected_word-0.2.0-py38haa244fe_1002
jupyter_latex_envs conda-forge/noarch::jupyter_latex_envs-1.4.6-pyhd8ed1ab_1002
jupyter_nbextensi~ conda-forge/win-64::jupyter_nbextensions_configurator-0.4.1-py38haa244fe_2
libxslt conda-forge/win-64::libxslt-1.1.33-h65864e5_2
lxml conda-forge/win-64::lxml-4.6.3-py38h292cb97_0
Proceed ([y]/n)? y
Preparing transaction: done
Verifying transaction: done
Executing transaction: -
- Enabling: jupyter_nbextensions_configurator
- Writing config: C:\Users\WS2819\Anaconda3\etc\jupyter
- Validating...
jupyter_nbextensions_configurator 0.4.1 ok
Enabling notebook nbextension nbextensions_configurator/config_menu/main...
Enabling tree nbextension nbextensions_configurator/tree_tab/main...
done
(base) C:\Users\WS2819>conda config --add channels anaconda-fusion
Warning: 'anaconda-fusion' already in 'channels' list, moving to the top
(base) C:\Users\WS2819>conda config --add channels conda-forge
Warning: 'conda-forge' already in 'channels' list, moving to the top
(base) C:\Users\WS2819>conda install -c immudzen cadet
Collecting package metadata (current_repodata.json): done
Solving environment: done
## Package Plan ##
environment location: C:\Users\WS2819\Anaconda3
added / updated specs:
- cadet
The following NEW packages will be INSTALLED:
addict conda-forge/win-64::addict-2.4.0-py38haa244fe_0
cached-property conda-forge/noarch::cached-property-1.5.2-hd8ed1ab_1
cached_property conda-forge/noarch::cached_property-1.5.2-pyha770c72_1
cadet immudzen/noarch::cadet-0.6-pyh39e3cac_0
h5py conda-forge/win-64::h5py-3.3.0-nompi_py38he6c2248_100
hdf5 conda-forge/win-64::hdf5-1.10.6-nompi_h5268f04_1114
krb5 conda-forge/win-64::krb5-1.19.1-hbae68bd_0
libcurl conda-forge/win-64::libcurl-7.77.0-h789b8ee_0
libssh2 conda-forge/win-64::libssh2-1.9.0-h680486a_6
pyreadline conda-forge/win-64::pyreadline-2.1-py38haa244fe_1003
Proceed ([y]/n)? y
Preparing transaction: done
Verifying transaction: done
Executing transaction: done
(base) C:\Users\WS2819>conda install -c immudzen cadetmatch
Collecting package metadata (current_repodata.json): done
Solving environment: done
## Package Plan ##
environment location: C:\Users\WS2819\Anaconda3
added / updated specs:
- cadetmatch
The following packages will be downloaded:
package | build
---------------------------|-----------------
emcee-3.1.0 | pyh8a188c0_0 34 KB conda-forge
------------------------------------------------------------
Total: 34 KB
The following NEW packages will be INSTALLED:
arviz conda-forge/noarch::arviz-0.11.2-pyhd8ed1ab_1
cadetmatch immudzen/noarch::cadetmatch-0.6.23-py_0
cftime conda-forge/win-64::cftime-1.5.0-py38hcb5f9af_0
corner conda-forge/noarch::corner-2.2.1-pyhd8ed1ab_0
curl conda-forge/win-64::curl-7.77.0-h789b8ee_0
deap conda-forge/win-64::deap-1.3.1-py38h4c96930_2
emcee conda-forge/noarch::emcee-3.1.0-pyh8a188c0_0
et_xmlfile conda-forge/noarch::et_xmlfile-1.0.1-py_1001
hdf4 conda-forge/win-64::hdf4-4.2.15-h0e5069d_3
jdcal conda-forge/noarch::jdcal-1.4.1-py_0
joblib conda-forge/noarch::joblib-1.0.1-pyhd8ed1ab_0
jstyleson immudzen/noarch::jstyleson-0.2.0-py_0
libnetcdf conda-forge/win-64::libnetcdf-4.8.0-nompi_hf689e7d_103
libzip conda-forge/win-64::libzip-1.8.0-hfed4ece_0
netcdf4 conda-forge/win-64::netcdf4-1.5.7-nompi_py38h58ef0d0_100
openpyxl conda-forge/noarch::openpyxl-3.0.7-pyhd8ed1ab_0
pandas conda-forge/win-64::pandas-1.2.5-py38h60cbd38_0
patsy conda-forge/noarch::patsy-0.5.1-py_0
salib conda-forge/noarch::salib-1.3.11-py_0
schwimmbad conda-forge/win-64::schwimmbad-0.3.2-py38haa244fe_0
scikit-learn conda-forge/win-64::scikit-learn-0.24.2-py38h5d5d464_0
seaborn conda-forge/noarch::seaborn-0.11.1-hd8ed1ab_1
seaborn-base conda-forge/noarch::seaborn-base-0.11.1-pyhd8ed1ab_1
statsmodels conda-forge/win-64::statsmodels-0.12.2-py38h347fdf6_0
threadpoolctl conda-forge/noarch::threadpoolctl-2.1.0-pyh5ca1d4c_0
xarray conda-forge/noarch::xarray-0.18.2-pyhd8ed1ab_0
Proceed ([y]/n)? y
Downloading and Extracting Packages
emcee-3.1.0 | 34 KB | ############################################################################ | 100%
Preparing transaction: done
Verifying transaction: |
SafetyError: The package for cadetmatch located at C:\Users\WS2819\Anaconda3\pkgs\cadetmatch-0.6.23-py_0
appears to be corrupted. The path 'site-packages/CADETMatch/jupyter.py'
has an incorrect size.
reported size: 3495 bytes
actual size: 3503 bytes
done
Executing transaction: done
after executing:
from CADETMatch.jupyter import Match
match_config_file = base_dir / 'langmuir.json'
with open(match_config_file, 'w') as json_file:
json.dump(match_config.to_dict(), json_file, indent='\t')
match = Match(match_config_file)
match.start_sim()
this time it displayed my emcee-version to be 0.0.0 although it clearly got installed in the last step of the installation before the safety error occurred.
maybe this is also related to my problem
Oh, I see a problem.
You ran
conda install -c immudzen cadet
but the package was renamed to cadet-python. There is also no reason to install it on its own.
The only command you should need to run is
conda install -c immudzen cadetmatch
and it will install the python interface it needs automatically.
can you run
conda uninstall cadet
conda install -c immudzen cadetmatch=0.7.1
Then run
import cadet
print(cadet.__file__)
print(cadet.__version__)
and see if it shows the right version. What I can’t figure out is why it is trying to install an older version when you run the install command.
1 Like
Okay from now on I better include all the information
So I ran what you asked me to:
(base) C:\Users\WS2819>conda uninstall cadet
Collecting package metadata (repodata.json): done
Solving environment: done
## Package Plan ##
environment location: C:\Users\WS2819\Anaconda3
removed specs:
- cadet
The following packages will be REMOVED:
addict-2.4.0-py38haa244fe_0
arviz-0.11.2-pyhd8ed1ab_1
cadet-0.6-pyh39e3cac_0
cadetmatch-0.6.23-py_0
cftime-1.5.0-py38hcb5f9af_0
corner-2.2.1-pyhd8ed1ab_0
curl-7.77.0-h789b8ee_0
deap-1.3.1-py38h4c96930_2
et_xmlfile-1.0.1-py_1001
hdf4-4.2.15-h0e5069d_3
jdcal-1.4.1-py_0
joblib-1.0.1-pyhd8ed1ab_0
jstyleson-0.2.0-py_0
libnetcdf-4.8.0-nompi_hf689e7d_103
libzip-1.8.0-hfed4ece_0
netcdf4-1.5.7-nompi_py38h58ef0d0_100
openpyxl-3.0.7-pyhd8ed1ab_0
pandas-1.2.5-py38h60cbd38_0
patsy-0.5.1-py_0
salib-1.3.11-py_0
scikit-learn-0.24.2-py38h5d5d464_0
seaborn-0.11.1-hd8ed1ab_1
seaborn-base-0.11.1-pyhd8ed1ab_1
statsmodels-0.12.2-py38h347fdf6_0
threadpoolctl-2.1.0-pyh5ca1d4c_0
xarray-0.18.2-pyhd8ed1ab_0
Proceed ([y]/n)? y
Preparing transaction: done
Verifying transaction: done
Executing transaction: done
(base) C:\Users\WS2819>conda install -c immudzen cadetmatch=0.7.1
Collecting package metadata (current_repodata.json): done
Solving environment: done
## Package Plan ##
environment location: C:\Users\WS2819\Anaconda3
added / updated specs:
- cadetmatch=0.7.1
The following packages will be downloaded:
package | build
---------------------------|-----------------
libblas-3.9.0 | 8_mkl 3.9 MB conda-forge
libcblas-3.9.0 | 8_mkl 3.9 MB conda-forge
liblapack-3.9.0 | 8_mkl 3.9 MB conda-forge
mkl-2020.4 | hb70f87d_311 172.4 MB conda-forge
------------------------------------------------------------
Total: 184.1 MB
The following NEW packages will be INSTALLED:
addict conda-forge/win-64::addict-2.4.0-py38haa244fe_0
arviz conda-forge/noarch::arviz-0.11.2-pyhd8ed1ab_1
cadet-python immudzen/noarch::cadet-python-0.11-py_0
cadetmatch immudzen/noarch::cadetmatch-0.7.1-py_0
cftime conda-forge/win-64::cftime-1.5.0-py38hcb5f9af_0
corner conda-forge/noarch::corner-2.2.1-pyhd8ed1ab_0
curl conda-forge/win-64::curl-7.77.0-h789b8ee_0
deap conda-forge/win-64::deap-1.3.1-py38h4c96930_2
et_xmlfile conda-forge/noarch::et_xmlfile-1.0.1-py_1001
hdf4 conda-forge/win-64::hdf4-4.2.15-h0e5069d_3
jdcal conda-forge/noarch::jdcal-1.4.1-py_0
joblib conda-forge/noarch::joblib-1.0.1-pyhd8ed1ab_0
jstyleson immudzen/noarch::jstyleson-0.2.0-py_0
libnetcdf conda-forge/win-64::libnetcdf-4.8.0-nompi_hf689e7d_103
libzip conda-forge/win-64::libzip-1.8.0-hfed4ece_0
llvmlite conda-forge/win-64::llvmlite-0.36.0-py38h57a6900_0
netcdf4 conda-forge/win-64::netcdf4-1.5.7-nompi_py38h58ef0d0_100
numba conda-forge/win-64::numba-0.53.1-py38h99fac5f_1
openpyxl conda-forge/noarch::openpyxl-3.0.7-pyhd8ed1ab_0
pandas conda-forge/win-64::pandas-1.2.5-py38h60cbd38_0
patsy conda-forge/noarch::patsy-0.5.1-py_0
salib conda-forge/noarch::salib-1.3.11-py_0
scikit-learn conda-forge/win-64::scikit-learn-0.24.2-py38h5d5d464_0
seaborn conda-forge/noarch::seaborn-0.11.1-hd8ed1ab_1
seaborn-base conda-forge/noarch::seaborn-base-0.11.1-pyhd8ed1ab_1
statsmodels conda-forge/win-64::statsmodels-0.12.2-py38h347fdf6_0
threadpoolctl conda-forge/noarch::threadpoolctl-2.1.0-pyh5ca1d4c_0
xarray conda-forge/noarch::xarray-0.18.2-pyhd8ed1ab_0
The following packages will be REMOVED:
tbb-2021.2.0-h2d74725_1
The following packages will be DOWNGRADED:
libblas 3.9.0-9_mkl --> 3.9.0-8_mkl
libcblas 3.9.0-9_mkl --> 3.9.0-8_mkl
liblapack 3.9.0-9_mkl --> 3.9.0-8_mkl
mkl 2021.2.0-hb70f87d_389 --> 2020.4-hb70f87d_311
Proceed ([y]/n)? y
Downloading and Extracting Packages
liblapack-3.9.0 | 3.9 MB | ############################################################################ | 100%
libblas-3.9.0 | 3.9 MB | ############################################################################ | 100%
libcblas-3.9.0 | 3.9 MB | ############################################################################ | 100%
mkl-2020.4 | 172.4 MB | ############################################################################ | 100%
Preparing transaction: done
Verifying transaction: done
Executing transaction: done
so this time there was no safety error.
Executing:
import cadet
print(cadet.__file__)
print(cadet.__version__)
this time got me the Output:
C:\Users\WS2819\Anaconda3\lib\site-packages\CADET_Python-0.11-py3.7.egg\cadet\__init__.py
0.11
When you wrote:
Then just run
conda install -c immudzen cadetmatch
This should fix the problem
I was 99 % sure I only executed this one command but apparently I also installed Cadet again because now the issue seems to be fixed.
Thank you so much for your dedicated help!
I wouldn´t have been able to figure this out by myself since I was always following the github documentation.
On a side note: is the RuntimeWarning
C:\Users\WS2819\Anaconda3\lib\subprocess.py:844: RuntimeWarning: line buffering (buffering=1) isn't supported in binary mode, the default buffer size will be used
self.stdout = io.open(c2pread, 'rb', bufsize)
I encountered something that usually occurs, or does this indicate additional installation mistakes?
No problem I am happy everything is working now.
You can ignore this warning. It just comes from running the matching software inside jupyter notebooks.
1 Like