Commit 4fecf0c5 authored by Michael Kuron's avatar Michael Kuron
Browse files

Merge branch 'FixPipeline' into 'master'

Fix pipeline

See merge request pycodegen/pystencils!260
parents b70ac70a 4827649e
Pipeline #33954 passed with stages
in 93 minutes and 56 seconds
......@@ -261,7 +261,8 @@ pycodegen-integration:
- cd ../pygrandchem
- py.test -v -n $NUM_CORES --junitxml=report.xml .
- cd ../walberla/build/
- make CodegenJacobiCPU CodegenJacobiGPU CodegenPoissonCPU CodegenPoissonGPU MicroBenchmarkGpuLbm LbCodeGenerationExample UniformGridBenchmarkGPU_trt UniformGridBenchmarkGPU_entropic_kbc_n4 FluctuatingMRT
- make -j $NUM_CORES CodegenJacobiCPU CodegenJacobiGPU CodegenPoissonCPU CodegenPoissonGPU MicroBenchmarkGpuLbm LbCodeGenerationExample
- make -j $NUM_CORES multiphaseCPU multiphaseGPU FluctuatingMRT FlowAroundSphereCodeGen
- cd apps/benchmarks/UniformGridGPU
- make -j $NUM_CORES
- cd ../UniformGridGenerated
......
......@@ -71,7 +71,10 @@ class PyStencilsKerncraftKernel(KernelCode):
while cur_node is not None:
if isinstance(cur_node, LoopOverCoordinate):
loop_counter_sym = cur_node.loop_counter_symbol
loop_info = (loop_counter_sym.name, cur_node.start, cur_node.stop, 1)
loop_info = (loop_counter_sym.name,
sp.Integer(cur_node.start),
sp.Integer(cur_node.stop),
sp.Integer(1))
# If the correct step were to be provided, all access within that step length will
# also need to be passed to kerncraft: cur_node.step)
self._loop_stack.append(loop_info)
......
......@@ -423,14 +423,14 @@ def plot_3d(stencil, figure=None, axes=None, data=None, textsize='8'):
def draw(self, renderer):
xs3d, ys3d, zs3d = self._verts3d
xs, ys, zs = proj3d.proj_transform(xs3d, ys3d, zs3d, renderer.M)
xs, ys, zs = proj3d.proj_transform(xs3d, ys3d, zs3d, self.axes.M)
self.set_positions((xs[0], ys[0]), (xs[1], ys[1]))
FancyArrowPatch.draw(self, renderer)
if axes is None:
if figure is None:
figure = plt.figure()
axes = figure.gca(projection='3d')
axes = figure.add_subplot(projection='3d')
try:
axes.set_aspect("equal")
except NotImplementedError:
......@@ -446,7 +446,7 @@ def plot_3d(stencil, figure=None, axes=None, data=None, textsize='8'):
r = [-1, 1]
for s, e in combinations(np.array(list(product(r, r, r))), 2):
if np.sum(np.abs(s - e)) == r[1] - r[0]:
axes.plot3D(*zip(s, e), color="k", alpha=0.5)
axes.plot(*zip(s, e), color="k", alpha=0.5)
for d, annotation in zip(stencil, data):
assert len(d) == 3, "Works only for 3D stencils"
......
......@@ -38,7 +38,7 @@ def _generate_fields(dt=np.uint8, stencil_directions=1, layout='numpy'):
index_dimensions=1 if stencil_directions > 1 else 0).astype(dt).flat
gpu_src_arr = gpuarray.to_gpu(src_arr)
gpu_dst_arr = gpuarray.zeros_like(gpu_src_arr)
gpu_dst_arr = gpuarray.empty_like(gpu_src_arr)
size = int(np.prod(src_arr.shape))
gpu_buffer_arr = gpuarray.zeros(size, dtype=dt)
......
......@@ -78,9 +78,8 @@ def test_rng(target, rng, precision, dtype, t=124, offsets=(0, 0), keys=(0, 0),
int_reference = np.empty(dh.shape + (4,), dtype=int)
for x in range(dh.shape[0]):
for y in range(dh.shape[1]):
r = Philox(counter=t + (x + offset_values[0]) * 2 ** 32 + (y + offset_values[1]) * 2 ** 64,
r = Philox(counter=t + (x + offset_values[0]) * 2 ** 32 + (y + offset_values[1]) * 2 ** 64 - 1,
key=keys[0] + keys[1] * 2 ** 32, number=4, width=32, mode="sequence")
r.advance(-4, counter=False)
int_reference[x, y, :] = r.random_raw(size=4)
if precision == 'float' or dtype == 'float':
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment