tanluren / yolov3-channel-and-layer-pruning

yolov3 yolov4 channel and layer pruning, Knowledge Distillation 层剪枝,通道剪枝,知识蒸馏
Apache License 2.0
1.5k stars 446 forks source link

刚开始推理时,GPU内存占用持续增加 #176

Open LiuRJun opened 2 years ago

LiuRJun commented 2 years ago

我的batch_size=4,GPU内存为6G. 在前向推理过程中,每次到了卷积层运行时,GPU内存就会增加,0.3G左右,调试发现,推理到第49层,GPU内存就爆了。 image 也就是在执行x=module(x)时就会增加GPU的内存占用,请问,有哪位大神能解释下原因