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

Fix Throughputbenchmark issue #144669

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

Conversation

shiyang-weng
Copy link

@shiyang-weng shiyang-weng commented Jan 13, 2025

Copy link

pytorch-bot bot commented Jan 13, 2025

🔗 Helpful Links

🧪 See artifacts and rendered test results at hud.pytorch.org/pr/144669

Note: Links to docs will display an error until the docs builds have been completed.

❌ 2 New Failures

As of commit b5f6e1c with merge base 6e77d7c (image):

NEW FAILURES - The following jobs have failed:

This comment was automatically generated by Dr. CI and updates every 15 minutes.

Copy link

CLA Not Signed

Copy link
Contributor

This PR needs a release notes: label

If your changes are user facing and intended to be a part of release notes, please use a label starting with release notes:.

If not, please add the topic: not user facing label.

To add a label, you can comment to pytorchbot, for example
@pytorchbot label "topic: not user facing"

For more information, see
https://github.com/pytorch/pytorch/wiki/PyTorch-AutoLabel-Bot#why-categorize-for-release-notes-and-how-does-it-work.

@shiyang-weng shiyang-weng changed the title Wengshiy/fix benchmark Fix Throughputbenchmark issue Jan 13, 2025
@williamwen42 williamwen42 added the topic: bug fixes topic category label Jan 13, 2025
Copy link
Collaborator

@leslie-fang-intel leslie-fang-intel left a comment

Choose a reason for hiding this comment

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

Please add the UT

@@ -539,6 +539,9 @@ struct AutocastState {

bool operator==(const AutocastState& o) const {
for (size_t i = 0; i < DEVICES.size(); i++) {
if (enabled[i] == false && o.enabled[i] == false) {
continue;
Copy link
Collaborator

Choose a reason for hiding this comment

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

Please elaborate why skips the check of dtype when enabled is False.

for (size_t i = 0; i < DEVICES.size(); i++) {
at::autocast::set_autocast_enabled(DEVICES[i], autocast_enabled[i]);
at::autocast::set_autocast_dtype(DEVICES[i], autocast_dtype[i]);
}
Copy link
Collaborator

Choose a reason for hiding this comment

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

Do we need to check the status of cache_enabled?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

ThroughputBenchmark incorrectly change autocast dtype on CPU
4 participants