From 13ee2e3daf4858c682c49c1a0fd900b6f4031e69 Mon Sep 17 00:00:00 2001 From: Lorenzo Chierici Date: Mon, 5 Feb 2024 12:43:20 +0100 Subject: [PATCH] Apply suggestions from code review Co-authored-by: Andrew Johnson --- openmc/deplete/abc.py | 4 ++-- openmc/deplete/batchwise.py | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/openmc/deplete/abc.py b/openmc/deplete/abc.py index 3f1b52f824..a5a615a1ed 100644 --- a/openmc/deplete/abc.py +++ b/openmc/deplete/abc.py @@ -812,7 +812,7 @@ class Integrator(ABC): # Solve transport equation (or obtain result from restart) if i > 0 or self.operator.prev_res is None: # Update geometry/material according to batchwise definition - if self.batchwise and source_rate != 0.0: + if self.batchwise is not None and source_rate != 0.0: n, root = self._get_bos_from_batchwise(i, n) else: root = None @@ -840,7 +840,7 @@ class Integrator(ABC): # solve) if output and final_step and comm.rank == 0: print(f"[openmc.deplete] t={t} (final operator evaluation)") - if self.batchwise and source_rate != 0.0: + if self.batchwise is not None and source_rate != 0.0: n, root = self._get_bos_from_batchwise(i+1, n) else: root = None diff --git a/openmc/deplete/batchwise.py b/openmc/deplete/batchwise.py index 955d2878b7..4abda675bc 100644 --- a/openmc/deplete/batchwise.py +++ b/openmc/deplete/batchwise.py @@ -58,11 +58,11 @@ class Batchwise(ABC): This is equivalent to the `target` parameter of the `search_for_keff`. Default to 1.0. print_iterations : Bool, Optional - Whether or not to print `search_for_keff` iterations. + Print a status message each iteration Default to True search_for_keff_output : Bool, Optional - Whether or not to print transport iterations during `search_for_keff`. - Default to False + Print full transport logs during iterations (e.g., inactive generations, active + generations). Default to False Attributes ---------- burn_mats : list of str