Systematic generalisation with group invariant predictions

Overview

Systematic generalisation with group invariant predictions

Code to accompany https://openreview.net/pdf?id=b9PoimzZFJ.

Requirements and usage

Requirements are Python 3, TensorFlow v1.14, Numpy, Scipy, Scikit-Learn, Matplotlib, Pillow, Scikit-Image, h5py, tqdm. Experiments were run on V100 GPUs (16 and 32GB).

The mnist folder contains code used to run the Coloured-MNIST experiments. The data folder in it contains data generators and includes a sample dataset generation. The inferred partitions that were used are also included in predicted_partitions.

For example, in the mnist folder, you could run

python main.py -method pgi -wc 50.0 -u 5

Use the -v flag when performing validation.

For coco you can create the datasets using the code in data_makers, which will require installing the cocoapi and downloading the Places dataset. A sample of generated COCO datasets can be downloaded here.

For example, in the coco folder, you could run

python main.py -dataset colour -method pgi -wc 100.0 -u 200
python main.py -dataset places -sample normal -method pgi -wc 50.0 -u 200

Citation

BibTex:

@proceedings{ahmed2021systematic,
  title={Systematic generalisation with group invariant predictions},  
  author={Ahmed, Faruk and Bengio, Yoshua and van Seijen, Harm and Courville, Aaron},  
  booktitle={9th International Conference on Learning Representations (ICLR)},  
  year={2021}  
}
You might also like...
Framework that uses artificial intelligence applied to mathematical models to make predictions
Framework that uses artificial intelligence applied to mathematical models to make predictions

LiconIA Framework that uses artificial intelligence applied to mathematical models to make predictions Interface Overview Table of contents [TOC] 1 Ar

Code for sound field predictions in domains with impedance boundaries. Used for generating results from the paper

Code for sound field predictions in domains with impedance boundaries. Used for generating results from the paper

Implementation of the bachelor's thesis "Real-time stock predictions with deep learning and news scraping".

Real-time stock predictions with deep learning and news scraping This repository contains a partial implementation of my bachelor's thesis "Real-time

Stroke-predictions-ml-model - Machine learning model to predict individuals chances of having a stroke

stroke-predictions-ml-model machine learning model to predict individuals chance

A python-image-classification web application project, written in Python and served through the Flask Microframework. This Project implements the VGG16 covolutional neural network, through Keras and Tensorflow wrappers, to make predictions on uploaded images.
The Python ensemble sampling toolkit for affine-invariant MCMC

emcee The Python ensemble sampling toolkit for affine-invariant MCMC emcee is a stable, well tested Python implementation of the affine-invariant ense

《Truly shift-invariant convolutional neural networks》(2021)

Truly shift-invariant convolutional neural networks [Paper] Authors: Anadi Chaman and Ivan Dokmanić Convolutional neural networks were always assumed

Expressive Power of Invariant and Equivaraint Graph Neural Networks (ICLR 2021)
Expressive Power of Invariant and Equivaraint Graph Neural Networks (ICLR 2021)

Expressive Power of Invariant and Equivaraint Graph Neural Networks In this repository, we show how to use powerful GNN (2-FGNN) to solve a graph alig

DIRL: Domain-Invariant Representation Learning
DIRL: Domain-Invariant Representation Learning

DIRL: Domain-Invariant Representation Learning Domain-Invariant Representation Learning (DIRL) is a novel algorithm that semantically aligns both the

Comments
  • question about implementation of pgi loss

    question about implementation of pgi loss

    Hi authors,

    Thanks for this great work!

    I read through your implementation but I am not sure if I understand all details correctly. In the PGI loss code here: https://github.com/Faruk-Ahmed/syst-gen/blob/29d87ae70e608d0159364ee031b83281266c2a65/mnist/main.py#L199-L219, do you compute this loss for batches or for the entire training set? If I understand it correctly, you are optimizing this for data batches, if so, I am wondering whether Eq. 4/5 in the paper holds? I can imagine that Eq. 4/5 should work for the entire dataset if we find the invariant representation across both groups P, Q. But it may or may not be true for each batch (due to random shuffling). If you can share your thoughts that would be great, thank you!

    opened by weiHelloWorld 10
  • Training of Wide-Resnet for Coco datasets

    Training of Wide-Resnet for Coco datasets

    Hi again Faruk!

    When you were training the wideresnet28-4 with the coco colors dataset, did you manage to have a high (>90%) accuracy on the training set? And did you use dropout? I can't go past 68% acc during training, even though the performance on the iid test set is around 80% acc (which is a little strange...). Do you have any suggestion?

    Best regards!

    opened by alceubissoto 2
  • Coco datasets

    Coco datasets

    Greetings! First, thank you for sharing the code of your work! :)

    I would like to ask you if the provided samples to COCO datasets (both color and places) comprehend the full set or just a subset of the data used in the paper's experiments. In case they are not complete, is it possible for you to share them?

    Thanks!

    opened by alceubissoto 1
Owner
Faruk Ahmed
Faruk Ahmed
Wandb-predictions - WANDB Predictions With Python

WANDB API CI/CD Below we capture the CI/CD scenarios that we would expect with o

Anish Shah 6 Oct 7, 2022
noisy labels; missing labels; semi-supervised learning; entropy; uncertainty; robustness and generalisation.

ProSelfLC: CVPR 2021 ProSelfLC: Progressive Self Label Correction for Training Robust Deep Neural Networks For any specific discussion or potential fu

amos_xwang 57 Dec 4, 2022
Image Classification - A research on image classification and auto insurance claim prediction, a systematic experiments on modeling techniques and approaches

A research on image classification and auto insurance claim prediction, a systematic experiments on modeling techniques and approaches

null 0 Jan 23, 2022
Code for paper: Group-CAM: Group Score-Weighted Visual Explanations for Deep Convolutional Networks

Group-CAM By Zhang, Qinglong and Rao, Lu and Yang, Yubin [State Key Laboratory for Novel Software Technology at Nanjing University] This repo is the o

zhql 98 Nov 16, 2022
BC3407-Group-5-Project - BC3407 Group Project With Python

BC3407-Group-5-Project As the world struggles to contain the ever-changing varia

null 1 Jan 26, 2022
naked is a Python tool which allows you to strip a model and only keep what matters for making predictions.

naked is a Python tool which allows you to strip a model and only keep what matters for making predictions. The result is a pure Python function with no third-party dependencies that you can simply copy/paste wherever you wish.

Max Halford 24 Dec 20, 2022
Using python and scikit-learn to make stock predictions

MachineLearningStocks in python: a starter project and guide EDIT as of Feb 2021: MachineLearningStocks is no longer actively maintained MachineLearni

Robert Martin 1.3k Dec 29, 2022
ReConsider is a re-ranking model that re-ranks the top-K (passage, answer-span) predictions of an Open-Domain QA Model like DPR (Karpukhin et al., 2020).

ReConsider ReConsider is a re-ranking model that re-ranks the top-K (passage, answer-span) predictions of an Open-Domain QA Model like DPR (Karpukhin

Facebook Research 47 Jul 26, 2022
Neural Ensemble Search for Performant and Calibrated Predictions

Neural Ensemble Search Introduction This repo contains the code accompanying the paper: Neural Ensemble Search for Performant and Calibrated Predictio

AutoML-Freiburg-Hannover 26 Dec 12, 2022
🔮 Execution time predictions for deep neural network training iterations across different GPUs.

Habitat: A Runtime-Based Computational Performance Predictor for Deep Neural Network Training Habitat is a tool that predicts a deep neural network's

Geoffrey Yu 44 Dec 27, 2022