Skip to content

Commit 4cb2f59

Browse files
committed
Update
1 parent fe0bf00 commit 4cb2f59

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

intermediate_source/memory_format_tutorial.py

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -385,10 +385,12 @@ def attribute(m):
385385

386386
gc.collect()
387387

388-
if hasattr(torch, "_check_wrapper_patched"):
389-
delattr(torch, "_check_wrapper_patched")
390-
391-
old_attrs.clear()
388+
# Clear any references to the wrapper functions
389+
del old_attrs
390+
del contains_cl
391+
del print_inputs
392+
del check_wrapper
393+
del attribute
392394

393395
######################################################################
394396
# Work to do

0 commit comments

Comments
 (0)