aboutsummaryrefslogtreecommitdiff
path: root/Python/pywarpx/WarpInterface.py
diff options
context:
space:
mode:
authorGravatar David Grote <grote1@llnl.gov> 2020-03-17 16:39:51 -0700
committerGravatar GitHub <noreply@github.com> 2020-03-17 16:39:51 -0700
commit85d2f945f41382c8ebfe6696d8093b47b46d8ea1 (patch)
treea2cb8ff29ad2644e9e7cb2b791c7e08841b5a97c /Python/pywarpx/WarpInterface.py
parent1a670a115eb3e7396ce922496319b943281c34a0 (diff)
downloadWarpX-85d2f945f41382c8ebfe6696d8093b47b46d8ea1.tar.gz
WarpX-85d2f945f41382c8ebfe6696d8093b47b46d8ea1.tar.zst
WarpX-85d2f945f41382c8ebfe6696d8093b47b46d8ea1.zip
Small fixes to Python to better handle particle weights (#807)
Diffstat (limited to 'Python/pywarpx/WarpInterface.py')
-rw-r--r--Python/pywarpx/WarpInterface.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/Python/pywarpx/WarpInterface.py b/Python/pywarpx/WarpInterface.py
index 8a3823959..91217ef1e 100644
--- a/Python/pywarpx/WarpInterface.py
+++ b/Python/pywarpx/WarpInterface.py
@@ -8,6 +8,8 @@ import warp
from . import fields
from pywarpx import PGroup
+# The particle weight is always the first pid
+warp.top.wpid = 1
def warp_species(warp_type, picmi_species, level=0):
"""Returns a Warp species that has a reference to the WarpX particles.