Draft
Conversation
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/tutorials/3809
Note: Links to docs will display an error until the docs builds have been completed. ✅ No FailuresAs of commit 2eaef42 with merge base 084b358 ( This comment was automatically generated by Dr. CI and updates every 15 minutes. |
Switches gradient_checkpointing_enable() to use non-reentrant checkpointing, which properly preserves dropout RNG state during recomputation and resolves the SystemError during loss.backward(). Issue: #3774
This reverts commit 6e486af.
Disable dropout (resid_pdrop=0, attn_pdrop=0, embd_pdrop=0) in the run_training_ac function to avoid SystemError from _VF.dropout returning NULL during backward recomputation of GPT2Block. Dropout is irrelevant to the memory profiling purpose of this tutorial. Issue: #3774
Contributor
Author
|
@basilwong here is an attempt to get this to work. It is a bandaid at best, still needs an actual fix |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Test mosaic tutorial post 2.11 release
Disabled GPT-2 dropout (resid_pdrop=0, attn_pdrop=0, embd_pdrop=0) in run_training_ac() to work around a PyTorch 2.11 bug where the CUDA dropout kernel crashes during gradient checkpointing recomputation (#3774). Dropout has no impact on this tutorial's purpose of memory profiling with Mosaic.