Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/carlthome/ipytoolbox
A collection of IPython magics and other utilities
https://github.com/carlthome/ipytoolbox
ipython jupyter matplotlib numpy
Last synced: 29 days ago
JSON representation
A collection of IPython magics and other utilities
- Host: GitHub
- URL: https://github.com/carlthome/ipytoolbox
- Owner: carlthome
- License: agpl-3.0
- Created: 2023-12-12T20:04:23.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2024-04-18T18:17:17.000Z (9 months ago)
- Last Synced: 2024-11-14T18:47:44.370Z (2 months ago)
- Topics: ipython, jupyter, matplotlib, numpy
- Language: Jupyter Notebook
- Homepage:
- Size: 143 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# ipytoolbox
A collection of IPython magic commands and other utilities.
## Features
### `%autocuda`
- A line magic to automatically select the local CUDA device(s) with the most free memory.### `%%animate`
- A cell magic to automatically capture `plt.plot(); plt.show()` calls and display them as an animation once the cell has finished executing.
[Example notebook](./notebooks/demo.ipynb)
## Install
First make sure Python is installed, then run:
```sh
pip install ipytoolbox
```Then you can use it in IPython or Jupyter Notebooks by
```ipython
%load_ext ipytoolbox
```## Develop
First clone the repo and set it as working directory. Then install the package in development mode (preferably within its own virtual environment):
```sh
pip install -e ".[tests]"
```If you have `direnv` installed, you can run `direnv allow` to automatically create and activate a Python virtual environment when you enter the directory.
### Test
```sh
pytest
```### Lint
```sh
pre-commit run --all-files
```Or `pre-commit install` to run automatically on `git commit`.
### Publish
```sh
gh release create
```