From 19212bbfac9e6421a35b279867cb2be4f76819c3 Mon Sep 17 00:00:00 2001 From: Georg Reich Date: Tue, 12 Mar 2024 15:06:40 +0100 Subject: [PATCH] removed first run continue_run warnings --- neurolib/models/model.py | 3 --- neurolib/models/multimodel/model.py | 3 --- 2 files changed, 6 deletions(-) diff --git a/neurolib/models/model.py b/neurolib/models/model.py index 5a068956..ea31303d 100644 --- a/neurolib/models/model.py +++ b/neurolib/models/model.py @@ -324,9 +324,6 @@ def storeOutputsAndStates(self, t, variables, append=False): def setInitialValuesToLastState(self): """Reads the last state of the model and sets the initial conditions to that state for continuing a simulation.""" if not all([sv in self.state for sv in self.state_vars]): - logging.warning( - f"`setInitialValuesToLastState` was called, but the state dict is incomplete. This is probably caused by `continue_run=True` on the first model run." - ) return for iv, sv in zip(self.init_vars, self.state_vars): # if state variables are one-dimensional (in space only) diff --git a/neurolib/models/multimodel/model.py b/neurolib/models/multimodel/model.py index cc000de9..381d10a9 100644 --- a/neurolib/models/multimodel/model.py +++ b/neurolib/models/multimodel/model.py @@ -203,9 +203,6 @@ def integrate(self, append_outputs=False, simulate_bold=False, noise_input=None) def setInitialValuesToLastState(self): if not self.state: - logging.warning( - f"`setInitialValuesToLastState` was called, but the state dict is empty. This is probably caused by `continue_run=True` on the first model run." - ) return new_initial_state = np.zeros((self.model_instance.initial_state.shape[0], self.maxDelay + 1)) total_vars_counter = 0