PyBaMM version 21.08 does not install
See original GitHub issue- PyBaMM version 21.08
- Python version 3.9.5
Describe the bug
I’m trying to pip install
the latest version of PyBaMM which is 21.08 but I get several errors and warnings. I’m using the Miniconda installation of Python. I did not have a problem installing the last version PyBaMM on my computer. So there is something wrong with the installation process for version 21.08.
To Reproduce Steps to reproduce the behaviour:
pip install pybamm
- See errors and warnings shown below.
Collecting pybamm
Using cached pybamm-21.8.tar.gz (889 kB)
ERROR: Command errored out with exit status 1:
command: /opt/miniconda3/bin/python -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/private/var/folders/4q/qh3l23cd6jzdclcq6l_bvzm0kyy0fc/T/pip-install-qx2hel0f/pybamm_e6b5ed7ff70c4a8eb7d01b9468cb7681/setup.py'"'"'; __file__='"'"'/private/var/folders/4q/qh3l23cd6jzdclcq6l_bvzm0kyy0fc/T/pip-install-qx2hel0f/pybamm_e6b5ed7ff70c4a8eb7d01b9468cb7681/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(__file__) if os.path.exists(__file__) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base /private/var/folders/4q/qh3l23cd6jzdclcq6l_bvzm0kyy0fc/T/pip-pip-egg-info-8ujq764a
cwd: /private/var/folders/4q/qh3l23cd6jzdclcq6l_bvzm0kyy0fc/T/pip-install-qx2hel0f/pybamm_e6b5ed7ff70c4a8eb7d01b9468cb7681/
Complete output (5 lines):
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/private/var/folders/4q/qh3l23cd6jzdclcq6l_bvzm0kyy0fc/T/pip-install-qx2hel0f/pybamm_e6b5ed7ff70c4a8eb7d01b9468cb7681/setup.py", line 18, in <module>
import CMakeBuild
ModuleNotFoundError: No module named 'CMakeBuild'
----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/61/0a/f9732746658d728e22282d4b6d2ebd3e50128e6c5d00662fd668e870ccbe/pybamm-21.8.tar.gz#sha256=51af2c85110c948df176f974afe980bb4d34744a3bd03ca0cd29ba965d9d8b64 (from https://pypi.org/simple/pybamm/) (requires-python:>=3.6,<3.10). Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
Using cached pybamm-0.4.0.post1-cp39-cp39-macosx_10_9_x86_64.whl (1.4 MB)
Collecting casadi>=3.5.0
Using cached casadi-3.5.5.post2-cp39-none-macosx_10_13_x86_64.macosx_10_13_intel.whl (21.2 MB)
Requirement already satisfied: scipy>=1.3 in /opt/miniconda3/lib/python3.9/site-packages (from pybamm) (1.7.1)
Requirement already satisfied: pandas>=0.24 in /opt/miniconda3/lib/python3.9/site-packages (from pybamm) (1.3.2)
Collecting jupyter
Using cached jupyter-1.0.0-py2.py3-none-any.whl (2.7 kB)
Collecting pybtex
Using cached pybtex-0.24.0-py2.py3-none-any.whl (561 kB)
Collecting autograd>=1.2
Using cached autograd-1.3-py3-none-any.whl
Collecting anytree>=2.4.3
Using cached anytree-2.8.0-py2.py3-none-any.whl (41 kB)
Collecting scikit-fem>=0.2.0
Using cached scikit_fem-3.2.0-py3-none-any.whl (116 kB)
Requirement already satisfied: numpy>=1.16 in /opt/miniconda3/lib/python3.9/site-packages (from pybamm) (1.20.3)
Collecting jax==0.2.5
Using cached jax-0.2.5-py3-none-any.whl
Requirement already satisfied: matplotlib>=2.0 in /opt/miniconda3/lib/python3.9/site-packages (from pybamm) (3.4.2)
Collecting pybamm
Using cached pybamm-0.4.0-cp39-cp39-macosx_10_9_x86_64.whl (1.4 MB)
Using cached pybamm-0.2.4.post3-py3-none-any.whl (520 kB)
Requirement already satisfied: six>=1.9.0 in /opt/miniconda3/lib/python3.9/site-packages (from anytree>=2.4.3->pybamm) (1.16.0)
Collecting future>=0.15.2
Using cached future-0.18.2-py3-none-any.whl
Requirement already satisfied: kiwisolver>=1.0.1 in /opt/miniconda3/lib/python3.9/site-packages (from matplotlib>=2.0->pybamm) (1.3.1)
Requirement already satisfied: pillow>=6.2.0 in /opt/miniconda3/lib/python3.9/site-packages (from matplotlib>=2.0->pybamm) (8.3.1)
Requirement already satisfied: cycler>=0.10 in /opt/miniconda3/lib/python3.9/site-packages (from matplotlib>=2.0->pybamm) (0.10.0)
Requirement already satisfied: pyparsing>=2.2.1 in /opt/miniconda3/lib/python3.9/site-packages (from matplotlib>=2.0->pybamm) (2.4.7)
Requirement already satisfied: python-dateutil>=2.7 in /opt/miniconda3/lib/python3.9/site-packages (from matplotlib>=2.0->pybamm) (2.8.2)
Requirement already satisfied: pytz>=2017.3 in /opt/miniconda3/lib/python3.9/site-packages (from pandas>=0.24->pybamm) (2021.1)
Collecting meshio>=4.0.4
Using cached meshio-5.0.0-py3-none-any.whl (163 kB)
Collecting jupyter-console
Using cached jupyter_console-6.4.0-py3-none-any.whl (22 kB)
Collecting ipykernel
Using cached ipykernel-6.4.1-py3-none-any.whl (124 kB)
Collecting nbconvert
Using cached nbconvert-6.1.0-py3-none-any.whl (551 kB)
Collecting qtconsole
Using cached qtconsole-5.1.1-py3-none-any.whl (119 kB)
Collecting ipywidgets
Using cached ipywidgets-7.6.4-py2.py3-none-any.whl (121 kB)
Collecting notebook
Using cached notebook-6.4.3-py3-none-any.whl (9.9 MB)
Requirement already satisfied: appnope in /opt/miniconda3/lib/python3.9/site-packages (from ipykernel->jupyter->pybamm) (0.1.2)
Requirement already satisfied: ipython-genutils in /opt/miniconda3/lib/python3.9/site-packages (from ipykernel->jupyter->pybamm) (0.2.0)
Requirement already satisfied: tornado<7.0,>=4.2 in /opt/miniconda3/lib/python3.9/site-packages (from ipykernel->jupyter->pybamm) (6.1)
Collecting jupyter-client<8.0
Using cached jupyter_client-7.0.2-py3-none-any.whl (122 kB)
Requirement already satisfied: traitlets<6.0,>=4.1.0 in /opt/miniconda3/lib/python3.9/site-packages (from ipykernel->jupyter->pybamm) (5.0.5)
Collecting debugpy<2.0,>=1.0.0
Using cached debugpy-1.4.3-cp39-cp39-macosx_10_15_x86_64.whl (1.7 MB)
Requirement already satisfied: matplotlib-inline<0.2.0,>=0.1.0 in /opt/miniconda3/lib/python3.9/site-packages (from ipykernel->jupyter->pybamm) (0.1.2)
Requirement already satisfied: ipython<8.0,>=7.23.1 in /opt/miniconda3/lib/python3.9/site-packages (from ipykernel->jupyter->pybamm) (7.26.0)
Requirement already satisfied: backcall in /opt/miniconda3/lib/python3.9/site-packages (from ipython<8.0,>=7.23.1->ipykernel->jupyter->pybamm) (0.2.0)
Requirement already satisfied: pexpect>4.3 in /opt/miniconda3/lib/python3.9/site-packages (from ipython<8.0,>=7.23.1->ipykernel->jupyter->pybamm) (4.8.0)
Requirement already satisfied: decorator in /opt/miniconda3/lib/python3.9/site-packages (from ipython<8.0,>=7.23.1->ipykernel->jupyter->pybamm) (5.0.9)
Requirement already satisfied: prompt-toolkit!=3.0.0,!=3.0.1,<3.1.0,>=2.0.0 in /opt/miniconda3/lib/python3.9/site-packages (from ipython<8.0,>=7.23.1->ipykernel->jupyter->pybamm) (3.0.17)
Requirement already satisfied: pickleshare in /opt/miniconda3/lib/python3.9/site-packages (from ipython<8.0,>=7.23.1->ipykernel->jupyter->pybamm) (0.7.5)
Requirement already satisfied: jedi>=0.16 in /opt/miniconda3/lib/python3.9/site-packages (from ipython<8.0,>=7.23.1->ipykernel->jupyter->pybamm) (0.18.0)
Requirement already satisfied: setuptools>=18.5 in /opt/miniconda3/lib/python3.9/site-packages (from ipython<8.0,>=7.23.1->ipykernel->jupyter->pybamm) (52.0.0.post20210125)
Requirement already satisfied: pygments in /opt/miniconda3/lib/python3.9/site-packages (from ipython<8.0,>=7.23.1->ipykernel->jupyter->pybamm) (2.10.0)
Requirement already satisfied: parso<0.9.0,>=0.8.0 in /opt/miniconda3/lib/python3.9/site-packages (from jedi>=0.16->ipython<8.0,>=7.23.1->ipykernel->jupyter->pybamm) (0.8.2)
Collecting jupyter-core>=4.6.0
Using cached jupyter_core-4.7.1-py3-none-any.whl (82 kB)
Collecting entrypoints
Using cached entrypoints-0.3-py2.py3-none-any.whl (11 kB)
Collecting pyzmq>=13
Using cached pyzmq-22.2.1-cp39-cp39-macosx_10_15_universal2.whl (2.0 MB)
Collecting nest-asyncio>=1.5
Using cached nest_asyncio-1.5.1-py3-none-any.whl (5.0 kB)
Requirement already satisfied: ptyprocess>=0.5 in /opt/miniconda3/lib/python3.9/site-packages (from pexpect>4.3->ipython<8.0,>=7.23.1->ipykernel->jupyter->pybamm) (0.7.0)
Requirement already satisfied: wcwidth in /opt/miniconda3/lib/python3.9/site-packages (from prompt-toolkit!=3.0.0,!=3.0.1,<3.1.0,>=2.0.0->ipython<8.0,>=7.23.1->ipykernel->jupyter->pybamm) (0.2.5)
Collecting widgetsnbextension~=3.5.0
Using cached widgetsnbextension-3.5.1-py2.py3-none-any.whl (2.2 MB)
Collecting nbformat>=4.2.0
Using cached nbformat-5.1.3-py3-none-any.whl (178 kB)
Collecting jupyterlab-widgets>=1.0.0
Using cached jupyterlab_widgets-1.0.1-py3-none-any.whl (243 kB)
Collecting jsonschema!=2.5.0,>=2.4
Using cached jsonschema-3.2.0-py2.py3-none-any.whl (56 kB)
Collecting attrs>=17.4.0
Using cached attrs-21.2.0-py2.py3-none-any.whl (53 kB)
Collecting pyrsistent>=0.14.0
Using cached pyrsistent-0.18.0-cp39-cp39-macosx_10_9_x86_64.whl (68 kB)
Collecting argon2-cffi
Using cached argon2_cffi-21.1.0-cp35-abi3-macosx_10_14_x86_64.whl (38 kB)
Collecting terminado>=0.8.3
Using cached terminado-0.12.1-py3-none-any.whl (15 kB)
Collecting prometheus-client
Using cached prometheus_client-0.11.0-py2.py3-none-any.whl (56 kB)
Collecting jinja2
Using cached Jinja2-3.0.1-py3-none-any.whl (133 kB)
Collecting Send2Trash>=1.5.0
Using cached Send2Trash-1.8.0-py3-none-any.whl (18 kB)
Requirement already satisfied: cffi>=1.0.0 in /opt/miniconda3/lib/python3.9/site-packages (from argon2-cffi->notebook->jupyter->pybamm) (1.14.6)
Requirement already satisfied: pycparser in /opt/miniconda3/lib/python3.9/site-packages (from cffi>=1.0.0->argon2-cffi->notebook->jupyter->pybamm) (2.20)
Collecting MarkupSafe>=2.0
Using cached MarkupSafe-2.0.1-cp39-cp39-macosx_10_9_x86_64.whl (13 kB)
Collecting defusedxml
Using cached defusedxml-0.7.1-py2.py3-none-any.whl (25 kB)
Collecting bleach
Using cached bleach-4.1.0-py2.py3-none-any.whl (157 kB)
Collecting jupyterlab-pygments
Using cached jupyterlab_pygments-0.1.2-py2.py3-none-any.whl (4.6 kB)
Collecting testpath
Using cached testpath-0.5.0-py3-none-any.whl (84 kB)
Collecting mistune<2,>=0.8.1
Using cached mistune-0.8.4-py2.py3-none-any.whl (16 kB)
Collecting pandocfilters>=1.4.1
Using cached pandocfilters-1.4.3-py3-none-any.whl
Collecting nbclient<0.6.0,>=0.5.0
Using cached nbclient-0.5.4-py3-none-any.whl (66 kB)
Collecting packaging
Using cached packaging-21.0-py3-none-any.whl (40 kB)
Collecting webencodings
Using cached webencodings-0.5.1-py2.py3-none-any.whl (11 kB)
Collecting qtpy
Using cached QtPy-1.11.0-py2.py3-none-any.whl (58 kB)
Installing collected packages: pyrsistent, attrs, pyzmq, nest-asyncio, jupyter-core, jsonschema, entrypoints, webencodings, packaging, nbformat, MarkupSafe, jupyter-client, testpath, pandocfilters, nbclient, mistune, jupyterlab-pygments, jinja2, defusedxml, debugpy, bleach, terminado, Send2Trash, prometheus-client, nbconvert, ipykernel, argon2-cffi, notebook, widgetsnbextension, qtpy, jupyterlab-widgets, qtconsole, meshio, jupyter-console, ipywidgets, future, scikit-fem, jupyter, casadi, autograd, anytree, pybamm
Successfully installed MarkupSafe-2.0.1 Send2Trash-1.8.0 anytree-2.8.0 argon2-cffi-21.1.0 attrs-21.2.0 autograd-1.3 bleach-4.1.0 casadi-3.5.5.post2 debugpy-1.4.3 defusedxml-0.7.1 entrypoints-0.3 future-0.18.2 ipykernel-6.4.1 ipywidgets-7.6.4 jinja2-3.0.1 jsonschema-3.2.0 jupyter-1.0.0 jupyter-client-7.0.2 jupyter-console-6.4.0 jupyter-core-4.7.1 jupyterlab-pygments-0.1.2 jupyterlab-widgets-1.0.1 meshio-5.0.0 mistune-0.8.4 nbclient-0.5.4 nbconvert-6.1.0 nbformat-5.1.3 nest-asyncio-1.5.1 notebook-6.4.3 packaging-21.0 pandocfilters-1.4.3 prometheus-client-0.11.0 pybamm-0.2.4.post3 pyrsistent-0.18.0 pyzmq-22.2.1 qtconsole-5.1.1 qtpy-1.11.0 scikit-fem-3.2.0 terminado-0.12.1 testpath-0.5.0 webencodings-0.5.1 widgetsnbextension-3.5.1
According to pip list
, the version of PyBaMM that is installed appears to be 0.2.4.post3
.
Running a PyBaMM example gives the following module not found error.
Traceback (most recent call last):
File "/Users/g72/Desktop/ORNL/MegaPack/pybamm-examples/example1.py", line 2, in <module>
import pybamm
File "/opt/miniconda3/lib/python3.9/site-packages/pybamm/__init__.py", line 105, in <module>
from .expression_tree.operations.evaluate import (
File "/opt/miniconda3/lib/python3.9/site-packages/pybamm/expression_tree/operations/evaluate.py", line 13, in <module>
import jax
ModuleNotFoundError: No module named 'jax'
Expected behaviour Expected behavior is to install PyBaMM version 21.08 with pip.
Issue Analytics
- State:
- Created 2 years ago
- Comments:5 (1 by maintainers)
Top Results From Across the Web
PyBaMM on Twitter: "Note that the new version is ready to pip ...
In PyBaMM 21.08 you will find: 🔋 Sensitivity analysis of solutions ... Note that the new version is ready to pip install, but...
Read more >Installation problem in workstation · Discussion #2110 - GitHub
I am interested to try installation of PyBamm in my local linux machine version ... ImportError: cannot import name _remove_dead_weakref.
Read more >Install from source (developer install) — PyBaMM 22.11.1 ...
This page describes the build and installation of PyBaMM from the source code, available on GitHub. Note that this is not the recommended...
Read more >pybamm · PyPI
PyBaMM is available on GNU/Linux, MacOS and Windows. We strongly recommend to install PyBaMM within a python virtual environment, in order not to...
Read more >pyBAMM package not available in conda forge channel but its ...
PyBaMM is now available as a conda package through the conda-forge channel on Windows, macOS, and Linux. You can install it by using...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Yes it works now. Looks like pip installs version
21.8.post1
.try
sim.solve([0,3700])
. See the error message at the bottom of your screenshot. I suggest looking at some tutorials on pybamm.org/training