Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

YOLOv5 6.0 Model Structure #6885

Closed
1 task done
WZMIAOMIAO opened this issue Mar 7, 2022 · 7 comments
Closed
1 task done

YOLOv5 6.0 Model Structure #6885

WZMIAOMIAO opened this issue Mar 7, 2022 · 7 comments
Labels
documentation Improvements or additions to documentation question Further information is requested

Comments

@WZMIAOMIAO
Copy link

WZMIAOMIAO commented Mar 7, 2022

Search before asking

Question

First of all, thank you for your great works.
I drew the structure of the model according to yolov5l.yaml (v6.0). I'm not sure whether there are any mistakes. And I want to contribute this picture to the community and help other learners.

yolov5

Additional

No response

@WZMIAOMIAO WZMIAOMIAO added the question Further information is requested label Mar 7, 2022
@glenn-jocher
Copy link
Member

@WZMIAOMIAO very nice! Looks all correct.

@glenn-jocher glenn-jocher added the documentation Improvements or additions to documentation label Mar 8, 2022
@WZMIAOMIAO
Copy link
Author

update bottleneck, because e=1.0.

yolov5/models/common.py

Lines 127 to 139 in e6e36aa

class C3(nn.Module):
# CSP Bottleneck with 3 convolutions
def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ch_out, number, shortcut, groups, expansion
super().__init__()
c_ = int(c2 * e) # hidden channels
self.cv1 = Conv(c1, c_, 1, 1)
self.cv2 = Conv(c1, c_, 1, 1)
self.cv3 = Conv(2 * c_, c2, 1) # act=FReLU(c2)
self.m = nn.Sequential(*(Bottleneck(c_, c_, shortcut, g, e=1.0) for _ in range(n)))
# self.m = nn.Sequential(*[CrossConv(c_, c_, 3, 1, g, 1.0, shortcut) for _ in range(n)])
def forward(self, x):
return self.cv3(torch.cat((self.m(self.cv1(x)), self.cv2(x)), dim=1))

@WZMIAOMIAO
Copy link
Author

WZMIAOMIAO commented Mar 9, 2022

@glenn-jocher Next week I want to write a technical summary(markdown) about YOLOV5(v6.0). Then put it in the YOLOV5 Docs to help people learn yolov5. I don't know if you're interested. 😄

@glenn-jocher
Copy link
Member

@WZMIAOMIAO yes that would be great! v6.0 and v6.1 use the same (current) architecture, so the docs will also apply to the latest models.

@WZMIAOMIAO
Copy link
Author

WZMIAOMIAO commented Mar 17, 2022

@WZMIAOMIAO yes that would be great! v6.0 and v6.1 use the same (current) architecture, so the docs will also apply to the latest models.

hi, I briefly summarized yolov5(v6.0). I hope you can take a look at it when you have time. #6998

@chelsea456
Copy link

Search before asking

Question

First of all, thank you for your great works.

I drew the structure of the model according to yolov5l.yaml (v6.0). I'm not sure whether there are any mistakes. And I want to contribute this picture to the community and help other learners.

yolov5

Additional

No response

Hi you, what program you use draw this picture. Tks you

@scraus
Copy link

scraus commented Dec 27, 2022

Search before asking

Question

First of all, thank you for your great works. I drew the structure of the model according to yolov5l.yaml (v6.0). I'm not sure whether there are any mistakes. And I want to contribute this picture to the community and help other learners.

yolov5

Additional

No response

Hello @WZMIAOMIAO! What do P1, P2, P3, and so on mean? And what does C3 mean? Thank you for your help! 🙏🙇‍♀️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation question Further information is requested
Projects
None yet
Development

No branches or pull requests

4 participants