Package: slp
slpRepo:https://github.com/georgepar/slpDocumentation:https://georgepar.github.io/slp/latest/slp is a framework for fast and reproducible development of multimodal models, with emphasis on
NLP models.It started as a collection of scripts and code I wrote / collected during my PhD and it evolves
accordingly.As such, the framework is opinionated and it follows a convention over configuration approach.A heavy emphasis is put on:Enforcing best practices and reproducibility of experimentsMaking common things fast at the top-level and not having to go through extensive configuration optionsRemaining extendable. Extensions and modules for more use cases should be easy to addOut of the box extensive logging and experiment managementSeparating dirty / scratch code (at the script level) for quick changes and clean / polished code at the library levelThis is currently in alpha release under active development, so things may break and new features
will be added.DependenciesWe usePytorch(1.7) and the following librariesPytorch Lightninghuggingface/transformersWandbPython 3.8InstallationYou can use slp as an external library by installing from PyPI withpip install slpOr you can clone it from githubgit clone git@github.com:georgepar/slpWe usepoetryfor dependency managementWhen you clone the repo run:pipinstallpoetry
poetryinstalland a clean environment with all the dependencies will be created.
You can access it withpoetry shell.Note: Wandb logging is enabled by default. You can eitherCreate an account and runwandb loginwhen you clone the repo in a new machine to store the results in the online managed environmentRunwandb offlinewhen you clone the repo to disable remote sync or use the--offlinecommand
line argument in your scriptsUse one of their self-hosted solutionsCreate a new project based on slpYou can use the template athttps://github.com/georgepar/cookiecutter-pytorch-slpto create a new project based on slppip install cookiecutter poetry
cookiecutter gh:georgepar/cookiecutter-pytorch-slp
# Follow the interactive configuration and a new folder with the project name you provided will appear
cd $PROJECT_NAME
poetry install  # Installs slp and all other dependenciesAnd you are good to go. Follow the instructions in the README of the new project you created. Happy codingContributingYou are welcome to open issues / PRs with improvements and bug fixes.Since this is mostly a personal project based around workflows and practices that work for me, I don't guarantee I will accept every change, but I'm always open to discussion.If you are going to contribute, please use the pre-commit hooks underhooks, otherwise the PR will not go through the CI. And never, ever touchrequirements.txtby hand, it will automatically be exported frompoetrycat<<EOT >> .git/hooks/pre-commit#!/usr/bin/env bashbash hooks/export-requirements-txtbash hooks/checksEOTchmod+x.git/hooks/pre-commit# Keep an up-to-date requirements.txt and run Linting, typechecking and testsln-s$(pwd)/hooks/commit-msg.git/hooks/commit-msg# Sign-off your commitCiteIf you use this code for your research, please include the following citation@ONLINE {,
    author = "Georgios Paraskevopoulos",
    title  = "slp",
    year   = "2020",
    url    = "https://github.com/georgepar/slp"
}RoadmapOptuna integration for hyperparameter tuningAdd dataloaders for popular multimodal datasetsAdd multimodal architecturesAdd RIM, DNC and Kanerva machine implementationsWrite unit tests