Skip to content

Official implementation of 'The Hammer and the Nut: Is Bilevel Optimization Really Needed to Poison Linear Classifiers?' [Submitted to IJCNN 2021]

Notifications You must be signed in to change notification settings

Cinofix/beta_poisoning

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Introduction

This repository contains the source code to support the paper The Hammer and the Nut: Is Bilevel Optimization Really Needed to Poison Linear Classifiers?, by Antonio Emanuele Cinà, Sebastiano Vascon, Ambra Demontis, Battista Biggio, Fabio Roli and Marcello Pelillo, accepted at IJCNN 2021.

Installation

Please use the command

$ conda env create -f environment.yml

to create the conda environment beta_poison. Then you need to activate the conda env by running conda activate beta_poison

Experiments

The file run_experiments.sh contains a list of commands to replicate the experiments and results proposed in our paper. Output files are, by default, saved in "IJCNN_Experiments/" dir.

MNIST Pairs

Experiments for MNIST Pairs (4 vs. 0 and 9 vs. 8):

$ ./run_experiments.sh mnist_bin

CIFAR-10 Pairs

Experiments for CIFAR-10 Pairs (frog vs. ship and frog vs. horse):

$ ./run_experiments.sh cifar_bin

MNIST TRIPLET

Experiments for MNIST triplet are obtained with:

$ ./run_experiments.sh mnist_triplet

Ablation study

Ablation study evaluates the effect of k (number of prototypes) during the optimization procedure. To run it use:

$ ./run_experiments.sh mnist_ablation # ablation on mnist
$ ./run_experiments.sh cifar_ablation # ablation on cifar

Contact

  • antonioemanuele.cina [at] unive [dot] it

About

Official implementation of 'The Hammer and the Nut: Is Bilevel Optimization Really Needed to Poison Linear Classifiers?' [Submitted to IJCNN 2021]

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published