Sumatra: an electronic labook. Git it right
Michele Mattioni
Computational Neurobiology group
mattioni@ebi.ac.uk




     ...
Open questions which I had no answer:



•   Where are my results?
•   Which parameters I used on that simulation?




   ...
How the experimental people solve that?
• Write down on a labbook everything they do :
   •   reagents
   •   times
   •  ...
We need an electronic labbook
• Able to track (automatically) our 'experiments' details:
   •   script launched
   •   par...
Say hello to Sumatra




               http://neuralensemble.org/trac/sumatra




        Slide from Andrew Davison (main...
Sumatra: what I need to use it
• Code under version control
   • Accepted version control:
      • Mercurial (hg)

      •...
smt Usage


                 $ cd myproject
                 $ smt init MyProject

            Normal way you launched the...
Shorter cmdline to launch the job


                         From
$ smt run ­­simulator=python ­­main=main.py default.para...
What if I use java?


         $ java main default.param


$ smt run ­­simulator=java ­­main=main default.param
Parameter file? Excuse me?

        Basically a name <-> parameter pair
 dt = 0.05 # Dt for the integration
 tstop = 10 # ...
Where is my stuff?
     smt monitor a directory (default Data).
    • Any new file/image saved there is automatically adde...
Access the results: smt
$ smt list 
default_20100407­163228
default_20100407­171249

$ smt list ­l 
Label        : default...
Access the results: smtweb
Access the results: smtweb
Accessing the plot from the link
How to install

ATM: Git support only available from the latest code:


hg clone https://neuralensemble.org/hg/sumatra

gi...
How sumatra saved the day (yesterday)

Scenario:
• Made some massive restructuring/refactoring on neuronvisio
• Get lost o...
Searched the last simulation where it worked
Selected the latest working, and neuronvisio ver.
Find that commit on neuronvisio repo
Branched it
Merged restart back into master




                  kind of apply twice the same patch, but you
                  know i...
Summary
• Sumatra can help you to:
   •   keep your stuff organized
   •   not lose your work
   •   speed up the recovery...
Acknowledgement
•   Andrew Davison (main sumatra developer)
•   people got the picture from (link on each picture)
•   Nic...
Got questions?




       http://neuralensemble.org/trac/sumatra
Sumatra and git
Upcoming SlideShare
Loading in …5
×

Sumatra and git

2,402 views

Published on

Sumatra is a System Management Tool to keep track of your simulation results. Now it has also git support.

Published in: Education
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
2,402
On SlideShare
0
From Embeds
0
Number of Embeds
1,134
Actions
Shares
0
Downloads
9
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

Sumatra and git

  1. 1. Sumatra: an electronic labook. Git it right Michele Mattioni Computational Neurobiology group mattioni@ebi.ac.uk EBI is an Outstation of the European Molecular Biology Laboratory.
  2. 2. Open questions which I had no answer: • Where are my results? • Which parameters I used on that simulation? http://www.flickr.com/photos/valeriebb/3006348550/ • Which one was that simulation? • Why it worked yesterday and not today? From Valerie Everett's photostream • At exactly which point it worked yesterday? • Where is my mind stuff?
  3. 3. How the experimental people solve that? • Write down on a labbook everything they do : • reagents • times • protocols why! http://www.flickr.com/photos/mwichary/3249202959/ • • what worked, what didn't • ... Marcin Wichary's photostream
  4. 4. We need an electronic labbook • Able to track (automatically) our 'experiments' details: • script launched • parameters used • reason • outcome • But we can also: • search them • organize them • Rerun them!
  5. 5. Say hello to Sumatra http://neuralensemble.org/trac/sumatra Slide from Andrew Davison (main developer), http://neuralensemble.org/meetings/talks/CodeJam3_Davison_Sumatra.pdf
  6. 6. Sumatra: what I need to use it • Code under version control • Accepted version control: • Mercurial (hg) • Subversion (svn) • Git (git) (I patched it! Power of the opensource..) • your choice (exstensible architeture) • Scripts organized as Main class and parameter_file
  7. 7. smt Usage $ cd myproject $ smt init MyProject Normal way you launched the script: $ python main.py default.param New way using Sumatra: $ smt run ­­simulator=python ­­main=main.py default.param
  8. 8. Shorter cmdline to launch the job From $ smt run ­­simulator=python ­­main=main.py default.param Configure it (it has to be done once.) $ smt configure ­­simulator=python ­­main=main.py To $ smt run default.param
  9. 9. What if I use java? $ java main default.param $ smt run ­­simulator=java ­­main=main default.param
  10. 10. Parameter file? Excuse me? Basically a name <-> parameter pair dt = 0.05 # Dt for the integration tstop = 10 # [ms] Not obligatory, but it's very handy because: • Sumatra can store your parameters in the record • If Sumatra understand them then You can change parameter on the fly $ smt run default.param tstop=20 dt=0.01
  11. 11. Where is my stuff? smt monitor a directory (default Data). • Any new file/image saved there is automatically added to the simulation record You save the results Sumatra remembers where is it My way: I create a dir for each day and then save all my stuff in dedicated folder • Data/19­04­2010/Sim_1/, Data/19­04­2010/Sim_2/ • Data/20­04­2010/Sim_1/, Data20­04­2010/Sim_2/
  12. 12. Access the results: smt $ smt list  default_20100407­163228 default_20100407­171249 $ smt list ­l  Label        : default_20100420­170241 Reason       : Testing the tagging from the cmdline Outcome      : It works! Duration     : 4.38211798668 Repository   : GitRepository at  /home/mattions/Work/model/MSN/TimeScales Main_File    : spineIntegration.py Version      : 8a61ecdd999e30d25c29620a87d9f4536aa67e9e Executable   : Python (version: 2.6.4) at /usr/bin/python Timestamp    : 2010­04­20 17:02:41.445588 Tags         : test, test2
  13. 13. Access the results: smtweb
  14. 14. Access the results: smtweb
  15. 15. Accessing the plot from the link
  16. 16. How to install ATM: Git support only available from the latest code: hg clone https://neuralensemble.org/hg/sumatra git clone http://github.com/mattions/sumatra_on_github
  17. 17. How sumatra saved the day (yesterday) Scenario: • Made some massive restructuring/refactoring on neuronvisio • Get lost on the way • Nothing worked anymore. But ...
  18. 18. Searched the last simulation where it worked
  19. 19. Selected the latest working, and neuronvisio ver.
  20. 20. Find that commit on neuronvisio repo
  21. 21. Branched it
  22. 22. Merged restart back into master kind of apply twice the same patch, but you know it was worth it.
  23. 23. Summary • Sumatra can help you to: • keep your stuff organized • not lose your work • speed up the recovery time when somethig get wrong • remember what you used ages ago, to make that figure • be more focus on your science. • You can help sumatra • Using it • Asking for request (ok, send a patch. It's quicker and easier)
  24. 24. Acknowledgement • Andrew Davison (main sumatra developer) • people got the picture from (link on each picture) • Nicolas Le Novère (to let me work on this) • Computational Neurobiology group @ EBI.
  25. 25. Got questions? http://neuralensemble.org/trac/sumatra

×