Fix support for torch Module type hints in LightningCLI#7807
Fix support for torch Module type hints in LightningCLI#7807justusschock merged 5 commits intoLightning-AI:masterfrom mauvilsa:cli_torch_types
Conversation
Codecov Report
@@ Coverage Diff @@
## master #7807 +/- ##
=======================================
- Coverage 93% 88% -5%
=======================================
Files 199 199
Lines 13008 13008
=======================================
- Hits 12044 11425 -619
- Misses 964 1583 +619 |
|
I did verify that the tests were successful locally. Not sure why it is failing. |
|
I can reproduce the failure locally on |
|
I guess torchvision has changed a log between versions. In https://github.com/PyTorchLightning/pytorch-lightning/pull/7807/checks?check_run_id=2728907218 the error is I will look into this last error and probably also change the test to use something a bit more stable. |
- Run unit test only on newer torchvision versions in which the base class is Module.
for more information, see https://pre-commit.ci
| onnxruntime>=1.3.0 | ||
| hydra-core>=1.0 | ||
| jsonargparse[signatures]>=3.12.0 | ||
| jsonargparse[signatures]>=3.13.1 |
There was a problem hiding this comment.
Yes, the fix is there.
Co-authored-by: Carlos Mocholí <carlossmocholi@gmail.com>
* Fixed support for torch Module type hints in LightningCLI * - Fix issue with serializing values when type hint is Any. - Run unit test only on newer torchvision versions in which the base class is Module. * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Minor change * Update CHANGELOG.md Co-authored-by: Carlos Mocholí <carlossmocholi@gmail.com> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: Carlos Mocholí <carlossmocholi@gmail.com> (cherry picked from commit f345840)
* Fixed support for torch Module type hints in LightningCLI * - Fix issue with serializing values when type hint is Any. - Run unit test only on newer torchvision versions in which the base class is Module. * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Minor change * Update CHANGELOG.md Co-authored-by: Carlos Mocholí <carlossmocholi@gmail.com> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: Carlos Mocholí <carlossmocholi@gmail.com> (cherry picked from commit f345840)
What does this PR do?
Fixes a problem mentioned in #7774 (comment). It does not resolve the whole issue, only that single comment.
Before submitting
PR review
Anyone in the community is free to review the PR once the tests have passed.
Before you start reviewing make sure you have read Review guidelines. In short, see the following bullet-list:
Did you have fun?
Make sure you had fun coding 🙃