Replies: 1 comment
-
Hi @RunningLeon, |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi all,
I am experiencing strange behaviors in terms of memory occupation on the GPU.
Situation is the following on a server with T4 card:
I have a custom model (called net) that occupies 2081 MB. I want to istantiate a segmentation model on the same gpu that should run after my model. I chose two segmentation model from your modelzoo:
I istantiate both model with the following lines of code:
Then i run inference, as the demo you provided, with:
result = inference_segmentor(model, img)
Now, i have critical issue: memory on GPU. To evaluate the impact of segmentation model in terms of memory i setup a simple snippet that i monitor with nvidia-smi:
If i just istantiate my model, it occupies 2081 MB. If i run inference with my model, the occupation remain the same (this model is on TRT).
For the segformer:
For the convnext:
I don't understand this growing pattern in memory occupation and most important i cannot reproduce the memory occupation you mentioned in the above model's config pages.
Is there another way to istantiate and infer the models?
Why there is so much difference in terms of memory between just istantiate a segmentation model and infering with it?
Why the model running separately occupy less memory then togheter?
Thanks in advance
P.S.: i tried this stuff not just on T4, but also on V100, A30 and RTXA6000. And the memory occupation is NEVER the same among different cards. If you feel to relate this problem, i can add more information about this. At the moment i just want to fix this issue on T4.
Beta Was this translation helpful? Give feedback.
All reactions