Remove release_resources() as it does not work

This commit is contained in:
henryruhs 2023-07-18 11:53:02 +02:00
parent a93af16711
commit fffdef93a7

View File

@ -112,11 +112,6 @@ def limit_resources() -> None:
resource.setrlimit(resource.RLIMIT_DATA, (memory, memory))
def release_resources() -> None:
if 'CUDAExecutionProvider' in roop.globals.execution_providers:
torch.cuda.empty_cache()
def pre_check() -> bool:
if sys.version_info < (3, 9):
update_status('Python version is not supported - please upgrade to 3.9 or higher.')
@ -147,7 +142,6 @@ def start() -> None:
update_status('Progressing...', frame_processor.NAME)
frame_processor.process_image(roop.globals.source_path, roop.globals.output_path, roop.globals.output_path)
frame_processor.post_process()
release_resources()
# validate image
if is_image(roop.globals.target_path):
update_status('Processing to image succeed!')
@ -173,7 +167,6 @@ def start() -> None:
update_status('Progressing...', frame_processor.NAME)
frame_processor.process_video(roop.globals.source_path, temp_frame_paths)
frame_processor.post_process()
release_resources()
# create video
if roop.globals.keep_fps:
fps = detect_fps(roop.globals.target_path)