ComPWA / compwa.github.io

Source code for the ComPWA Organization website
https://compwa.github.io
Apache License 2.0
5 stars 4 forks source link

`jaxlib`: could not find a version that satisfies #136

Closed mmikhasenko closed 2 years ago

mmikhasenko commented 2 years ago

Bug description

the line

%pip install -q ampform==0.14.0 qrules==0.9.7 sympy==1.10.1 tensorwaves[jax,pwa]==0.4.5

causes the error

Note: you may need to restart the kernel to use updated packages.
ERROR: Could not find a version that satisfies the requirement jaxlib; extra == "jax" (from tensorwaves[jax,pwa]) (from versions: none)
ERROR: No matching distribution found for jaxlib; extra == "jax"

once I remove jax from the tensorwaves options, it works.

System info

I am on the e73542d commit of polarization-sensitivity branch running the notebook 017.ipynb

Bug resulted on the following system:

redeboer commented 2 years ago

Seems that this is actually a problem in tensorwaves. In that case, you should have the same effect in the terminal:

conda env create --force  # completely reset the compwa-org environment
pip install tensorwaves[jax,pwa]==0.4.5

Note that tensorwaves etc is not part of the default dependencies defined for the Conda environment. They are installed once a notebook is run. The Conda config for this repo just installs dev tools like jupyter lab, pre-commit and sphinx.

https://github.com/ComPWA/compwa-org/blob/6501662070e2a5f24d01894a24052d9bc78634c0/setup.cfg#L39-L98

redeboer commented 2 years ago

My guess is that either jaxlib or TF (which comes in through pwa) is not supported on Windows

redeboer commented 2 years ago

88374c2 removes the need for ~TensorWaves~ TF (through phasespace). Only problem: have to think how to render phase space times intensity in the 1D intensity plots. Previously, those were just 1D histograms, but the Dalitz plot is now a meshgrid, note a generated hit-and-miss phase space sample.

redeboer commented 2 years ago

My guess is that either jaxlib or TF (which comes in through pwa) is not supported on Windows

See https://github.com/google/jax/issues/438. Since JAX is quite important in the notebooks, I recommend working with WSL2: https://docs.microsoft.com/en-us/windows/wsl/install

redeboer commented 2 years ago

Did you get the numeric computations to work in WSL? If so, I'll close this issue.

mmikhasenko commented 2 years ago

Yes, it works great with WLS

redeboer commented 2 years ago

Perfect!