PyTb (Python Toolbox)¶
This is a collection of useful snippets I find myself to use regularly during prototyping.
Most of the functions are especially useful when working on remote machines via jupyter notebooks (e.g. a JupyterHub) with long-running processes (e.g. Deeplearning).
Checkout the Quickstart section for common usecases and example code.
- Monitor long running tasks and get notified by email if something goes wrong or the job has finished
- Debug Remotely over a TCP connection
- Load Jupyter Notebooks as Python Modules
- Reload modules when importing again (do not cache the result)
- Mirroring all output of a script to a file
- Flexibly test a number possible configurations of a function
- Automatically configure the framework
- Configure defaults
pip install py-toolbox
or via distutils:
git clone https://github.com/dangrie158/py-toolbox.git pytb cd pytb python setup.py install
Clone the repo and install the development requirements. After this you can install the package in development mode to just link the sources into your python path.
git clone https://github.com/dangrie158/py-toolbox.git pytb cd pytb direnv allow # if you're not using direnv, you really should # otherwise create a new virtualenv for the package pip install -r dev-requirements.txt python3 setup.py develop make test
- Command Line Interface
- pytb.config module
- pytb.core module
- pytb.importlib module
- pytb.io module
- pytb.itertools module
- pytb.notification module
- Setup monitoring for your long running tasks
- API Documentation
- pytb.rdb module