Skip to content

Commit 20f4189

Browse files
committed
Update
1 parent 7300783 commit 20f4189

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

conf.py

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -112,17 +112,13 @@
112112
def reset_seeds(gallery_conf, fname):
113113
global torch
114114
torch._dynamo.reset()
115-
torch.cuda.empty_cache()
116-
if torch.cuda.is_available():
117-
torch.cuda.empty_cache()
118-
torch.cuda.reset_peak_memory_stats()
115+
torch.dynamo.reset()
116+
torch.cuda.empty_cache()
119117
torch.manual_seed(42)
120118
torch.set_default_device(None)
121119
random.seed(10)
122120
numpy.random.seed(10)
123121
gc.collect()
124-
import torch._inductor.utils
125-
torch._inductor.utils.clear_inductor_caches()
126122

127123

128124
sphinx_gallery_conf = {

0 commit comments

Comments
 (0)