ChatLiterature / clear.py
carbonnnnn's picture
First version
8677815
raw
history blame contribute delete
155 Bytes
# USE THIS FILE TO CLEAR GPU CACHE
import gc
import torch
# def report_gpu():
print(torch.cuda.list_gpu_processes())
gc.collect()
torch.cuda.empty_cache()