forked from arrayfire/arrayfire
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathhamming.cpp
More file actions
18 lines (16 loc) · 699 Bytes
/
hamming.cpp
File metadata and controls
18 lines (16 loc) · 699 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
/*******************************************************
* Copyright (c) 2014, ArrayFire
* All rights reserved.
*
* This file is distributed under 3-clause BSD license.
* The complete license agreement can be obtained at:
* http://arrayfire.com/licenses/BSD-3-Clause
********************************************************/
#include <af/defines.h>
#include <af/vision.h>
af_err af_hamming_matcher(af_array* idx, af_array* dist, const af_array query,
const af_array train, const dim_t dist_dim,
const unsigned n_dist) {
return af_nearest_neighbour(idx, dist, query, train, dist_dim, n_dist,
AF_SHD);
}