minimal deep learning framework
Project description
Nimrod
Description
This is a repo with minimal tooling, modules, models and recipes to get easily get started with deep learning training and experimentation with an emphasis on speech, audio and language modeling.
Install
you need python <3.12
Install using Pip
Install package:
pip install slg-nimrod
Install espeak for LM:
brew install espeak #macos
Install Spacy english model
python -m spacy download en_core_web_sm
Usage
Download test data on which to run example recipes:
# if not already installed on your system
git lfs install
# update changes
git lfs fetch --all
# copy the actual data
git lfs checkout
# or just
git lfs pull # combing both steps above into one (like usual git pull)
Check recipes in recipes/
folder. E.g. for a simple digit recognizer
on MNIST:
git clone https://github.com/slegroux/nimrod.git
cd nimrod/recipes/images/mnist
python train.py datamodule.num_workers=8 trainer.max_epochs=20 trainer.accelerator='mps' loggers='tensorboard'
head conf/train.yaml
All the parameters of the experiment are editable and read from a .yaml file which details:
- data and logging directory paths
- data module with data source path and batching parameters
- model architecture
- trainer with hardware acceleration and number of epochs
- callbacks for early stopping and automatic logging to Wandb
Docker
You might want to use docker containers for reproductible development environment or run your project in the cloud
make container
docker pull slegroux/nimrod
docker run -it --rm -p 8888:8888 slegroux/nimrod /bin/bash
You can also use docker-compose to define services and volumes
cd .devcontainer
docker-compose up
docker-compose down
Develop
pip install -e .
Hyperparameter tuning
to compare training results on different model parameters:
cd nimrod/recipes/images/mnist
python train.py --multirun model.n_h=16,64,256 loggers='tensorboard' trainer.max_epochs=5
Server
st webapp
Run a simple digit recognizer webapp with GUI
cd server
./run_st_app.sh
Authors
2023 Sylvain Le Groux sylvain.legroux@gmail.com
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file slg_nimrod-0.0.9.tar.gz
.
File metadata
- Download URL: slg_nimrod-0.0.9.tar.gz
- Upload date:
- Size: 65.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.11.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 47b189a3aa807a5e065488be722dc61136f9b9c21f051da7b16a9289e6337397 |
|
MD5 | b3d85971650a7e872d1f6316e3d93da4 |
|
BLAKE2b-256 | 00c41b45a4ff8f1ae05c9ce6922bc8315b1a36c1c2976846308b44809879e079 |
File details
Details for the file slg_nimrod-0.0.9-py3-none-any.whl
.
File metadata
- Download URL: slg_nimrod-0.0.9-py3-none-any.whl
- Upload date:
- Size: 82.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.11.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e8de0272b04a220696b1c10ad6b368e390253a439e6378480e254ca729fcaae4 |
|
MD5 | cd641a65f9aae34de8c88c37b8535ea1 |
|
BLAKE2b-256 | 226636cfd58efad60ec996243747012bbf5203ab4cd4aa0f10267f0ea6f733eb |