ComfyUI_InstantID icon indicating copy to clipboard operation
ComfyUI_InstantID copied to clipboard

Out of memory where I use cuda as InstantID Face Analysis

Open vvip2u opened this issue 1 year ago • 1 comments

InstantID Face Analysis: CUDA

logs

torch.cuda.OutOfMemoryError: Allocation on device 0 would exceed allowed memory. (out of memory)
Currently allocated     : 10.15 GiB
Requested               : 60.00 MiB
Device limit            : 24.00 GiB
Free (according to CUDA): 12.45 GiB
PyTorch limit (set by user-supplied memory fraction)
                        : 17179869184.00 GiB

I think my RTX3090 (24G) is enough to run with cuda. But change A model to B model, it failed.

My advice: I think it maybe optimize the GPU memory management.

FYI

vvip2u avatar Feb 28 '24 13:02 vvip2u

depends on the wokflow, the above message without context doesn't help much. The face analysis should be performed on the CPU anyway.

cubiq avatar Feb 28 '24 14:02 cubiq