Snakefile 1.2 KB

123456789101112131415161718192021222324
  1. # This Snakefile run the SPADE analysis for all the possible configurations of simulators and hours from which the simulated spike data where recorded
  2. simulators = ['SpiNNaker', 'C']
  3. hours = range(1,6)
  4. # Summoning all the output files
  5. rule all:
  6. input:
  7. expand('patterns_results/iteration_III/60s_simulation_runs/{simulator}/out_firings_after{hour}h/patterns.npy', simulator=simulators, hour=hours),
  8. expand('../simulation_data/iteration_III/60s_simulation_runs/{simulator}/out_firings_after{hour}h.dat', simulator=simulators, hour=hours)
  9. # Tocken rule to check the simulated data exist
  10. rule check_data:
  11. output:
  12. protected('../simulation_data/iteration_III/60s_simulation_runs/{simulator}/out_firings_after{hour}h.dat')
  13. # Rule to pass to spade_analysis.py all the combinations of the parameters simulator and hour
  14. rule analyze_data:
  15. input:
  16. data=protected('../simulation_data/iteration_III/60s_simulation_runs/{simulator}/out_firings_after{hour}h.dat'),
  17. script='spade_analysis.py'
  18. output:
  19. 'patterns_results/iteration_III/60s_simulation_runs/{simulator}/out_firings_after{hour}h/patterns.npy'
  20. shell:
  21. 'python spade_analysis.py {wildcards.simulator} {wildcards.hour}'