28 mai 2018 à 1 juin 2018
Fuseau horaire Europe/Paris

Hands-on session preparation *before coming*

Hands-on session preparation before coming!

The school will be more profitable if you can run yourself the code during the hands-on session. In some cases (Amir’s session), the code would run on an outside server, in some other cases (Gilles’ session) you will run the code on your laptop.

Given that the wifi will be somewhat limited and in order to save time on the session themselves, we recommend that participants come with their laptop already properly configured:

  • with a Terminal emulator (to connect e.g. to CERN public unix cluster lxplus.cern.ch, just an example we will not use lxplus)
  • with anaconda3 installation (see below)

Anaconda3 installation

We recommend to install anaconda3 https://www.anaconda.com/download which includes the most common Machine Learning software suite (like sci-kit learn, matplotlib). We will use python 3 version; the most notable non backward compatible difference of python3 vs python2 which is still used in large collaboration is the print statement: print “a=’,a becomes print (“a=”,a).

 

To test it:

  • download Gilles’ old lectures (just for test)

https://github.com/glouppe/tutorials-scikit-learn

  • open notebook 1.%20An%20introduction%20to%20Machine%20Learning%20with%20Scikit-Learn.ipynb  

Two techniques to do this:

  • easiest:

    • start the application Anaconda-Navigator,

    • select Jupyter Notebook,

    • navigate to lectures-iccub-2016/lec1,

    • click on Introduction to Scikit-Learn.ipynb

  • recommended :

    • open a terminal

    • cd to lectures-iccub-2016/lec1

    • start the notebook by typing : jupyter notebook

    • if jupyter is not known, make sure anaconda3 installation is in your PATH with something like : export PATH="/Users/rousseau/anaconda3/bin:$PATH"

    • click on Introduction to Scikit-Learn.ipynb in the tab that opened in you browser

Execute the notebook. For the very basics of Jupiter notebook interactivity, please check this short video

  • Recommended method
    • click on first cell (the title!)

    • execute each cell by typing Shift-return repetitively. For non trivial cells with code, you'll see it takes a bit or more time to recompute the output

    • all cells should execute correctly (albeit taking some times) except :

      • cell 3 %%javascript fail

      • cell 8 trying to get a root file

      • cell 9 running root_numpy

Please send mail to David Rousseau rousseau@lal.in2p3.fr if you have difficulties with installation and test run.