Skip to content

Commit

Permalink
typo
Browse files Browse the repository at this point in the history
  • Loading branch information
brandon-edwards committed Oct 8, 2024
1 parent dc495ea commit e65eeef
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions examples/fl_post/fl/project/src/runner_nnunetv1.py
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ def compare_tensor_dicts(td_1, td_2, tag="", epsilon=0.0001):
hash_2 = np.sum([np.mean(np.array(_value)) for _value in td_2.values()])
delta = np.abs(hash_1 - hash_2)
if delta > epsilon:
raise VaueError(f"The tensor dict comparison {tag} failed with delta: {delta} against an accepted error of: {epsilon}.")
raise ValueError(f"The tensor dict comparison {tag} failed with delta: {delta} against an accepted error of: {epsilon}.")


if not from_checkpoint:
Expand Down Expand Up @@ -244,7 +244,7 @@ def compare_tensor_dicts(td_1, td_2, tag="", epsilon=0.0001):
else:
checkpoint_dict = self.load_checkpoint()
# double check
compare_tensor_dicts(td_1=input_tensor_dict,td_2=checkpoint_dict['state_dict'])
compare_tensor_dicts(td_1=input_tensor_dict,td_2=checkpoint_dict['state_dict'], tag="checkpoint VS fromOpenFL")

(all_tr_losses, _, _, _) = checkpoint_dict['plot_stuff']
# these metrics are appended to the checkpoint each call to train, so it is critical that we are grabbing this right after
Expand Down

0 comments on commit e65eeef

Please sign in to comment.