# GPU Out Of Memory - Tensorflow Object Detection API

**URL:** <https://forums.developer.nvidia.com/t/gpu-out-of-memory-tensorflow-object-detection-api/280574>\
**Category:** Frameworks (archived)\
**Created:** [January 29, 2024, 6:25pm UTC](https://forums.developer.nvidia.com/t/gpu-out-of-memory-tensorflow-object-detection-api/280574 "2024-01-29T18:25:20Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![lucas.a.alves](https://developer.download.nvidia.com/images/forums/profile-default-devtalk-84.png) [@lucas.a.alves](https://forums.developer.nvidia.com/u/lucas.a.alves)\
**Post date:** [January 29, 2024, 6:25pm UTC](https://forums.developer.nvidia.com/t/gpu-out-of-memory-tensorflow-object-detection-api/280574/1 "2024-01-29T18:25:20Z")

</div>

I’m currently training an EfficientDetD7 to detect objects in images, using the ‘Tensorflow Object Detection API’ framework.  
I’m using an NVIDIA H100 GPU with 80 Gb of VRAM. I can only train with a batch size equal to or less than 2. After some tests I realized that each image in the batch occupies 33 Gb. Therefore, a batch size equal to 1 consumes 33 Gb and a batch size equal to 2 consumes 66 Gb.  
Is there any way to reduce memory consumption? I’m already using tensorflow’s Memory Growth.

---

<div class="post-metadata">

**Author:** ![Sirens\_uk](https://sea2.discourse-cdn.com/nvidia/user_avatar/forums.developer.nvidia.com/sirens_uk/32/204055_2.png) [@Sirens\_uk](https://forums.developer.nvidia.com/u/Sirens_uk)\
**Post date:** [January 22, 2025, 2:00pm UTC](https://forums.developer.nvidia.com/t/gpu-out-of-memory-tensorflow-object-detection-api/280574/2 "2025-01-22T14:00:49Z")

</div>

One thing to consider can you actually run inference on your chosen model?

You probably need to reduce the batch size on all honesty.
