Skip to content

Commit

Permalink
🐛 Try to fix callback error
Browse files Browse the repository at this point in the history
  • Loading branch information
Haneol-Kijm committed Sep 15, 2024
1 parent 8931236 commit 53a5d12
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions engine/callbacks.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,3 +20,10 @@ def on_test_end(self, *args, **kwargs):
file_name = f"{self.model_name}_{date.today()}.csv"
test_info.to_csv(file_name, index=False, lineterminator='\n')
print("Output csv file successfully saved!!")


def load_state_dict(self, state_dict):
self.predictions = state_dict['predictions']

def state_dict(self):
return {'predictions': self.predictions}

0 comments on commit 53a5d12

Please sign in to comment.