-
Notifications
You must be signed in to change notification settings - Fork 694
Description
Hi, when I execute the following line in my code:
model_trt = torch2trt(net, [example_input], fp16_mode=True, max_batch_size=1)
it takes some time and then I receive the following output:
"
[07/25/2022-14:14:51] [TRT] [E] 2: [virtualMemoryBuffer.cpp::resizePhysical::161] Error Code 2: OutOfMemory (no further information)
[07/25/2022-14:14:51] [TRT] [E] 2: [virtualMemoryBuffer.cpp::resizePhysical::161] Error Code 2: OutOfMemory (no further information)
[07/25/2022-14:14:51] [TRT] [E] 2: [virtualMemoryBuffer.cpp::resizePhysical::161] Error Code 2: OutOfMemory (no further information)
[07/25/2022-14:14:51] [TRT] [E] 2: [virtualMemoryBuffer.cpp::resizePhysical::161] Error Code 2: OutOfMemory (no further information)
[07/25/2022-14:14:51] [TRT] [E] 2: [virtualMemoryBuffer.cpp::resizePhysical::161] Error Code 2: OutOfMemory (no further information)
Segmentation fault (core dumped)
"
I see that my GPU utilization goes up to almost 100% before the crash and it looks like a GPU memory issue.
I've added torch.cuda.empty_cache() before the execution of torch2trt and the problem still happens.
The size of my model is about 1.78 and the size of my GPU is 6GB/
System info:
GPU - NVIDIA GeForce RTX 3060 Laptop
Operating System - ubuntu 22.04
Cuda Version - V11.1.105
Nvidia driver version - 510.73.05
torch - 1.9.1+cu111
torch2trt - 0.3.0
Thank you in advance!