Release 8.0.5 PR (#279)
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: Glenn Jocher <glenn.jocher@ultralytics.com> Co-authored-by: Izam Mohammed <106471909+izam-mohammed@users.noreply.github.com> Co-authored-by: Yue WANG 王跃 <92371174+yuewangg@users.noreply.github.com> Co-authored-by: Thibaut Lucas <thibautlucas13@gmail.com>
This commit is contained in:
parent
9552827157
commit
c42e44a021
28 changed files with 940 additions and 311 deletions
63
docs/cli.md
63
docs/cli.md
|
|
@ -1,7 +1,8 @@
|
|||
## CLI Basics
|
||||
If you want to train, validate or run inference on models and don't need to make any modifications to the code, using YOLO command line interface is the easiest way to get started.
|
||||
If you want to train, validate or run inference on models and don't need to make any modifications to the code, using
|
||||
YOLO command line interface is the easiest way to get started.
|
||||
|
||||
!!! tip "Syntax"
|
||||
|
||||
```bash
|
||||
yolo task=detect mode=train model=yolov8n.yaml epochs=1 ...
|
||||
... ... ...
|
||||
|
|
@ -9,60 +10,76 @@ If you want to train, validate or run inference on models and don't need to make
|
|||
classify val yolov8n-cls.pt
|
||||
```
|
||||
|
||||
The experiment arguments can be overridden directly by pass `arg=val` covered in the next section. You can run any supported task by setting `task` and `mode` in cli.
|
||||
The experiment arguments can be overridden directly by pass `arg=val` covered in the next section. You can run any
|
||||
supported task by setting `task` and `mode` in cli.
|
||||
=== "Training"
|
||||
|
||||
| | `task` | snippet |
|
||||
| ----------- | ------------- | ----------------------------------------------------------- |
|
||||
| Detection | `detect` | <pre><code>yolo task=detect mode=train </code></pre> |
|
||||
| Instance Segment | `segment` | <pre><code>yolo task=segment mode=train </code></pre> |
|
||||
| Classification| `classify` | <pre><code>yolo task=classify mode=train </code></pre> |
|
||||
| | `task` | snippet |
|
||||
|------------------|------------|------------------------------------------------------------|
|
||||
| Detection | `detect` | <pre><code>yolo task=detect mode=train </code></pre> |
|
||||
| Instance Segment | `segment` | <pre><code>yolo task=segment mode=train </code></pre> |
|
||||
| Classification | `classify` | <pre><code>yolo task=classify mode=train </code></pre> |
|
||||
|
||||
=== "Prediction"
|
||||
|
||||
| | `task` | snippet |
|
||||
| ----------- | ------------- | ------------------------------------------------------------ |
|
||||
| Detection | `detect` | <pre><code>yolo task=detect mode=predict </code></pre> |
|
||||
| Instance Segment | `segment` | <pre><code>yolo task=segment mode=predict </code></pre>|
|
||||
| Classification| `classify` | <pre><code>yolo task=classify mode=predict </code></pre>|
|
||||
| | `task` | snippet |
|
||||
|------------------|------------|--------------------------------------------------------------|
|
||||
| Detection | `detect` | <pre><code>yolo task=detect mode=predict </code></pre> |
|
||||
| Instance Segment | `segment` | <pre><code>yolo task=segment mode=predict </code></pre> |
|
||||
| Classification | `classify` | <pre><code>yolo task=classify mode=predict </code></pre> |
|
||||
|
||||
=== "Validation"
|
||||
|
||||
| | `task` | snippet |
|
||||
| ----------- | ------------- | ------------------------------------------------------------- |
|
||||
| Detection | `detect` | <pre><code>yolo task=detect mode=val </code></pre> |
|
||||
| Instance Segment | `segment` | <pre><code>yolo task=segment mode=val </code></pre> |
|
||||
| Classification| `classify` | <pre><code>yolo task=classify mode=val </code></pre> |
|
||||
| | `task` | snippet |
|
||||
|------------------|------------|-----------------------------------------------------------|
|
||||
| Detection | `detect` | <pre><code>yolo task=detect mode=val </code></pre> |
|
||||
| Instance Segment | `segment` | <pre><code>yolo task=segment mode=val </code></pre> |
|
||||
| Classification | `classify` | <pre><code>yolo task=classify mode=val </code></pre> |
|
||||
|
||||
!!! note ""
|
||||
|
||||
<b>Note:</b> The arguments don't require `'--'` prefix. These are reserved for special commands covered later
|
||||
|
||||
---
|
||||
|
||||
## Overriding default config arguments
|
||||
|
||||
All global default arguments can be overriden by simply passing them as arguments in the cli.
|
||||
|
||||
!!! tip ""
|
||||
|
||||
=== "Syntax"
|
||||
```yolo task= ... mode= ... {++ arg=val ++}```
|
||||
```bash
|
||||
yolo task= ... mode= ... {++ arg=val ++}
|
||||
```
|
||||
|
||||
=== "Example"
|
||||
Perform detection training for `10 epochs` with `learning_rate` of `0.01`
|
||||
```
|
||||
```bash
|
||||
yolo task=detect mode=train {++ epochs=10 lr0=0.01 ++}
|
||||
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## Overriding default config file
|
||||
You can override config file entirely by passing a new file. You can create a copy of default config file in your current working dir as follows:
|
||||
|
||||
You can override config file entirely by passing a new file. You can create a copy of default config file in your
|
||||
current working dir as follows:
|
||||
|
||||
```bash
|
||||
yolo task=init
|
||||
```
|
||||
|
||||
You can then use `cfg=name.yaml` command to pass the new config file
|
||||
|
||||
```bash
|
||||
yolo cfg=default.yaml
|
||||
```
|
||||
|
||||
??? example
|
||||
|
||||
=== "Command"
|
||||
```
|
||||
```bash
|
||||
yolo task=init
|
||||
yolo cfg=default.yaml
|
||||
```
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue