From 0e0f6b2f11968357ee9890a507d939e63f68bb45 Mon Sep 17 00:00:00 2001 From: Dave Grote Date: Fri, 6 Sep 2019 14:06:08 -0700 Subject: Updated Python particles interface to allow refined levels --- Python/pywarpx/WarpInterface.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'Python/pywarpx/WarpInterface.py') diff --git a/Python/pywarpx/WarpInterface.py b/Python/pywarpx/WarpInterface.py index f84c22a5d..e2c9efa58 100644 --- a/Python/pywarpx/WarpInterface.py +++ b/Python/pywarpx/WarpInterface.py @@ -3,11 +3,11 @@ from . import fields from pywarpx import PGroup -def warp_species(warp_type, picmie_species): +def warp_species(warp_type, picmi_species, level=0): """Returns a Warp species that has a reference to the WarpX particles. """ - elec_pgroups = PGroup.PGroups(ispecie=picmie_species.species_number) - return warp.Species(type=warp_type, pgroups=elec_pgroups) + pgroups = PGroup.PGroups(ispecie=picmi_species.species_number, level=level) + return warp.Species(type=warp_type, pgroups=pgroups) class _WarpX_FIELDtype(object): -- cgit v1.2.3