kernels.float.normal.cu Maven / Gradle / Ivy
#include
#include
#include
extern "C"
__global__ void normal_float(int n,float *means,float std,float *result, curandGenerator_t s) {
int tid = threadIdx.x + blockIdx.x * blockDim.x;
for(int i = tid; i < n; i += blockDim.x*gridDim.x) {
float *curr = &result[i];
curandGenerateNormal(s,curr,1,means[i],std);
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy