Skip to content

Commit

Permalink
#386: improve code quality
Browse files Browse the repository at this point in the history
  • Loading branch information
tlamonthezie committed Jun 7, 2023
1 parent 3a7679a commit bf5260e
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/lbaf/Applications/LBAF_app.py
Original file line number Diff line number Diff line change
Expand Up @@ -371,7 +371,8 @@ def run(self):
self.__parameters.work_model.get("parameters", {}).get(k)
for k in ("alpha", "beta", "gamma")
]
_n_a, _w_min_max, a_min_max = lbstats.compute_min_max_arrangements_work(objects, alpha, beta, gamma, n_ranks, logger=self.__logger)
_n_a, _w_min_max, a_min_max = lbstats.compute_min_max_arrangements_work(objects, alpha, beta, gamma,
n_ranks, logger=self.__logger)
else:
self.__logger.info("No brute force optimization performed")
a_min_max = []
Expand All @@ -387,7 +388,7 @@ def run(self):
self.__parameters.object_qoi if self.__parameters.object_qoi is not None else '')

# Execute runtime for specified phases, -1 for all phases
offline_LB_compatible = self.__parameters.json_params.get(
offline_LB_compatible = self.__parameters.json_params.get( # pylint:disable=C0103:invalid-name;not lowercase
"offline_LB_compatible", False)
rebalanced_phase = runtime.execute(
self.__parameters.algorithm.get("phase_id", -1),
Expand All @@ -402,7 +403,7 @@ def run(self):
"No rebalancing took place for offline load-balancing")
else:
# Determine if a phase with same index was present
if (existing_phase := phases.get(p_id := rebalanced_phase.get_id())):
if _existing_phase := phases.get(p_id := rebalanced_phase.get_id()):
# Apply object timings to rebalanced phase
self.__logger.info(
f"Phase {p_id} already present, applying its object loads to rebalanced phase")
Expand Down

0 comments on commit bf5260e

Please sign in to comment.