picnicml / doddle-model

:cake: doddle-model: machine learning in Scala.
https://picnicml.github.io
Apache License 2.0
137 stars 23 forks source link

Implement a KNeighborsClassifier #41

Open binkabir opened 5 years ago

binkabir commented 5 years ago

KNeighborsClassifier seems to be a very popular classification algorithm. Do you have any plans/timeline for implementing it?

Cheers.

inejc commented 5 years ago

Hey. No particular timeline but would be a welcome contribution. Would you perhaps be interested in tackling this? Let me know if you need any help 🙂.

binkabir commented 5 years ago

Hi @inejc. I will be willing to help in some algorithm implementation like this one, but Im only good in scala programming and a beginner in ML.

inejc commented 5 years ago

@binkabir that's perfectly fine, you are in a very good position if you know scala 🙂. There are plenty of resources available for free online and I can provide additional help with the actual algorithm. A good start would be to learn how it works. Let me know if you need any help finding the learning material.

binkabir commented 5 years ago

Sure, I have some materials, but having you giving me more learning materials will be awesome.

inejc commented 5 years ago

Great, I'll provide some additional links over the weekend.

inejc commented 5 years ago

Hi @binkabir. For a quick overview of the algorithm I would suggest these resources:

After that, it would be useful to study the following data structures:

Let me know if you need more math-heavy resources for the above and I'll do my best to provide them. You can also try to search for them on Google Scholar.

Note that estimators in doddle-model are implemented using typeclasses. If you are not familiar with them, you can take a look at:

You can find the basic doddle-model typeclasses here. If you decide to implement the classification algorithm you will need to implement an instance of the Classifier typeclass. Here is an example of how this is done for the most frequent (dummy) classifier.

Don't hesitate to ask if you need any more help and thanks for being interested in making a contribution, it's really appreciated.

binkabir commented 5 years ago

This is awesome, will have a look at it. Thanks.