Lock in $30 Savings on PRO—Offer Ends Soon! ⏳
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Introduction au machine learning avec Scitkit-l...
Search
ngarneau
March 23, 2015
Programming
0
45
Introduction au machine learning avec Scitkit-learn
Atelier d'introduction au machine learning au Web à Québec édition 2015
ngarneau
March 23, 2015
Tweet
Share
More Decks by ngarneau
See All by ngarneau
Mocks, stubs & seams
ngarneau
0
110
big data
ngarneau
5
400
Other Decks in Programming
See All in Programming
Go コードベースの構成と AI コンテキスト定義
andpad
0
130
GISエンジニアから見たLINKSデータ
nokonoko1203
0
110
ELYZA_Findy AI Engineering Summit登壇資料_AIコーディング時代に「ちゃんと」やること_toB LLMプロダクト開発舞台裏_20251216
elyza
0
220
TestingOsaka6_Ozono
o3
0
160
Integrating WordPress and Symfony
alexandresalome
0
160
AI時代を生き抜く 新卒エンジニアの生きる道
coconala_engineer
1
270
エディターってAIで操作できるんだぜ
kis9a
0
730
AIの誤りが許されない業務システムにおいて“信頼されるAI” を目指す / building-trusted-ai-systems
yuya4
6
3.7k
マスタデータ問題、マイクロサービスでどう解くか
kts
0
110
これだけで丸わかり!LangChain v1.0 アップデートまとめ
os1ma
6
1.9k
これならできる!個人開発のすゝめ
tinykitten
PRO
0
110
안드로이드 9년차 개발자, 프론트엔드 주니어로 커리어 리셋하기
maryang
1
120
Featured
See All Featured
Large-scale JavaScript Application Architecture
addyosmani
515
110k
Visualization
eitanlees
150
16k
Mobile First: as difficult as doing things right
swwweet
225
10k
How to train your dragon (web standard)
notwaldorf
97
6.4k
I Don’t Have Time: Getting Over the Fear to Launch Your Podcast
jcasabona
34
2.6k
Easily Structure & Communicate Ideas using Wireframe
afnizarnur
194
17k
How Fast Is Fast Enough? [PerfNow 2025]
tammyeverts
3
390
Making Projects Easy
brettharned
120
6.5k
Put a Button on it: Removing Barriers to Going Fast.
kastner
60
4.1k
It's Worth the Effort
3n
187
29k
No one is an island. Learnings from fostering a developers community.
thoeni
21
3.6k
Why Our Code Smells
bkeepers
PRO
340
57k
Transcript
Introduction au machine learning avec scikit-learn Nicolas Garneau Université Laval
- L’Agence
Les bases
Prédiction à la bourse Applications du ML Analyse de comportement
Aide à la décision Classification de textes ...
S : {s1, s2, s3, ..., sn} Jeu de données
un «exemple»
S : {s1, s2, s3, ..., sn} Jeu de données
sn : {x, y} une liste de «features» un «label»
S : {s1, s2, s3, ..., sn} Jeu de données
sn : {x, y} x : {x1, x2, x3, ..., xn} chacun de nos features...
Exemple iris dataset 4 features: • Longueur pétale • Largeur
pétale • Longueur sépale • Largeur sépale
Exemple iris dataset 3 classes: Iris Setosa Iris Versicolor Iris
Virginica crédit photo: http://mirlab.org/jang/books/dcpr/dataSetIris.asp?title=2-2%20Iris%20Dataset
s1 : {(larg. sépale, long. sépale), type} Exemple iris dataset
si on sélectionne 2 features
s1 : {(larg. sépale, long. sépale), type} Exemple x1 :
{(0: 2, 1: 5), 1} x2 : {(0: 1, 1: 6), 0} ... iris dataset
Exemple iris dataset
Comment y arriver Différentes façons
K Nearest Neighbors (KNN) K plus proches voisins Mesure de
similarité
K Nearest Neighbors (KNN) Vote de majorité k = 3
K Nearest Neighbors (KNN) Vote de majorité ! k =
3
K Nearest Neighbors (KNN) Vote de majorité pondéré* !! 15
12 3 k = 3
K Nearest Neighbors
Notre problème Description du problème de classification qu’on a Classification
200 features 800 exemples 200 inconnus
Workflow 1. Pre-model 2. Model 3. Validation
1. Pre-model «Scaling» Réduction de la dimensionnalité «Imputation»
1. Pre-model Scaling Distribution normale Pour les distances...!
2. Model clf = KNeighborsClassifier(n_neighbors=35) clf.fit(X, y) clf.predict(X_mystery)
3. Validation Train/test sets Score «Cross-validation»
3. Validation Score precision: TP / (TP + FP) recall:
TP / (TP + FN) f1-score: 2TP / (2TP + FP + FN)
Bonus! Bagging