Public | Automated Build

Last pushed: a month ago
Short Description
Material for the EPFL master course "A Network Tour of Data Science"
Full Description

A Network Tour of Data Science, edition 2016

  (Jupyter lab or notebook)

This repository contains the exercises for the EPFL master course EE-558 A
Network Tour of Data Science
(moodle), taught in autumn 2016. Look at
the 2017 edition for a course more focused on graphs and networks (instead of
deep learning). There is two types of exercises.

The Data Scientist toolkit, a set of tools, mostly in Python, to
help during the Data Science process.

  1. Introduction.
  2. Data acquisition & exploration: demo, exercise, solution.
  3. Data exploitation: demo, exercise, solution.
  4. High Performance Computing: exercise, solution.
  5. Data visualization: exercise, solution.

Machine Learning (ML) & Graph Signal Processing (GSP) algorithms.
These exercises are designed so as to familiarize yourself with the algorithms
presented in class.

  1. Graph Science: exercise, solution.
  2. Clustering: exercise, solution, assignment, solution.
  3. Classification: exercise, solution.
  4. TensorFlow: exercise, solution.
  5. Neural Networks: assignment, solution.
  6. Recurrent Neural Networks: assignment, solution.
  7. Graph Fourier Transform: exercise, solution.
  8. Transductive Learning using Graphs: assignment, solution.


Part of the course is evaluated by a project, proposed and carried out
by groups of one to three students. Below is their work.

Installation with Docker

The easiest way to play with the code is to run it inside a docker container,
a lightweight virtualization method.

  1. Install Docker on your Windows, Mac or Linux machine.

  2. Run the image, which is automatically updated from this git repository.

    docker pull mdeff/ntds_2016  # to update it
    docker run --rm -i -p 8871:8888 -v ~/:/data/mount mdeff/ntds_2016
  3. Access the container's Jupyter notebook at http://localhost:8871. There
    you'll find two folders:

    • repo contains a copy of this git repository. Nothing you modify in this
      folder is persistent. If you want to keep your modifications, use File,
      Download as, Notebook in the Jupyter interface.
    • mount contains a view of your home directory, from which you can
      persistently modify any of your files.

    Windows and Mac users may need to redirect the port in

Container modification

If you want to use it for your projects and need additional software or Python
packages, you'll need to install them into the container.

  1. Create your named container.

    docker run -i -p 8871:8888 -v ~/:/data/mount --name myproject mdeff/ntds_2016
  2. Once you stop it, you'll be able to start it again with docker start myproject.

  3. In another terminal, install packages while the container is running.

    docker exec -i myproject /bin/bash
    pip install mypackage
    apt-get install myotherpackage

Manual installation

Warning: this may be problematic for Windows users, as TensorFlow does not
support Windows yet.

  1. Install Python.

    • Windows: we recommend to install Anaconda. Please install version 3.5.
      Most of the packages we'll use during the exercises are included in the
      distribution. An other option is the Windows Subsystem for Linux,
      available on Windows 10, which allows you to install packages as if you
      were on Ubuntu.
    • Mac: we recommend that you use the Homebrew package manager and install
      Python with brew install python3. You can also use Anaconda.
    • Linux: please use your package manager to install the latest Python 3.x.
  2. Clone the course repository. You may need to first install git.

    git clone
    cd ntds_2016
  3. Optionally, create a virtual environment.

    pyvenv /path/to/new/virtual/env
    . /path/to/new/virtual/env/bin/activate

    A virtual environment allows you to install a different set of packages for
    each of your Python project. Each project thus stays cleanly separated from
    each other. It is a good practice but by no means necessary. You can read
    more about virtual environments on this blog post. Anaconda
    users, see here.

  4. Install the packages we'll use from PyPI, the Python Package Index.

    pip install -r requirements.txt  # or make install
    • If it fails, it is probably because you need to install some native
      packages with your package manager. Please read the error messages and
      remember, Google is your friend ! You may look at the
      dockerfile to get an idea of which setup is necessary on
      a Debian / Ubuntu system.

    • Depending on your installation, pip may refer to Python 2 (you can
      verify with pip -V). In that case, use pip3 instead of pip.

    • Anaconda users can also install packages with conda install packname.
      See here for your options.

  5. Verify that you have a working installation by running a simple test.
    Again, you may need to call python3.

    python  # or make test
    • If you are on Windows with Anaconda and get
      WARNING (theano.configdefaults): g++ not detected!, you may want to
      install mingw-w64 with conda install mingw libpython. Otherwise your Deep Learning models will run extremly slowly.
      This may however not work for Python 3.5, see this GitHub
      for a workaround.
  6. Open the jupyter web interface and play with the notebooks !

    jupyter notebook


All codes and examples are released under the terms of the MIT

Docker Pull Command
Source Repository