skorch: A scikit-learn compatible neural network library that wraps pytorch
Benjamin Bossan
Scikit-learn is the most widely used general purpose machine learning library in Python. It has a very nice API and many tools are built around it, but its support for neural networks is very limited.
PyTorch is a deep learning platform that makes working with neural networks a blast. However, users often find that they need to write boilerplate and wrapper code to integrate PyTorch into their existing workflows.
A possible solution to those problems is skorch. This open source Python library allows you to easily wrap your PyTorch modules to give them a high level sklearn API. This allows you to:
- tap into the power and flexibility of PyTorch
- get rid of most of the boring boilerplate code
- combine PyTorch nets with the usual sklearn goodies like
Pipeline
s,GridSearchCV
, etc.
Ideally, you already have some basic knowledge of sklearn and PyTorch, or are an advanced user of one of the two libraries who is curious about improving your workflow.