π [Update] document of get start, turn table->tabs
Browse files
docs/0_get_start/0_quick_start.rst
CHANGED
@@ -6,6 +6,7 @@ Quick Start
|
|
6 |
If more detailed modifications are needed, custom content should be modularized as much as possible to avoid extensive code modifications.
|
7 |
|
8 |
.. _QuickInstallYOLO:
|
|
|
9 |
Install YOLO
|
10 |
------------
|
11 |
|
|
|
6 |
If more detailed modifications are needed, custom content should be modularized as much as possible to avoid extensive code modifications.
|
7 |
|
8 |
.. _QuickInstallYOLO:
|
9 |
+
|
10 |
Install YOLO
|
11 |
------------
|
12 |
|
docs/0_get_start/1_introduction.rst
CHANGED
@@ -1,9 +1,66 @@
|
|
1 |
What is YOLO
|
2 |
============
|
3 |
|
|
|
4 |
|
5 |
-
|
6 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
7 |
|
8 |
Loss Function
|
9 |
-------------
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
What is YOLO
|
2 |
============
|
3 |
|
4 |
+
``YOLO`` (You Only Look Once) is a state-of-the-art, real-time object detection system. It is designed to predict bounding boxes and class probabilities for objects in an image with high accuracy and speed. YOLO models, including the latest YOLOv9, are known for their efficiency in detecting objects in a single forward pass through the network, making them highly suitable for real-time applications.
|
5 |
|
6 |
+
YOLOv9 introduces improvements in both architecture and loss functions to enhance prediction accuracy and inference speed.
|
7 |
+
|
8 |
+
Forward Process
|
9 |
+
---------------
|
10 |
+
|
11 |
+
The forward process of YOLOv9 can be visualized as follows:
|
12 |
+
|
13 |
+
.. mermaid::
|
14 |
+
|
15 |
+
graph LR
|
16 |
+
subgraph YOLOv9
|
17 |
+
Auxiliary
|
18 |
+
AP["Auxiliary Prediction"]
|
19 |
+
end
|
20 |
+
BackBone-->FPN;
|
21 |
+
FPN-->PAN;
|
22 |
+
PAN-->MP["Main Prediction"];
|
23 |
+
BackBone-->Auxiliary;
|
24 |
+
Auxiliary-->AP;
|
25 |
+
|
26 |
+
- **BackBone**: Extracts features from the input image.
|
27 |
+
- **FPN (Feature Pyramid Network)**: Aggregates features at different scales.
|
28 |
+
- **PAN (Region Proposal Network)**: Proposes regions of interest.
|
29 |
+
- **Main Prediction**: The primary detection output.
|
30 |
+
- **Auxiliary Prediction**: Additional predictions to assist the main prediction.
|
31 |
|
32 |
Loss Function
|
33 |
-------------
|
34 |
+
|
35 |
+
The loss function of YOLOv9 combines several components to optimize the model's performance:
|
36 |
+
|
37 |
+
.. mermaid::
|
38 |
+
|
39 |
+
flowchart LR
|
40 |
+
gtb-->cls
|
41 |
+
gtb["Ground Truth"]-->iou
|
42 |
+
pdm-.->cls["Max Class"]
|
43 |
+
pdm["Main Prediction"]-.->iou["Closest IoU"]
|
44 |
+
pdm-.->anc["box in anchor"]
|
45 |
+
cls-->gt
|
46 |
+
iou-->gt["Matched GT Box"]
|
47 |
+
anc-.->gt
|
48 |
+
|
49 |
+
gt-->Liou["IoU Loss"]
|
50 |
+
pdm-->Liou
|
51 |
+
pdm-->Lbce
|
52 |
+
gt-->Lbce["BCE Loss"]
|
53 |
+
gt-->Ldfl["DFL Loss"]
|
54 |
+
pdm-->Ldfl
|
55 |
+
|
56 |
+
Lbce-->ML
|
57 |
+
Liou-->ML
|
58 |
+
Ldfl-->ML["Total Loss"]
|
59 |
+
|
60 |
+
- **Ground Truth**: The actual labels and bounding boxes in the dataset.
|
61 |
+
- **Main Prediction**: The model's predicted bounding boxes and class scores.
|
62 |
+
- **IoU (Intersection over Union)**: Measures the overlap between the predicted and ground truth boxes.
|
63 |
+
- **BCE (Binary Cross-Entropy) Loss**: Used for class prediction.
|
64 |
+
- **DFL (Distribution Focal Loss)**: Used for improving the precision of bounding box regression.
|
65 |
+
|
66 |
+
By optimizing these components, YOLOv9 aims to achieve high accuracy and robustness in object detection tasks.
|
docs/0_get_start/2_installations.rst
CHANGED
@@ -10,26 +10,42 @@ Torch Requirements
|
|
10 |
|
11 |
The following table summarizes the torch requirements for different operating systems and hardware configurations:
|
12 |
|
13 |
-
|
14 |
-
|
15 |
-
|
16 |
-
|
17 |
-
|
18 |
-
|
19 |
-
|
20 |
-
|
21 |
-
|
22 |
-
|
23 |
-
|
24 |
-
|
25 |
-
|
26 |
-
|
27 |
-
|
28 |
-
|
29 |
-
|
30 |
-
|
31 |
-
|
32 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
33 |
|
34 |
Git & GitHub
|
35 |
------------
|
|
|
10 |
|
11 |
The following table summarizes the torch requirements for different operating systems and hardware configurations:
|
12 |
|
13 |
+
|
14 |
+
.. tabs::
|
15 |
+
|
16 |
+
.. tab:: Linux
|
17 |
+
|
18 |
+
.. tabs::
|
19 |
+
|
20 |
+
.. tab:: CUDA
|
21 |
+
|
22 |
+
PyTorch: 1.12+
|
23 |
+
|
24 |
+
.. tab:: CPU
|
25 |
+
|
26 |
+
PyTorch: 1.12+
|
27 |
+
|
28 |
+
.. tab:: MacOS
|
29 |
+
|
30 |
+
.. tabs::
|
31 |
+
|
32 |
+
.. tab:: MPS
|
33 |
+
|
34 |
+
PyTorch: 2.2+
|
35 |
+
.. tab:: CPU
|
36 |
+
PyTorch: 2.2+
|
37 |
+
.. tab:: Windows
|
38 |
+
|
39 |
+
.. tabs::
|
40 |
+
|
41 |
+
.. tab:: CUDA
|
42 |
+
|
43 |
+
[WIP]
|
44 |
+
|
45 |
+
.. tab:: CPU
|
46 |
+
|
47 |
+
[WIP]
|
48 |
+
|
49 |
|
50 |
Git & GitHub
|
51 |
------------
|