days
-1
-7
hours
0
-2
minutes
-4
-8
seconds
-3
-7
search
Furthering research efforts

Reproduce machine learning results with pre-trained models in PyTorch Hub

Sarah Schlothauer
pytorch
© Shutterstock / Quon_ID

PyTorch offers a new API that will help machine learning researchers to reproduce research results. PyTorch Hub supports the publication of pre-trained models in order to help facilitate more transparent ML research. Do you have a pre-trained model that you wish to submit? PyTorch Hub accepts contributions.

Facebook’s open source deep learning platform Pytorch has been on the up and up, with a recent May update improving JIT compilation and offering TensorBoard support.

PyTorch unveiled some news regarding open and reproducible research.

Currently, in beta phase, meet PyTorch Hub. According to its documentation, it is a “pre-trained model repository designed to facilitate research reproducibility“. This API and workflow allow for easier, more transparent reproducibility, which is an important part of machine learning and reliable data science.

ML research reproducibility

From the announcement blog: “As a user, PyTorch Hub allows you to follow a few simple steps and do things like: 1) explore available models; 2) load a model; and 3) understand what methods are available for any given model.”

It also comes with built-in support and integration for Papers with Code and Google’s Colab, two free-to-use deep learning resources.

SEE ALSO: Create interactive data-exploration tools and web apps with Python in Panel

Machine learning researchers can explore through a variety of pre-trained models, including: BERT, Deeplabv3-ResNet101, U-Net for brain MRI, and more.

More models to come as the project grows more mature. See them at Papers With Code, which offers free and open source papers, code, and evaluation tables. See an example of how Papers With Code works. Google Colab example also available here.

Users can load pre-trained models using a single command and the torch.hub.load() API.

Join the hub

Users are free to contribute their own models if they use public data, not private. Have a pre-trained model that you would like to submit to further ML reproducibility efforts and potentially help further research? Find out how to submit and create a pull request via GitHub. Host your models either on a cloud or on GitHub.

PyTorch Hub supports publishing pre-trained models (model definitions and pre-trained weights) to a GitHub repository by adding a simple hubconf.py file.

SEE ALSO: Pythia: Facebook’s deep learning framework for the vision and language domain

For developers, ML plug-and-play models are slated for arrival in the future.

Upcoming changes also include the addition of an upvote/downvote system for models so that users can vote on the most useful or relevant.

Refer to the full documentation for PyTorch Hub and find out more about running a loaded model.

Author
Sarah Schlothauer

Sarah Schlothauer

All Posts by Sarah Schlothauer

Sarah Schlothauer is an assistant editor for JAXenter.com. She received her Bachelor's degree from Monmouth University and is currently enrolled at Goethe University in Frankfurt, Germany where she is working on her Masters. She lives in Frankfurt with her husband and cat.

Leave a Reply

Be the First to Comment!

avatar
400
  Subscribe  
Notify of