Skip to content

Commit a9e7027

Browse files
authored
Merge branch 'main' into aistats2025
2 parents 9ef548d + f99530c commit a9e7027

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

cebra/solver/base.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -231,7 +231,8 @@ def fit(self,
231231
self.decoding(loader, valid_loader))
232232
if save_hook is not None:
233233
save_hook(num_steps, self)
234-
self.save(logdir, f"checkpoint_{num_steps:#07d}.pth")
234+
if logdir is not None:
235+
self.save(logdir, f"checkpoint_{num_steps:#07d}.pth")
235236

236237
def step(self, batch: cebra.data.Batch) -> dict:
237238
"""Perform a single gradient update.

0 commit comments

Comments
 (0)