dp is a deep learning library designed for streamlining research and development using the Torch7 distribution. It emphasizes flexibility through the elegant use of object-oriented design patterns.
During my time in the LISA Lab as an apprentice of Yoshua Bengio and Aaron Courville, I was inspired by pylearn2 and Theano to build a framework better suited to my needs and style.
Among other things, this package includes :
- common datasets like MNIST, CIFAR-10 and CIFAR-100, preprocessing like Zero-Component Analysis whitening, Global Contrast Normalization, Lecun's Local Contrast Normalization, and facilities for interfacing your own.
- a high-level framework that abstracts away common usage patterns of the nn and torch7 package such as loading datasets and early stopping.
- hyperparameter optimization facilities for sampling and running experiments from the command-line or prior hyper-parameter distributions.
- facilites for storing and analysing hyperpameters and results using a PostgreSQL database backend which facilitates distributing experiments over different machines.
A Facial Keypoints tutorial involving the case study of a Kaggle Challenge is also available. It provides an overview of the steps required for extending and using dp in the context of the challenge. And even provides the script so that you can generate your own Kaggle submissions.
## dp Packages ##- Data Library
- View : Tensor containers like DataView, ImageView and ClassView;
- BaseSet : View containers like Batch and DataSet;
- DataSource : BaseSet containers like Mnist and BillionWords;
- Preprocess : data preprocessing like ZCA and Standardize;
- Sampler : DataSet iterators like ShuffleSampler and SentenceSampler;
- Node Library
- Node : abstract class that defines Model and Loss commonalities;
- Model : parameterized Nodes like Neural and Convolution2D that adapt Modules to Model;
- Loss : non-parameterized Nodes like NLL that adapt Criterions;
- Experiment Library
- Experiment : trains a Model using a DataSource and a Loss;
- Propagator : propagates a DataSet through a Model and Loss;
- Visitor : visits Models after a backward pass to update parameters, statistics or gradients;
- Extension Library
- Hyperparameter Library
- Hyperoptimizer : explores different experiment configurations;
- DatasourceFactory : builds a datasource;
- ExperimentFactory : builds an experiment and Model.
For CUDA:
$> sudo luarocks install cunnx
For LAPACK (then recompile torch):
$> sudo apt-get install liblapack-dev
For PostgresSQL:
$> sudo apt-get install libpq-dev
$> sudo luarocks install luasql-postgres PGSQL_INCDIR=/usr/include/postgresql
$> sudo apt-get install liblapack-dev
We appreciate issues and pull requests of all kind.