Pytorch-lightning: Split ModelCheckpoint filepath into dirpath and filename

Created on 21 Sep 2020  ·  7Comments  ·  Source: PyTorchLightning/pytorch-lightning

🚀 Feature

Previous discussions:

https://github.com/PyTorchLightning/pytorch-lightning/pull/3163#issuecomment-683539565
https://github.com/PyTorchLightning/pytorch-lightning/pull/3163#issuecomment-695854769
https://github.com/PyTorchLightning/pytorch-lightning/issues/3001

Idea:

Keep backwards compatibility by having filepath (old parameter) and dirpath, filename (new parameters)
- if filepath is set: old logic, show deprecated warning.
- if dirpath and filename are set: new logic.
- if filepath, dirpath, and filename are set: raise MisconfigurationException


cc @Borda @awaelchli @ananthsub @rohitgr7 @ydcjeff

enhancement help wanted let's do it!

Most helpful comment

but it was not properly resolved, right? do you remember the issue/PR?

There was this PR #2584 but was slightly different

All 7 comments

I have been suggesting this for a long time. 😅

I know, @Borda just asked me to create a new issue to discuss.

I have been suggesting this for a long time. 😅

but it was not properly resolved, right? do you remember the issue/PR?

I like it, I vote for this :) We have plenty of tests for the filepath arg (I think thanks to @carmocca?), so the guarantee for back compatibility is there.

but it was not properly resolved, right? do you remember the issue/PR?

There was this PR #2584 but was slightly different

Should we have these parameters now in ModelCheckpoint since 1.x is released?

Yes, I think it would be useful.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

DavidRuhe picture DavidRuhe  ·  3Comments

Vichoko picture Vichoko  ·  3Comments

monney picture monney  ·  3Comments

williamFalcon picture williamFalcon  ·  3Comments

as754770178 picture as754770178  ·  3Comments