Skip to content

Commit

Permalink
Fix grid size for Blelloch test
Browse files Browse the repository at this point in the history
  • Loading branch information
kif committed Nov 6, 2024
1 parent a341657 commit 78cc289
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/pyFAI/opencl/test/test_collective.py
Original file line number Diff line number Diff line change
Expand Up @@ -178,11 +178,11 @@ def test_Blelloch(self):
"""
data_d = pyopencl.array.to_device(self.queue, self.data.astype("float32"))
scan_d = pyopencl.array.empty_like(data_d)
maxi = int(round(numpy.log2(min(self.shape, self.max_valid_wg))))+1
maxi = int(round(numpy.log2(min(self.shape/2, self.max_valid_wg))))+1
for i in range(maxi):
wg = 1 << i
try:
evt = self.program.test_blelloch_scan(self.queue, (self.shape,), (wg,),
evt = self.program.test_blelloch_scan(self.queue, (self.shape//2,), (wg,),
data_d.data,
scan_d.data,
pyopencl.LocalMemory(2*4*wg))
Expand Down

0 comments on commit 78cc289

Please sign in to comment.