Skip to content

bertinetto/r2d2

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Code for the ICLR'19 paper "Meta-learning with differentiable closed-form solvers".

-----------------Work in progress-------------------

Paper

Please refer to it as:

@inproceedings{
bertinetto2018metalearning,
title={Meta-learning with differentiable closed-form solvers},
author={Luca Bertinetto and Joao F. Henriques and Philip Torr and Andrea Vedaldi},
booktitle={International Conference on Learning Representations},
year={2019}
}

Data setup

  • In scripts/train/conf/fewshots.yaml, specify the location of your custom $DATASET_PATH (data.root_dir).
  • Download Omniglot, CIFAR-FS and miniImageNet the above format. Original datasets from here and here.
  • Download and extract one or more datasets in your custom $DATASET_PATH folder, the code assumes the following structure (example):
$DATASET_PATH
├── miniimagenet
│   ├── data
│   │   ├── n01532829
|   |   |── ...
│   │   └── n13133613
│   ├── splits
│   │   └── ravi-larochelle
|   |   |   ├── train.txt
|   |   |   ├── val.txt
|   |   |   └── test.txt
├── omniglot
|   ...
├── cifarfs 
|   ...

Repo setup (with Conda)

  • Set up conda environment: conda env create -f environment.yml.
  • source activate fsrr
  • Install torchnet: pip install git+https://github.com/pytorch/tnt.git@master.
  • Install the repo package: pip install -e .
  • source deactivate fsrr
Note

Some of the files of this repository (e.g. data loading and training boilerplate routines) are the result of a modification of prototypical networks code and contain a statement in their header.