Skip to content

Fix failing sharded_checkpoint tests that fail when pytorch 1.13 is not installed #1988

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 7 commits into from
Feb 23, 2023

Conversation

eracah
Copy link
Contributor

@eracah eracah commented Feb 22, 2023

What does this PR do?

Skip all the tests in test_sharded_checkpoint.py IF pytorch 1.13 is not installed. This is because these tests use FSDP and if Composer uses FSDP and pytorch 1.13 is not installed, the process will fail.

These failing tests do not mean anything will break for user, it just means the tests fail when they shouldn't

TLDR: add a pytest.skip call (conditional on pytorch 1.13 is not being installed) to all tests in test_sharded_checkpoint.py

@eracah eracah requested a review from bandish-shah February 22, 2023 02:42
@eracah eracah changed the title Skip test Fix failing sharded_checkpoint tests that fail when pytorch 1.13 is not installed Feb 22, 2023
@eracah eracah marked this pull request as ready for review February 22, 2023 19:31
@eracah eracah requested a review from dakinggg February 22, 2023 19:32
Copy link
Contributor

@bandish-shah bandish-shah left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See comments, better to use @pytest.mark.skipif() decorator. Also would be good to give a clear reason as to why this test is skipped vs just spitting out a PyTorch version.

@eracah eracah requested a review from bandish-shah February 23, 2023 19:26
Copy link
Contributor

@bandish-shah bandish-shah left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM thanks for the changes!

@bandish-shah bandish-shah merged commit 33a28b5 into mosaicml:dev Feb 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants