Sha256: aef2d5ecdf52127097a0c67f6af617c8670d46d17e97c9030c3703302cacb72c
Contents?: true
Size: 423 Bytes
Versions: 2
Compression:
Stored size: 423 Bytes
Contents
% c_dtype = dtype_to_c_type(dtype) __kernel void random_uniform_<%= dtype %>(const int seed_ptr, const float min, const float max, __global const <%= c_dtype %> *rand_table, __global <%= c_dtype %> *C) { // Get the index of the current element to be processed const int id = get_global_id(0); <%= c_dtype %> rand_value = rand_table[ (seed_ptr + id) % <%= tsize %>]; C[id] = rand_value * (max - min) + min; }
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
tensor_stream-opencl-0.3.2 | lib/tensor_stream/opencl/kernels/random_uniform.cl |
tensor_stream-opencl-0.3.1 | lib/tensor_stream/opencl/kernels/random_uniform.cl |