fix: Swaps high and lows for ranges if needed to make negatives behave nicer
All checks were successful
gitea-physics/pdme/pipeline/head This commit looks good
All checks were successful
gitea-physics/pdme/pipeline/head This commit looks good
This commit is contained in:
@@ -48,3 +48,5 @@ class DotRangeMeasurement():
|
||||
|
||||
def __post_init__(self) -> None:
|
||||
self.r = numpy.array(self.r)
|
||||
if self.v_low > self.v_high:
|
||||
self.v_low, self.v_high = self.v_high, self.v_low
|
||||
|
||||
@@ -56,3 +56,5 @@ class DotPairRangeMeasurement():
|
||||
def __post_init__(self) -> None:
|
||||
self.r1 = numpy.array(self.r1)
|
||||
self.r2 = numpy.array(self.r2)
|
||||
if self.v_low > self.v_high:
|
||||
self.v_low, self.v_high = self.v_high, self.v_low
|
||||
|
||||
Reference in New Issue
Block a user