diff --git a/backend/src/pytorch/InterpolateTorch.py b/backend/src/pytorch/InterpolateTorch.py index fab8b55a..49ecb40d 100644 --- a/backend/src/pytorch/InterpolateTorch.py +++ b/backend/src/pytorch/InterpolateTorch.py @@ -50,11 +50,11 @@ def copyTensor(self, tensorToCopy: torch.Tensor, tensorCopiedTo: torch.Tensor): self.stream.synchronize() def hotUnload(self): - del self.flownet - del self.encode - del self.tenFlow_div - del self.backwarp_tenGrid - del self.f0encode + self.flownet = None + self.encode = None + self.tenFlow_div = None + self.backwarp_tenGrid = None + self.f0encode = None gc.collect() torch.cuda.empty_cache() torch.cuda.reset_max_memory_allocated()