Nearest Neighbor

nearestneighbour computes nearest neighbours to a set of points from a set of candidate points by Euclidean distance.

Classifiers: Nearest neighbor

  • f(x) = label of the training example nearest to x
  • All we need is a distance function for our inputs
  • No training required!

The 1-N-N classifier is one of the oldest methods known.

The idea: to classify X find its closest neighbor among the training points (call it X) and assign to X the label of X

k−Nearest Neighbor

vl_kdtreequery supports two important operations: approximate nearest-neighbor search and k-nearest neighbor search (return the k nearest neighbors to a given query point Q).

[index, distance] = vl_kdtreequery(kdtree, X, Q, 'NumNeighbors', 10, 'MaxComparisons', 15);
The MaxComparisons option specifies how many paths in the best-bin-first search of the kd-tree can be checked before giving up and returning the closest point encountered so far.
does not compare any point in Q with more than 15 points in X.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s




Just another site

Jing's Blog

Just another site

Start from here......







Just another site

Where On Earth Is Waldo?

A Project By Melanie Coles

the Serious Computer Vision Blog

A blog about computer vision and serious stuff

Cauthy's Blog

paper review...

Cornell Computer Vision Seminar Blog

Blog for CS 7670 - Special Topics in Computer Vision


Life through nerd-colored glasses

Luciana Haill

Brainwaves Augmenting Consciousness



Dr Paul Tennent

and the university of nottingham

turn off the lights, please

A bunch of random, thinned and stateless thoughts around the Web

%d bloggers like this: