You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Besides {_enter/_exit}_autocast, from trace_rules.py, I could find
{_enter/_exit}_dual_level for forward mode auto-diff, {_enter/_exit}_inference_mode for inference mode.
Besides these, looking at ctx_manager.py, there could also be Stream, Grad, Device related context managers which are mapped to something like the following
old_stream=torch.cuda.get_current_stream()
new_stream=torch.cuda.Stream()
set_stream(new_stream)
# Some operationsset_stream(old_stream)
Originally posted by @kshitij12345 in #1400 (comment)
Besides {_enter/_exit}_autocast, from trace_rules.py, I could find
{_enter/_exit}_dual_level for forward mode auto-diff, {_enter/_exit}_inference_mode for inference mode.
Besides these, looking at ctx_manager.py, there could also be
Stream
,Grad
,Device
related context managers which are mapped to something like the followingRefs:
https://github.com/pytorch/pytorch/blob/781c68c86549aa2fd155f92afb0406b7577ab31c/torch/_dynamo/trace_rules.py#L550-L552
https://github.com/pytorch/pytorch/blob/781c68c86549aa2fd155f92afb0406b7577ab31c/torch/_dynamo/trace_rules.py#L2393-L2394
The text was updated successfully, but these errors were encountered: