CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutSign UpSign In
hukaixuan19970627

Real-time collaboration for Jupyter Notebooks, Linux Terminals, LaTeX, VS Code, R IDE, and more,
all in one place. Commercial Alternative to JupyterHub.

GitHub Repository: hukaixuan19970627/yolov5_obb
Path: blob/master/models/hub/yolov5-p2.yaml
Views: 475
1
# YOLOv5 🚀 by Ultralytics, GPL-3.0 license
2
3
# Parameters
4
nc: 80 # number of classes
5
depth_multiple: 1.0 # model depth multiple
6
width_multiple: 1.0 # layer channel multiple
7
anchors: 3 # auto-anchor evolves 3 anchors per P output layer
8
9
# YOLOv5 v6.0 backbone
10
backbone:
11
# [from, number, module, args]
12
[[-1, 1, Conv, [64, 6, 2, 2]], # 0-P1/2
13
[-1, 1, Conv, [128, 3, 2]], # 1-P2/4
14
[-1, 3, C3, [128]],
15
[-1, 1, Conv, [256, 3, 2]], # 3-P3/8
16
[-1, 6, C3, [256]],
17
[-1, 1, Conv, [512, 3, 2]], # 5-P4/16
18
[-1, 9, C3, [512]],
19
[-1, 1, Conv, [1024, 3, 2]], # 7-P5/32
20
[-1, 3, C3, [1024]],
21
[-1, 1, SPPF, [1024, 5]], # 9
22
]
23
24
# YOLOv5 v6.0 head
25
head:
26
[[-1, 1, Conv, [512, 1, 1]],
27
[-1, 1, nn.Upsample, [None, 2, 'nearest']],
28
[[-1, 6], 1, Concat, [1]], # cat backbone P4
29
[-1, 3, C3, [512, False]], # 13
30
31
[-1, 1, Conv, [256, 1, 1]],
32
[-1, 1, nn.Upsample, [None, 2, 'nearest']],
33
[[-1, 4], 1, Concat, [1]], # cat backbone P3
34
[-1, 3, C3, [256, False]], # 17 (P3/8-small)
35
36
[-1, 1, Conv, [128, 1, 1]],
37
[-1, 1, nn.Upsample, [None, 2, 'nearest']],
38
[[-1, 2], 1, Concat, [1]], # cat backbone P2
39
[-1, 1, C3, [128, False]], # 21 (P2/4-xsmall)
40
41
[-1, 1, Conv, [128, 3, 2]],
42
[[-1, 18], 1, Concat, [1]], # cat head P3
43
[-1, 3, C3, [256, False]], # 24 (P3/8-small)
44
45
[-1, 1, Conv, [256, 3, 2]],
46
[[-1, 14], 1, Concat, [1]], # cat head P4
47
[-1, 3, C3, [512, False]], # 27 (P4/16-medium)
48
49
[-1, 1, Conv, [512, 3, 2]],
50
[[-1, 10], 1, Concat, [1]], # cat head P5
51
[-1, 3, C3, [1024, False]], # 30 (P5/32-large)
52
53
[[21, 24, 27, 30], 1, Detect, [nc, anchors]], # Detect(P2, P3, P4, P5)
54
]
55
56