File tree Expand file tree Collapse file tree
openfl/component/aggregator Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -150,15 +150,17 @@ def __init__(
150150 self .quit_job_sent_to = []
151151
152152 self .tensor_db = TensorDB ()
153- if persist_checkpoint :
153+ if persist_checkpoint and not self . assigner . is_task_group_evaluation () :
154154 persistent_db_path = persistent_db_path or "tensor.db"
155155 logger .info (
156156 "Persistent checkpoint is enabled, setting persistent db at path %s" ,
157157 persistent_db_path ,
158158 )
159159 self .persistent_db = PersistentTensorDB (persistent_db_path )
160160 else :
161- logger .info ("Persistent checkpoint is disabled" )
161+ logger .info (
162+ "Either persistent checkpoint is disabled or the experiment is in evaluation mode"
163+ )
162164 self .persistent_db = None
163165 # FIXME: I think next line generates an error on the second round
164166 # if it is set to 1 for the aggregator.
@@ -225,8 +227,10 @@ def __init__(
225227
226228 self .secagg = SecAggSetup (self .uuid , self .authorized_cols , self .tensor_db )
227229
228- if self .persistent_db and self ._recover ():
229- logger .info ("Recovered state of aggregator" )
230+ # Only recover from persistent DB if not in evaluation mode
231+ if self .persistent_db and not self .assigner .is_task_group_evaluation ():
232+ if self ._recover ():
233+ logger .info ("Recovered state of aggregator" )
230234
231235 # TODO: Aggregator has no concrete notion of round_begin.
232236 # https://github.com/securefederatedai/openfl/pull/1195#discussion_r1879479537
You can’t perform that action at this time.
0 commit comments