Skip to content
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

Update and disable push_tests_mps workflow #10442

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

hlky
Copy link
Collaborator

@hlky hlky commented Jan 3, 2025

What does this PR do?

Updates push_tests_mps to separate tests by category and fix some environment issues. For now a lot of failures are due to a problem with GitHub's runners so we also disable the workflow.

Who can review?

Anyone in the community is free to review the PR once the tests have passed. Feel free to tag
members/contributors who may be interested in your PR.

@sayakpaul

@sayakpaul
Copy link
Member

Does removing them help launch the tests? Could we maybe trigger it manually?

@hlky
Copy link
Collaborator Author

hlky commented Jan 3, 2025

I don't know if we can trigger it manually. Currently the tests launch on push to main and eventually segfault after some scheduler tests

https://github.com/huggingface/diffusers/actions/runs/12588771861/job/35087350062#step:7:8211

Most pipeline tests seem to be failing and there are some warnings

There was a problem when trying to write in your cache folder (/System/Volumes/Data/mnt/cache/hub). You should set the environment variable TRANSFORMERS_CACHE to a writable directory.
There was a problem when trying to write in your cache folder (/System/Volumes/Data/mnt/cache/hub). Please, ensure the directory exists and can be written to.

It suggests some pipeline tests are failing because of it, but there are no tracebacks for individual test failures, probably due to the segfault.

@sayakpaul
Copy link
Member

Sorry should have been clearer.

What we could do to ensure the MPS stuff runs successfully:

  • Temporarily have a workflow in this PR with the same contents as the one in .github/workflows/push_tests_mps.yml.
  • Have the temporary workflow triggered on PRs so that we can verify it.
  • Once we confirm things are working as expected, we delete the temporary workflow.

Does this sound good?

@sayakpaul
Copy link
Member

Nice seems like the tests are getting picked up? We can let them run and fix anything in a follow-up PR? WDYT?

@hlky
Copy link
Collaborator Author

hlky commented Jan 3, 2025

There are still some failures so far, I'll compare to one of the last runs to check if anything is fixed. I think priority is fixing the segfault but I see no indication of anything that could be causing it. We could separate the tests like models, pipelines, schedulers, might help break it down as there are a lot of FAILED and a lot of SKIPPED.

@sayakpaul
Copy link
Member

Makes sense and okay for me to tackle that in this PR. Thanks! Let me know if I can help.

@HuggingFaceDocBuilderDev

The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update.

@@ -220,7 +220,7 @@ def set_timesteps(
self.num_inference_steps = num_inference_steps

step_ratio = self.config.num_train_timesteps // self.num_inference_steps
timesteps = (np.arange(0, num_inference_steps) * step_ratio).round()[::-1].copy().astype(np.int64)
timesteps = (np.arange(0, num_inference_steps) * step_ratio).round()[::-1].copy().astype(np.int32)
Copy link
Member

Choose a reason for hiding this comment

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

Won't it cause any numerical problems or qualitative problems?

Copy link
Collaborator Author

@hlky hlky Jan 12, 2025

Choose a reason for hiding this comment

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

Should be ok but I'll cherry-pick this + the other fix (64553b3) and review with @yiyixuxu. Edit: this PR can replace the current mps workflow as discussed.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

PR is now only workflow changes, we may want to just disable it until we get the new runner though.

Copy link
Member

Choose a reason for hiding this comment

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

That is okay with me.

@hlky hlky force-pushed the mps-test-hub-home branch from 12fe529 to 1c7df8a Compare January 13, 2025 05:45
@hlky hlky changed the title HF_HOME in push_tests_mps workflow Update push_tests_mps workflow Jan 13, 2025
@hlky hlky mentioned this pull request Jan 13, 2025
@hlky hlky changed the title Update push_tests_mps workflow Update and disable push_tests_mps workflow Jan 13, 2025
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.

3 participants