THIS VERSION OF THE SCATTERING IS OBSOLETE
Please check out our new version (pytorch): https://github.com/edouardoyallon/pyscatwave - any version of the Scattering Transform in lua can be considered as obsolete.
ScatWave is a Torch implementation of 2D scattering using CUDA libraries, designed for images.
This software belongs to the team DATA @ ENS, its main author is Edouard Oyallon.
Assuming Torch is already installed on your computer, simply cd in scatwave_pkg, then 'luarocks make' Make sure you have FFTW and cuFFT installed and that the libraries are linked to the software.
ScatWave + 3FC = 83.0 on CIFAR 10
ScatWave + 3FC = 56.7 on CIFAR 100
ScatWave + Deepnet = 91.4% on CIFAR10
ScatWave + Deepnet = 69.5% on CIFAR100
scatwave = require 'scatwave'
x=torch.FloatTensor(128,3,32,32)
scat = scatwave.network.new(3,x:size())
scat_coeff = scat(x) -- or scat(x,1)
You can go to cuda via:
scat=scat:cuda()
-
Data can be downloaded from this page: https://github.com/szagoruyko/wide-residual-networks/blob/master/README.md.
The whitened versions work quite better and are used in this work. -
training the network on cifar10:
th train_cifar10.lua -
training the network on cifar100:
th train_cifar100.lua -
transfering to matlab F1:
th get_F1.lua -
analysing the operator:
matlab sparsify_F1.m -
retraining the deepnet with a new F1:
th retrain_with_fix_F1_pretrained_end_cifar10.lua -
replace the scattering by a deepnet with a pretrained and fixed model:
th replace_scattering_fix_end_cifar10.lua
Edouard Oyallon. Contacts: firstname.lastname@ens.fr
Team DATA - Ecole Normale Supérieure
The author is thankful to Sergey Zagoruyko for helpfull discussions, codes and enlightments. Many parts of this work are based on codes that he shared, and this had a major impact on this work. I would like to thank also Mathieu Andreux, Eugene Belilovsky, Carmine Cella, Michael Eickenberg for helpful discussions.