From 5f82e5ba0dc920784c7f4e90dbb3eed2153d8e06 Mon Sep 17 00:00:00 2001 From: Gnome Ann <> Date: Fri, 20 Aug 2021 11:17:34 -0400 Subject: [PATCH] Also clear CUDA cache twice if using breakmodel --- aiserver.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/aiserver.py b/aiserver.py index 40e7c602..45bd28ed 100644 --- a/aiserver.py +++ b/aiserver.py @@ -1119,7 +1119,7 @@ def generate(txt, min, max): genselect(genout) # Clear CUDA cache again if using GPU - if(vars.hascuda and vars.usegpu): + if(vars.hascuda and (vars.usegpu or vars.breakmodel)): torch.cuda.empty_cache() set_aibusy(0)