README.txt 2.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  2. Instructions to reproduce all main text, supplementary and mathematical appendix figures of the manuscript
  3. "Learning accurate path integration in ring attractor models of the head direction system".
  4. Instructions are based on default values of various parameters. After generating figures, please remember
  5. to revert parameters to these default values.
  6. The figures are reproduced from saved networks. In order to generate the results from scratch, execute
  7. run_simulation.py with the desired parameters for each figure mentioned below. Simulation takes ~8 hours
  8. on a mid-range gaming laptop, while the reduced network drastically reduces simulation time to ~3 minutes.
  9. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  10. - Fig. 1B,C, 2A-C, 3A-C,E,F, S3: Run generate_plots.py with vel_hist = True.
  11. - Fig. 2D: Run stability.py.
  12. - Fig. 3D, 4, S5E, S6A-C, S7A: Run multinet_plots.py. The diffusion coefficients for Fig. S5E were obtai-
  13. ned by running stability.py with d_coeff = True for the corresponding networks.
  14. - Fig. S1: Run EB_synapses.py. The upper-left panel in Fig. S1A also appears in Fig. 1E.
  15. - Fig. S2: Run generate_plots.py with cut_exc = True.
  16. - Fig. S4: Run generate_plots.py with data_dir = '\\savefiles\\trained_networks\\Parallel\\Perturb_Conn\\'.
  17. The networks were randomly generated, therefore results can vary. By varying the parameter 'run' in the
  18. dictionary params from 0 to 11, one can see multiple examples of such networks.
  19. - Fig. S5A-D: Run generate_plots.py with 'n_sigma': 0.7 in the dictionary params.
  20. - Fig. S6D,E: Run generate_plots.py with sim_run = '4Medium', PI_err = False and 'tau_s': 1 in the dictio-
  21. nary params.
  22. - Fig. S7B: Run generate_plots.py with PI_err = False, and 'gain': .125 in the dictionary params.
  23. - Fig. S7C: Run generate_plots.py with PI_err = False and 'gain': 10 in the dictionary params. Also plot
  24. margins in lines 761 and 766 need to be adjusted.
  25. - Fig. S7D-F: Run generate_plots.py with PI_err = False, sim_run = 'Long', and 'gain': -1 in the dictiona-
  26. ry params.
  27. - Fig. S8: Run generate_plots.py with 'vary_w_rot': True and 'adj': True in the dictionary params.
  28. - Fig. S9: Run generate_plots.py with PI_example_dir = '\\savefiles\\PI_example1.npz', 'vary_w_rot': True
  29. in the dictionary params and filename = "fly_rec" + util.filename(params) + 'NoLearn'. Also set
  30. err_lim = 180 in line 487.
  31. - Fig. S10: Run generate_plots.py with PI_example_dir = '\\savefiles\\PI_example_360_max.npz', PI_err =
  32. False, and 'rand_w_rot': True in the dictionary params.
  33. - Fig. A1-4: Run math_appendix.py.