cheshirekow  v0.1.0
euclidean.cu.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2012 Josh Bialkowski (jbialk@mit.edu)
3  *
4  * This file is part of mpblocks.
5  *
6  * mpblocks is free software: you can redistribute it and/or modify
7  * it under the terms of the GNU General Public License as published by
8  * the Free Software Foundation, either version 3 of the License, or
9  * (at your option) any later version.
10  *
11  * mpblocks is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  * GNU General Public License for more details.
15  *
16  * You should have received a copy of the GNU General Public License
17  * along with mpblocks. If not, see <http://www.gnu.org/licenses/>.
18  */
27 #ifndef MPBLOCKS_CUDANN_KERNELS_EUCLIDEAN_CU_H_
28 #define MPBLOCKS_CUDANN_KERNELS_EUCLIDEAN_CU_H_
29 
30 #include <cuda.h>
31 #include <cuda_runtime.h>
33 
34 namespace mpblocks {
35 namespace cudaNN {
36 namespace kernels {
37 
38 
40 template< typename Format_t, unsigned int NDim>
43  query,
44  Format_t* g_in,
45  unsigned int pitchIn,
46  Format_t* g_out,
47  unsigned int pitchOut,
48  unsigned int n
49  );
50 
51 template< bool Pseudo, typename Scalar, unsigned int NDim >
54  query,
55  Scalar* g_out
56  );
57 
58 
59 } // kernels
60 } // cudaNN
61 } // mpblocks
62 
63 
64 
65 
66 #endif // KERNELS_H_
#define __global__
Definition: fakecuda.h:33
__global__ void euclidean_distance(QueryPoint< Format_t, NDim > query, Format_t *g_in, unsigned int pitchIn, Format_t *g_out, unsigned int pitchOut, unsigned int n)
vector norm (2-norm) between two points