just update the Target drift attribute to so we dont have to inject the drift_percent every single time

This commit is contained in:
Adrian Manteza
2022-03-17 22:48:22 +00:00
parent e4f51b8a3f
commit bd61fb7e81
3 changed files with 15 additions and 8 deletions

View File

@ -15,8 +15,8 @@ class Target(BaseModel):
def max_drift_increment(cls) -> int:
return 1 # 10%
def minimum(self, drift_percent = 0.0) -> float:
return self.value - (self.value * drift_percent)
def minimum(self) -> float:
return self.value - (self.value * self.drift)
def maximum(self, drift_percent = 0.0) -> float:
return self.value + (self.value * drift_percent)
def maximum(self) -> float:
return self.value + (self.value * self.drift)