IPython extension type-checking IPython environments with beartype.
pip install ipython_beartype
Within an IPython / Jupyter notebook session, do the following:
%load_ext ipython_beartype
%beartype
All the type annotations in the following cells will be type checked.
- Create and activate a virtual environment
- Run
pip install -e .[dev]
to do an editable install - Run
pytest
to run tests
Run mypy .
Thanks to knyazer and
patrick-kidger for building the jaxtyping
IPython extension, which was used as the base for this extension.
Also special thanks to leycec for creating beartype and the IPython team.