aboutsummaryrefslogtreecommitdiff
path: root/lid_driven_cavity/opencl/AA.py
diff options
context:
space:
mode:
authorAdrian Kummerlaender2019-11-11 13:41:46 +0100
committerAdrian Kummerlaender2019-11-11 13:41:46 +0100
commit336d20eed737445f3b2aa7d875c90ccc64a97213 (patch)
treece17ece45910d92fe10473a7632aa0ae4f057c6e /lid_driven_cavity/opencl/AA.py
parent988818c224197eb506ac2f42edef13d7bd1cc11a (diff)
downloadboltzgen_examples-336d20eed737445f3b2aa7d875c90ccc64a97213.tar
boltzgen_examples-336d20eed737445f3b2aa7d875c90ccc64a97213.tar.gz
boltzgen_examples-336d20eed737445f3b2aa7d875c90ccc64a97213.tar.bz2
boltzgen_examples-336d20eed737445f3b2aa7d875c90ccc64a97213.tar.lz
boltzgen_examples-336d20eed737445f3b2aa7d875c90ccc64a97213.tar.xz
boltzgen_examples-336d20eed737445f3b2aa7d875c90ccc64a97213.tar.zst
boltzgen_examples-336d20eed737445f3b2aa7d875c90ccc64a97213.zip
Use separate Nix environments for each target
Diffstat (limited to 'lid_driven_cavity/opencl/AA.py')
-rw-r--r--lid_driven_cavity/opencl/AA.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/lid_driven_cavity/opencl/AA.py b/lid_driven_cavity/opencl/AA.py
index f317cd0..74979c5 100644
--- a/lid_driven_cavity/opencl/AA.py
+++ b/lid_driven_cavity/opencl/AA.py
@@ -83,7 +83,7 @@ class Lattice:
moments = numpy.ndarray(shape=(self.memory.volume*(self.descriptor.d+1),1), dtype=self.float_type[0])
self.program.collect_moments_all(
- self.queue, self.geometry.size(), self.layout, self.memory.cl_pop, self.memory.cl_moments)
+ self.queue, self.geometry.inner_size(), self.layout, self.memory.cl_pop, self.memory.cl_moments)
cl.enqueue_copy(self.queue, moments, self.memory.cl_moments).wait();
@@ -99,7 +99,7 @@ __kernel void equilibrilize_all(__global ${float_type}* f_next)
__kernel void collect_moments_all(__global ${float_type}* f,
__global ${float_type}* moments)
{
- const unsigned int gid = ${index.gid('get_global_id(0)', 'get_global_id(1)')};
+ const unsigned int gid = ${index.gid('get_global_id(0)+1', 'get_global_id(1)+1')};
collect_moments_tock(f, gid, moments);
}
"""