Skip to content

hichamjanati/spatio-temporal-alignements

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Spatio-temporal Alignement

Guide to reproduce the results of the paper "Spatio-temporal alignements: Optimal transort through space and time" (https://arxiv.org/abs/1910.03860).

If your platform contains GPUs, please set the number of devices you would like to use in the beginning the scripts run_tsne....

1. Installation

The implementation of the proposed STA is available in the package sta provided in this folder. Before installing it, please make sure you have a miniconda environment installed and the following necessary dependencies (available through pip or conda):

To reproduce the brain imaging experiment, you will also seed the MNE package (available with pip):

If you want 3D visualization of the brain signals, you also need

  • mayavi
  • pysurfer

Then proceed to the sta folder and run:

python setup.py develop

2. Experiments

2.1 theoretical_bound

  • run plot_example.py to produce Figure 2 of the paper.
  • run plot_bound.py to produce the theoretical bound (Figure 3)

2.2 Brain imaging

  1. Make sur mne is installed.
  2. Open run_tsne_brains.py to set the n_gpus and n_jobs params and run it to reproduce Figure 5.
  3. To reproduce Figure 4, verify your installation of mayavi and pysurfer and run plot_brains.py.
    This last step can eventually take time because the MNE-Sample data must be downloaded.

2.3 Handwrittern letters

  1. Run process_chars.py to generate and save the processed data.
  2. Run plot_chars.py to visualize the chars (figure 6)
  3. Open run_tsne_brains.py to set the n_gpus and n_jobs params and to compute and save the tsne maps
  4. run plot_tsne_chars.py to reproduce Figure 7.

About

Spatio-temporal alignements: Optimal transport in space and time

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages