AlexeyAB / darknet

YOLOv4 / Scaled-YOLOv4 / YOLO - Neural Networks for Object Detection (Windows and Linux version of Darknet )
http://pjreddie.com/darknet/
Other
21.65k stars 7.96k forks source link

Questions about yolov4 architecture #5484

Closed kaanakan closed 4 years ago

kaanakan commented 4 years ago

Hi,

For GPU we use a small number of groups (1 - 8) in convolutional layers: CSPResNeXt50 / CSPDarknet53.

I saw this in the Yolov4 paper but when I look at the yolov4.cfg, I could not find any groups parameter in the convolutional layers. So, is the group parameter used for only classification model?

Can you provide a block diagram for yolov4? (covering end-to-end architecture, CSPDarknet53, SPP, PANet, Yolov3 heads)

It would be great if you can state which parts of the yolov4.cfg file correspond to which model ( CSPDarknet53, SPP, PANet, Yolov3 heads).

Thanks in advance.

WongKinYiu commented 4 years ago
  1. https://github.com/AlexeyAB/darknet/issues/5466#issuecomment-623130824

  2. https://github.com/AlexeyAB/darknet/issues/5355#issuecomment-619884433

kaanakan commented 4 years ago

Thank you for your fast response. I understand the CSP architecture now and cfg file.

Is there any figures that show the architecture in an end-to-end fashion? Something like the figure below,

image image credit: https://towardsdatascience.com/yolo-v3-object-detection-53fb7d3bfe6b

WongKinYiu commented 4 years ago

https://github.com/lutzroeder/netron you can try this.

kaanakan commented 4 years ago

Thanks a lot!

AlexeyAB commented 4 years ago

For GPU we use a small number of groups (1 - 8) in convolutional layers: CSPResNeXt50 / CSPDarknet53.

I saw this in the Yolov4 paper but when I look at the yolov4.cfg, I could not find any groups parameter in the convolutional layers.

groups=1 by default for [convolutional] layers, so yes, we use groups=1 as mentioned in the paper.

violet17 commented 4 years ago

For GPU we use a small number of groups (1 - 8) in convolutional layers: CSPResNeXt50 / CSPDarknet53.

I saw this in the Yolov4 paper but when I look at the yolov4.cfg, I could not find any groups parameter in the convolutional layers.

groups=1 by default for [convolutional] layers, so yes, we use groups=1 as mentioned in the paper.

@AlexeyAB Is this means that the [convolutional] layers aren't partial into to two parts in CSP module? Just like the figure below? image

WongKinYiu commented 4 years ago

https://github.com/AlexeyAB/darknet/issues/5466#issuecomment-623130824

violet17 commented 4 years ago

#5466 (comment)

Hi WongKinYiu, thanks. I figure out that yolov5 uses the conv64 stride2 and splits it into two conv 64.