From e6ad76ba0cc83981b9f0f5f8e6e6b0e07829bb98 Mon Sep 17 00:00:00 2001 From: Gamelin Alexis <gamelin@synchrotron-soleil.fr> Date: Fri, 24 Apr 2020 16:36:38 +0200 Subject: [PATCH] Particles : Bugfix Filling_pattern update should happen before no_empty is used ! --- tracking/particles.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/tracking/particles.py b/tracking/particles.py index e16847f..ee321bb 100644 --- a/tracking/particles.py +++ b/tracking/particles.py @@ -472,11 +472,10 @@ class Beam: raise TypeError("{} should be bool or float64".format(filling_pattern.dtype)) self.bunch_list = bunch_list + self.update_filling_pattern() for bunch in self.not_empty: bunch.init_gaussian() - - self.update_filling_pattern() def update_filling_pattern(self): """Update the beam filling pattern.""" -- GitLab