Apply suggestions from code review

Co-authored-by: Andrew Johnson <drewejohnson@users.noreply.github.com>
This commit is contained in:
Lorenzo Chierici 2024-02-05 12:43:20 +01:00 committed by church89
parent d69a8a853a
commit 13ee2e3daf
2 changed files with 5 additions and 5 deletions

View file

@ -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

View file

@ -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