Skip to content

GitLab

  • Menu
Projects Groups Snippets
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • RapidLib RapidLib
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 33
    • Issues 33
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 0
    • Merge requests 0
  • Deployments
    • Deployments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • Repository
  • Wiki
    • Wiki
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
Collapse sidebar
  • rapid-mix
  • RapidLibRapidLib
  • Issues
  • #67

Closed
Open
Created Dec 13, 2016 by Michael Zbyszyński@MikeZOwner

Improve handling of "k"

MZ just added getK() and setK() to the kNN model. This brings up some interesting issues:

  1. I can't think of a case where k == 2 is better than k == 1. Disallow it?
  2. Ties go to the first class found. Find a better metric? Distance? Average distance?
  3. If setK() asks for a k that is greater than the current number of neighbours, then k is set to the number of neighbours. Maybe kNN should remember the number that the user requested so that k can be increased if new neighbours are added?
  4. Using getK() and setK() in a modelSet required casting a baseModel* down the inheritance chain. Is this bad design? How will this work if more parameters are exposed in more models?

This issue should probably be broken up into sub-issues.

Assignee
Assign to
Time tracking