mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-28 06:05:58 -04:00
fix a bug in timer reset
This commit is contained in:
parent
8154e5a035
commit
944afb1d20
3 changed files with 10 additions and 0 deletions
|
|
@ -86,6 +86,7 @@ extern "C" {
|
|||
int openmc_id_map(const void* slice, int32_t* data_out);
|
||||
int openmc_property_map(const void* slice, double* data_out);
|
||||
int openmc_reset();
|
||||
int openmc_reset_timers();
|
||||
int openmc_run();
|
||||
void openmc_set_seed(int64_t new_seed);
|
||||
int openmc_simulation_finalize();
|
||||
|
|
|
|||
|
|
@ -63,6 +63,8 @@ _dll.openmc_run.restype = c_int
|
|||
_dll.openmc_run.errcheck = _error_handler
|
||||
_dll.openmc_reset.restype = c_int
|
||||
_dll.openmc_reset.errcheck = _error_handler
|
||||
_dll.openmc_reset_timers.restype = c_int
|
||||
_dll.openmc_reset_timers.errcheck = _error_handler
|
||||
_run_linsolver_argtypes = [_array_1d_dble, _array_1d_dble, _array_1d_dble,
|
||||
c_double]
|
||||
_dll.openmc_run_linsolver.argtypes = _run_linsolver_argtypes
|
||||
|
|
@ -305,6 +307,7 @@ def plot_geometry():
|
|||
def reset():
|
||||
"""Reset tallies and timers."""
|
||||
_dll.openmc_reset()
|
||||
_dll.openmc_reset_timers()
|
||||
|
||||
|
||||
def run():
|
||||
|
|
|
|||
|
|
@ -165,6 +165,12 @@ int openmc_reset()
|
|||
return 0;
|
||||
}
|
||||
|
||||
int openmc_reset_timers()
|
||||
{
|
||||
reset_timers();
|
||||
return 0;
|
||||
}
|
||||
|
||||
int openmc_hard_reset()
|
||||
{
|
||||
// Reset all tallies and timers
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue