mirror of
https://github.com/oobabooga/text-generation-webui.git
synced 2026-03-05 05:03:50 +01:00
Clear the torch cache before generating
This commit is contained in:
parent
f4b27a39af
commit
e7a15a0361
|
|
@ -667,6 +667,10 @@ def generate(state):
|
|||
"""
|
||||
import torch
|
||||
|
||||
from modules.torch_utils import clear_torch_cache
|
||||
|
||||
clear_torch_cache()
|
||||
|
||||
try:
|
||||
model_name = state['image_model_menu']
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue