Skip to content

[benchmarks] Fix AMP data-type.#6550

Merged
ysiraichi merged 2 commits intomasterfrom
ysiraichi/fix-amp-dtype
Feb 17, 2024
Merged

[benchmarks] Fix AMP data-type.#6550
ysiraichi merged 2 commits intomasterfrom
ysiraichi/fix-amp-dtype

Conversation

@ysiraichi
Copy link
Copy Markdown
Collaborator

This PR fixes the behavior of AMP, aligning it to that of PyTorch HUD. Instead of setting a default data-type, we use the default one.

cc @miladm

@ysiraichi ysiraichi force-pushed the ysiraichi/fix-amp-dtype branch from d75a987 to 08213f3 Compare February 16, 2024 14:10
@JackCaoG JackCaoG requested a review from yeounoh February 16, 2024 18:08
@JackCaoG
Copy link
Copy Markdown
Collaborator

@yeounoh can you review this one? I don't remember why we set the default dtype.

@ysiraichi
Copy link
Copy Markdown
Collaborator Author

Truth is: it was my PR that set the default AMP data-type for the benchmarking scripts. The reason being that I hadn't understood the code (linked in the OP) correctly.

@ysiraichi
Copy link
Copy Markdown
Collaborator Author

I have reset the AMP data-types according to whatever is the default data type in torch.<device>.amp (or torch_xla.amp).

@ysiraichi ysiraichi merged commit 3d21839 into master Feb 17, 2024
amithrm pushed a commit to amithrm/xla that referenced this pull request Mar 1, 2024
bhavya01 pushed a commit that referenced this pull request Apr 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants