Upgrade to Pro — share decks privately, control downloads, hide ads and more …

PyCon Italy 2018 - Practical Machine Learning w...

PyCon Italy 2018 - Practical Machine Learning with Python and scikit-learn

A tutorial for intermediate Python developers with none or little knowledge about Machine Learning.

Andrea Grandi

April 22, 2018
Tweet

More Decks by Andrea Grandi

Other Decks in Technology

Transcript

  1. WHO AM I • Andrea Grandi • I live in

    London (UK) • Software Developer at Government Digital Service • Python/Django developer • passionate about micro controllers, IoT, Arduino, Golang and machine learning
  2. WHAT YOU ARE GOING TO LEARN • Approach the problem

    • Study the available data • Find the “best” algorithm • Make predictions … in a simple way!
  3. WHAT IS MACHINE LEARNING? “an application of artificial intelligence (AI)

    that provides systems the ability to automatically learn and improve from experience without being explicitly programmed”
  4. WHAT YOU NEED • Find an interesting problem: you can

    get a free dataset from http://archive.ics.uci.edu/ml • Python 3 + virtualenv • Requirements: jupyter, matplotlib, pandas, numpy, scikit-learn, seaborn (see requirements.txt for details)
  5. WHAT HAPPENED? A group of them moved in a different

    area and started developing an increased rate of type 2 diabetes
  6. WHY? Similar genetic characteristics but different habits. When these people

    moved, they adopted a different lifestyle and diet.
  7. DATASET • Number of times pregnant • Plasma glucose concentration

    a 2 hours in an oral glucose tolerance test • Diastolic blood pressure (mm Hg) • Triceps skin fold thickness (mm) • 2-Hour serum insulin (mu U/ml) • Body mass index (weight in kg/(height in m)^2) • Diabetes pedigree function • Age (years) 768 women with 8 characteristics The last column indicates if the person is affected (1) by diabetes or not (0).
  8. Credits • Dr. Daniela Ceccarelli (my wife): for validating the

    medical part of what I say • Dr. Jason Brownlee: for his amazing blog • my colleagues who had the patience to listen to my talk
  9. How to stay in touch • blog: https://www.andreagrandi.it • Twitter:

    @andreagrandi • GitHub: https://github.com/andreagrandi • email: [email protected] • IRC: Andy80 on FreeNode (#python, #django, #python-uk ) • PGP: 7D4C 4090 DB50 1693 4614 F6FC 6206 9DE9 2240 402E