Skip to content

Commit

Permalink
_ropt_callback -> _on_before_forward_model_evaluation
Browse files Browse the repository at this point in the history
  • Loading branch information
yngve-sk committed Nov 6, 2024
1 parent 613735e commit d5069d0
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/ert/run_models/everest_run_model.py
Original file line number Diff line number Diff line change
Expand Up @@ -471,7 +471,7 @@ def _simulation_callback(self, ctx: BatchContext | None) -> None:
)
self._monitor_thread.start()

def _ropt_callback(
def _on_before_forward_model_evaluation(
self, _: Event, optimizer: BasicOptimizer, simulator: Simulator
) -> None:
logging.getLogger(EVEREST).debug("Optimization callback called")
Expand Down Expand Up @@ -541,7 +541,9 @@ def _create_optimizer(self, simulator: Simulator) -> BasicOptimizer:
optimizer.add_observer(
EventType.START_EVALUATION,
functools.partial(
self._ropt_callback, optimizer=optimizer, simulator=simulator
self._on_before_forward_model_evaluation,
optimizer=optimizer,
simulator=simulator,
),
)

Expand Down

0 comments on commit d5069d0

Please sign in to comment.