mirror of
https://github.com/nerfstudio-project/nerfstudio.git
synced 2026-11-17 21:33:56 +08:00
fix: saving ckpt error when ckpt folder has some folder inside (#3516)
This commit is contained in:
1 parent
cef95890f3
commit
9e5bbd9819
1 file changed
+2
-2
@@ -478,8 +478,8 @@ class Trainer:
|
||||
)
|
||||
# possibly delete old checkpoints
|
||||
if self.config.save_only_latest_checkpoint:
|
||||
# delete everything else in the checkpoint folder
|
||||
for f in self.checkpoint_dir.glob("*"):
|
||||
# delete every other checkpoint in the checkpoint folder
|
||||
for f in self.checkpoint_dir.glob("*.ckpt"):
|
||||
if f != ckpt_path:
|
||||
f.unlink()
|
||||
|
||||
|
||||
Reference in new issue
Block a user