From 026624684de8c7414b6411b90c5371f7a8f8a354 Mon Sep 17 00:00:00 2001 From: Andreas Kloeckner Date: Fri, 30 Dec 2016 19:48:07 -0500 Subject: [PATCH 1/2] Add plotting to curve-pot example [ci skip] --- examples/curve-pot.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/examples/curve-pot.py b/examples/curve-pot.py index 777c53ee..9d8678f5 100644 --- a/examples/curve-pot.py +++ b/examples/curve-pot.py @@ -199,6 +199,10 @@ def draw_pot_figure(aspect_ratio, # }}} + fp.write_vtk_file("potential.vts", [ + ("potential", vol_pot.real) + ]) + if 0: # {{{ 2D false-color plot -- GitLab From 8dc0057be2ac879169e8720015ac194e85218dc4 Mon Sep 17 00:00:00 2001 From: Andreas Kloeckner Date: Fri, 30 Dec 2016 19:49:11 -0500 Subject: [PATCH 2/2] Revert "Specify types of nsources in expansions." This reverts commit 85653a69b1ccac1c266bc6a2a0e09dc3e6163349. --- sumpy/p2p.py | 4 ++-- sumpy/qbx.py | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/sumpy/p2p.py b/sumpy/p2p.py index 0345f904..7234180f 100644 --- a/sumpy/p2p.py +++ b/sumpy/p2p.py @@ -154,8 +154,8 @@ class P2P(P2PBase): shape=(self.dim, "nsources")), lp.GlobalArg("targets", None, shape=(self.dim, "ntargets")), - lp.ValueArg("nsources", np.int32), - lp.ValueArg("ntargets", np.int32), + lp.ValueArg("nsources", None), + lp.ValueArg("ntargets", None), lp.GlobalArg("strength", None, shape="nstrengths,nsources"), lp.GlobalArg("result", None, shape="nresults,ntargets", dim_tags="sep,C") diff --git a/sumpy/qbx.py b/sumpy/qbx.py index 629f9092..0b3dc035 100644 --- a/sumpy/qbx.py +++ b/sumpy/qbx.py @@ -111,8 +111,8 @@ class LayerPotentialBase(KernelComputation, KernelCacheWrapper): shape=(self.dim, "ntargets"), order="C"), lp.GlobalArg("center", None, shape=(self.dim, "ntargets"), order="C"), - lp.ValueArg("nsources", np.int32), - lp.ValueArg("ntargets", np.int32), + lp.ValueArg("nsources", None), + lp.ValueArg("ntargets", None), ] @memoize_method -- GitLab