Commit 67c20f8d authored by Elad Noor's avatar Elad Noor

chore: qa

parent 2ccc6846
Pipeline #107240338 failed with stages
in 7 minutes and 2 seconds
......@@ -97,7 +97,7 @@ class ComponentContribution(object):
@staticmethod
def standard_dg_multi(
reactions: List[PhasedReaction]
reactions: List[PhasedReaction],
) -> Tuple[np.array, np.array]:
"""Calculate the chemical reaction energies of a list of reactions.
......@@ -110,7 +110,10 @@ class ComponentContribution(object):
residual_reactions, stored_dg = zip(*rxn_dg_pairs)
stored_dg = np.array(stored_dg)
standard_dg, dg_sigma = ComponentContribution.predictor.standard_dg_multi( # noqa
(
standard_dg,
dg_sigma,
) = ComponentContribution.predictor.standard_dg_multi(
residual_reactions
)
return standard_dg + stored_dg, dg_sigma
......@@ -129,7 +132,7 @@ class ComponentContribution(object):
temperature=self.temperature,
)
standard_dg_prime = ComponentContribution.predictor.standard_dg_prime( # noqa
standard_dg_prime = ComponentContribution.predictor.standard_dg_prime(
residual_reaction,
p_h=self.p_h,
ionic_strength=self.ionic_strength,
......@@ -176,7 +179,10 @@ class ComponentContribution(object):
residual_reactions, stored_dg_primes = zip(*rxn_dg_pairs)
stored_dg_primes = np.array(stored_dg_primes)
standard_dg_prime, dg_sigma = ComponentContribution.predictor.standard_dg_prime_multi( # noqa
(
standard_dg_prime,
dg_sigma,
) = ComponentContribution.predictor.standard_dg_prime_multi(
residual_reactions,
p_h=self.p_h,
ionic_strength=self.ionic_strength,
......
......@@ -295,7 +295,7 @@ class PathwayThermoModel(object):
self.r_bounds = None
def _MakeLnConcentratonBounds(
self
self,
) -> Tuple[Iterable[float], Iterable[float]]:
"""Make bounds on logarithmic concentrations.
......@@ -304,7 +304,7 @@ class PathwayThermoModel(object):
return self.pathway.bounds.GetLnBounds(self.pathway.S.index)
def _MakeDrivingForceConstraints(
self
self,
) -> Tuple[np.array, np.array, np.array]:
"""Generate parameters for LP.
......@@ -371,7 +371,7 @@ class PathwayThermoModel(object):
return A, b, c
def _GetPrimalVariablesAndConstants(
self
self,
) -> Tuple[np.array, np.array, np.array, List[Variable], List[Variable]]:
# Create the driving force variable and add the relevant constraints
......@@ -386,7 +386,7 @@ class PathwayThermoModel(object):
return A, b, c, y, lnC
def _GetDualVariablesAndConstants(
self
self,
) -> Tuple[
np.array,
np.array,
......@@ -407,7 +407,7 @@ class PathwayThermoModel(object):
return A, b, c, w, g, z, u
def _MakeMDFProblem(
self
self,
) -> Tuple[Model, List[Variable], List[Variable], Variable]:
"""Create primal LP problem for Min-max Thermodynamic Driving Force.
......@@ -445,7 +445,7 @@ class PathwayThermoModel(object):
return lp, y, lnC, B
def _MakeMDFProblemDual(
self
self,
) -> Tuple[
Model, List[Variable], List[Variable], List[Variable], List[Variable]
]:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment