Machine Learning Course - Lesson 6: K Nearest Neighbors Classifier (JavaScript - No Libraries)

Radu Mariescu-Istodor
Radu Mariescu-Istodor
2.4 هزار بار بازدید - پارسال - A generalization of the nearest
A generalization of the nearest neighbor classifier is the k nearest neighbors classifier (KNN for sort). K is the number of neighbors that will play a role in the classification.

I'll teach you how to implement the K Nearest Neighbors classifier in JavaScript and use it for drawing recognition.

The Course: Machine Learning Course

⭐️HOMEWORK⭐️
Try to calculate a probability for the classification to be correct, based on the number of neighbors of the predicted class. Most libraries (tensorflow, scikit-learn) support this feature and it can be a useful thing to have. Other variants of nearest neighbor classifiers exist as well, like a version weighted by distance or one that considers a fixed size neighborhood. Think you can implement any of these? Share your code with me on Discord
Discord: discord
I’ll showcase my favorite implementations in a future video.

⭐️LINKS⭐️

📁 Data
https://github.com/gniziemazity/drawi...

💻 Code
tps://github.com/gniziemazity/ml-course
✔️ Use P5 to follow along
✔️ P6 is the code after this lesson


⭐️TIMESTAMPS⭐️
00:00 Introduction
00:47 Intuition for the K Nearest Neighbors
01:50 Implementing the K Nearest Neighbors Classifier
06:32 Visualizing the K Nearest Neighbors on the Chart
09:44 Homework (Neighbors)
پارسال در تاریخ 1401/12/26 منتشر شده است.
2,490 بـار بازدید شده
... بیشتر