Add files using upload-large-folder tool
Browse filesThis view is limited to 50 files because it contains too many changes. See raw diff
- datasets/coco128/LICENSE +674 -0
- datasets/coco128/README.txt +22 -0
- datasets/coco128/labels/train2017.cache +0 -0
- datasets/coco128/labels/train2017/000000000009.txt +8 -0
- datasets/coco128/labels/train2017/000000000144.txt +3 -0
- datasets/coco128/labels/train2017/000000000149.txt +22 -0
- datasets/coco128/labels/train2017/000000000164.txt +40 -0
- datasets/coco128/labels/train2017/000000000263.txt +2 -0
- datasets/coco128/labels/train2017/000000000338.txt +6 -0
- datasets/coco128/labels/train2017/000000000349.txt +4 -0
- datasets/coco128/labels/train2017/000000000357.txt +17 -0
- datasets/coco128/labels/train2017/000000000359.txt +4 -0
- datasets/coco128/labels/train2017/000000000387.txt +3 -0
- datasets/coco128/labels/train2017/000000000394.txt +2 -0
- datasets/coco128/labels/train2017/000000000395.txt +13 -0
- datasets/coco128/labels/train2017/000000000404.txt +5 -0
- datasets/coco128/labels/train2017/000000000443.txt +6 -0
- datasets/coco128/labels/train2017/000000000486.txt +8 -0
- datasets/coco128/labels/train2017/000000000491.txt +4 -0
- datasets/coco128/labels/train2017/000000000531.txt +15 -0
- datasets/coco128/labels/train2017/000000000532.txt +8 -0
- datasets/coco128/labels/train2017/000000000569.txt +5 -0
- datasets/coco128/labels/train2017/000000000659.txt +9 -0
- ultralytics/docker/Dockerfile +89 -0
- ultralytics/docker/Dockerfile-arm64 +54 -0
- ultralytics/docker/Dockerfile-conda +46 -0
- ultralytics/docker/Dockerfile-cpu +60 -0
- ultralytics/docker/Dockerfile-jetson-jetpack4 +65 -0
- ultralytics/docker/Dockerfile-jetson-jetpack5 +59 -0
- ultralytics/docker/Dockerfile-jetson-jetpack6 +55 -0
- ultralytics/docker/Dockerfile-python +57 -0
- ultralytics/docker/Dockerfile-runner +45 -0
- ultralytics/docs/en/datasets/detect/argoverse.md +153 -0
- ultralytics/docs/en/datasets/detect/coco.md +177 -0
- ultralytics/docs/en/datasets/detect/coco8.md +135 -0
- ultralytics/docs/en/datasets/detect/globalwheat2020.md +145 -0
- ultralytics/docs/en/datasets/detect/index.md +188 -0
- ultralytics/docs/en/datasets/detect/lvis.md +159 -0
- ultralytics/docs/en/datasets/detect/objects365.md +141 -0
- ultralytics/docs/en/datasets/detect/open-images-v7.md +200 -0
- ultralytics/docs/en/datasets/detect/roboflow-100.md +218 -0
- ultralytics/docs/en/datasets/detect/signature.md +170 -0
- ultralytics/docs/en/datasets/detect/sku-110k.md +181 -0
- ultralytics/docs/en/datasets/detect/visdrone.md +179 -0
- ultralytics/docs/en/datasets/detect/xview.md +165 -0
- ultralytics/docs/en/integrations/amazon-sagemaker.md +256 -0
- ultralytics/docs/en/integrations/clearml.md +246 -0
- ultralytics/docs/en/integrations/comet.md +286 -0
- ultralytics/docs/en/integrations/coreml.md +218 -0
- ultralytics/docs/en/integrations/dvc.md +278 -0
datasets/coco128/LICENSE
ADDED
|
@@ -0,0 +1,674 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
GNU GENERAL PUBLIC LICENSE
|
| 2 |
+
Version 3, 29 June 2007
|
| 3 |
+
|
| 4 |
+
Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/>
|
| 5 |
+
Everyone is permitted to copy and distribute verbatim copies
|
| 6 |
+
of this license document, but changing it is not allowed.
|
| 7 |
+
|
| 8 |
+
Preamble
|
| 9 |
+
|
| 10 |
+
The GNU General Public License is a free, copyleft license for
|
| 11 |
+
software and other kinds of works.
|
| 12 |
+
|
| 13 |
+
The licenses for most software and other practical works are designed
|
| 14 |
+
to take away your freedom to share and change the works. By contrast,
|
| 15 |
+
the GNU General Public License is intended to guarantee your freedom to
|
| 16 |
+
share and change all versions of a program--to make sure it remains free
|
| 17 |
+
software for all its users. We, the Free Software Foundation, use the
|
| 18 |
+
GNU General Public License for most of our software; it applies also to
|
| 19 |
+
any other work released this way by its authors. You can apply it to
|
| 20 |
+
your programs, too.
|
| 21 |
+
|
| 22 |
+
When we speak of free software, we are referring to freedom, not
|
| 23 |
+
price. Our General Public Licenses are designed to make sure that you
|
| 24 |
+
have the freedom to distribute copies of free software (and charge for
|
| 25 |
+
them if you wish), that you receive source code or can get it if you
|
| 26 |
+
want it, that you can change the software or use pieces of it in new
|
| 27 |
+
free programs, and that you know you can do these things.
|
| 28 |
+
|
| 29 |
+
To protect your rights, we need to prevent others from denying you
|
| 30 |
+
these rights or asking you to surrender the rights. Therefore, you have
|
| 31 |
+
certain responsibilities if you distribute copies of the software, or if
|
| 32 |
+
you modify it: responsibilities to respect the freedom of others.
|
| 33 |
+
|
| 34 |
+
For example, if you distribute copies of such a program, whether
|
| 35 |
+
gratis or for a fee, you must pass on to the recipients the same
|
| 36 |
+
freedoms that you received. You must make sure that they, too, receive
|
| 37 |
+
or can get the source code. And you must show them these terms so they
|
| 38 |
+
know their rights.
|
| 39 |
+
|
| 40 |
+
Developers that use the GNU GPL protect your rights with two steps:
|
| 41 |
+
(1) assert copyright on the software, and (2) offer you this License
|
| 42 |
+
giving you legal permission to copy, distribute and/or modify it.
|
| 43 |
+
|
| 44 |
+
For the developers' and authors' protection, the GPL clearly explains
|
| 45 |
+
that there is no warranty for this free software. For both users' and
|
| 46 |
+
authors' sake, the GPL requires that modified versions be marked as
|
| 47 |
+
changed, so that their problems will not be attributed erroneously to
|
| 48 |
+
authors of previous versions.
|
| 49 |
+
|
| 50 |
+
Some devices are designed to deny users access to install or run
|
| 51 |
+
modified versions of the software inside them, although the manufacturer
|
| 52 |
+
can do so. This is fundamentally incompatible with the aim of
|
| 53 |
+
protecting users' freedom to change the software. The systematic
|
| 54 |
+
pattern of such abuse occurs in the area of products for individuals to
|
| 55 |
+
use, which is precisely where it is most unacceptable. Therefore, we
|
| 56 |
+
have designed this version of the GPL to prohibit the practice for those
|
| 57 |
+
products. If such problems arise substantially in other domains, we
|
| 58 |
+
stand ready to extend this provision to those domains in future versions
|
| 59 |
+
of the GPL, as needed to protect the freedom of users.
|
| 60 |
+
|
| 61 |
+
Finally, every program is threatened constantly by software patents.
|
| 62 |
+
States should not allow patents to restrict development and use of
|
| 63 |
+
software on general-purpose computers, but in those that do, we wish to
|
| 64 |
+
avoid the special danger that patents applied to a free program could
|
| 65 |
+
make it effectively proprietary. To prevent this, the GPL assures that
|
| 66 |
+
patents cannot be used to render the program non-free.
|
| 67 |
+
|
| 68 |
+
The precise terms and conditions for copying, distribution and
|
| 69 |
+
modification follow.
|
| 70 |
+
|
| 71 |
+
TERMS AND CONDITIONS
|
| 72 |
+
|
| 73 |
+
0. Definitions.
|
| 74 |
+
|
| 75 |
+
"This License" refers to version 3 of the GNU General Public License.
|
| 76 |
+
|
| 77 |
+
"Copyright" also means copyright-like laws that apply to other kinds of
|
| 78 |
+
works, such as semiconductor masks.
|
| 79 |
+
|
| 80 |
+
"The Program" refers to any copyrightable work licensed under this
|
| 81 |
+
License. Each licensee is addressed as "you". "Licensees" and
|
| 82 |
+
"recipients" may be individuals or organizations.
|
| 83 |
+
|
| 84 |
+
To "modify" a work means to copy from or adapt all or part of the work
|
| 85 |
+
in a fashion requiring copyright permission, other than the making of an
|
| 86 |
+
exact copy. The resulting work is called a "modified version" of the
|
| 87 |
+
earlier work or a work "based on" the earlier work.
|
| 88 |
+
|
| 89 |
+
A "covered work" means either the unmodified Program or a work based
|
| 90 |
+
on the Program.
|
| 91 |
+
|
| 92 |
+
To "propagate" a work means to do anything with it that, without
|
| 93 |
+
permission, would make you directly or secondarily liable for
|
| 94 |
+
infringement under applicable copyright law, except executing it on a
|
| 95 |
+
computer or modifying a private copy. Propagation includes copying,
|
| 96 |
+
distribution (with or without modification), making available to the
|
| 97 |
+
public, and in some countries other activities as well.
|
| 98 |
+
|
| 99 |
+
To "convey" a work means any kind of propagation that enables other
|
| 100 |
+
parties to make or receive copies. Mere interaction with a user through
|
| 101 |
+
a computer network, with no transfer of a copy, is not conveying.
|
| 102 |
+
|
| 103 |
+
An interactive user interface displays "Appropriate Legal Notices"
|
| 104 |
+
to the extent that it includes a convenient and prominently visible
|
| 105 |
+
feature that (1) displays an appropriate copyright notice, and (2)
|
| 106 |
+
tells the user that there is no warranty for the work (except to the
|
| 107 |
+
extent that warranties are provided), that licensees may convey the
|
| 108 |
+
work under this License, and how to view a copy of this License. If
|
| 109 |
+
the interface presents a list of user commands or options, such as a
|
| 110 |
+
menu, a prominent item in the list meets this criterion.
|
| 111 |
+
|
| 112 |
+
1. Source Code.
|
| 113 |
+
|
| 114 |
+
The "source code" for a work means the preferred form of the work
|
| 115 |
+
for making modifications to it. "Object code" means any non-source
|
| 116 |
+
form of a work.
|
| 117 |
+
|
| 118 |
+
A "Standard Interface" means an interface that either is an official
|
| 119 |
+
standard defined by a recognized standards body, or, in the case of
|
| 120 |
+
interfaces specified for a particular programming language, one that
|
| 121 |
+
is widely used among developers working in that language.
|
| 122 |
+
|
| 123 |
+
The "System Libraries" of an executable work include anything, other
|
| 124 |
+
than the work as a whole, that (a) is included in the normal form of
|
| 125 |
+
packaging a Major Component, but which is not part of that Major
|
| 126 |
+
Component, and (b) serves only to enable use of the work with that
|
| 127 |
+
Major Component, or to implement a Standard Interface for which an
|
| 128 |
+
implementation is available to the public in source code form. A
|
| 129 |
+
"Major Component", in this context, means a major essential component
|
| 130 |
+
(kernel, window system, and so on) of the specific operating system
|
| 131 |
+
(if any) on which the executable work runs, or a compiler used to
|
| 132 |
+
produce the work, or an object code interpreter used to run it.
|
| 133 |
+
|
| 134 |
+
The "Corresponding Source" for a work in object code form means all
|
| 135 |
+
the source code needed to generate, install, and (for an executable
|
| 136 |
+
work) run the object code and to modify the work, including scripts to
|
| 137 |
+
control those activities. However, it does not include the work's
|
| 138 |
+
System Libraries, or general-purpose tools or generally available free
|
| 139 |
+
programs which are used unmodified in performing those activities but
|
| 140 |
+
which are not part of the work. For example, Corresponding Source
|
| 141 |
+
includes interface definition files associated with source files for
|
| 142 |
+
the work, and the source code for shared libraries and dynamically
|
| 143 |
+
linked subprograms that the work is specifically designed to require,
|
| 144 |
+
such as by intimate data communication or control flow between those
|
| 145 |
+
subprograms and other parts of the work.
|
| 146 |
+
|
| 147 |
+
The Corresponding Source need not include anything that users
|
| 148 |
+
can regenerate automatically from other parts of the Corresponding
|
| 149 |
+
Source.
|
| 150 |
+
|
| 151 |
+
The Corresponding Source for a work in source code form is that
|
| 152 |
+
same work.
|
| 153 |
+
|
| 154 |
+
2. Basic Permissions.
|
| 155 |
+
|
| 156 |
+
All rights granted under this License are granted for the term of
|
| 157 |
+
copyright on the Program, and are irrevocable provided the stated
|
| 158 |
+
conditions are met. This License explicitly affirms your unlimited
|
| 159 |
+
permission to run the unmodified Program. The output from running a
|
| 160 |
+
covered work is covered by this License only if the output, given its
|
| 161 |
+
content, constitutes a covered work. This License acknowledges your
|
| 162 |
+
rights of fair use or other equivalent, as provided by copyright law.
|
| 163 |
+
|
| 164 |
+
You may make, run and propagate covered works that you do not
|
| 165 |
+
convey, without conditions so long as your license otherwise remains
|
| 166 |
+
in force. You may convey covered works to others for the sole purpose
|
| 167 |
+
of having them make modifications exclusively for you, or provide you
|
| 168 |
+
with facilities for running those works, provided that you comply with
|
| 169 |
+
the terms of this License in conveying all material for which you do
|
| 170 |
+
not control copyright. Those thus making or running the covered works
|
| 171 |
+
for you must do so exclusively on your behalf, under your direction
|
| 172 |
+
and control, on terms that prohibit them from making any copies of
|
| 173 |
+
your copyrighted material outside their relationship with you.
|
| 174 |
+
|
| 175 |
+
Conveying under any other circumstances is permitted solely under
|
| 176 |
+
the conditions stated below. Sublicensing is not allowed; section 10
|
| 177 |
+
makes it unnecessary.
|
| 178 |
+
|
| 179 |
+
3. Protecting Users' Legal Rights From Anti-Circumvention Law.
|
| 180 |
+
|
| 181 |
+
No covered work shall be deemed part of an effective technological
|
| 182 |
+
measure under any applicable law fulfilling obligations under article
|
| 183 |
+
11 of the WIPO copyright treaty adopted on 20 December 1996, or
|
| 184 |
+
similar laws prohibiting or restricting circumvention of such
|
| 185 |
+
measures.
|
| 186 |
+
|
| 187 |
+
When you convey a covered work, you waive any legal power to forbid
|
| 188 |
+
circumvention of technological measures to the extent such circumvention
|
| 189 |
+
is effected by exercising rights under this License with respect to
|
| 190 |
+
the covered work, and you disclaim any intention to limit operation or
|
| 191 |
+
modification of the work as a means of enforcing, against the work's
|
| 192 |
+
users, your or third parties' legal rights to forbid circumvention of
|
| 193 |
+
technological measures.
|
| 194 |
+
|
| 195 |
+
4. Conveying Verbatim Copies.
|
| 196 |
+
|
| 197 |
+
You may convey verbatim copies of the Program's source code as you
|
| 198 |
+
receive it, in any medium, provided that you conspicuously and
|
| 199 |
+
appropriately publish on each copy an appropriate copyright notice;
|
| 200 |
+
keep intact all notices stating that this License and any
|
| 201 |
+
non-permissive terms added in accord with section 7 apply to the code;
|
| 202 |
+
keep intact all notices of the absence of any warranty; and give all
|
| 203 |
+
recipients a copy of this License along with the Program.
|
| 204 |
+
|
| 205 |
+
You may charge any price or no price for each copy that you convey,
|
| 206 |
+
and you may offer support or warranty protection for a fee.
|
| 207 |
+
|
| 208 |
+
5. Conveying Modified Source Versions.
|
| 209 |
+
|
| 210 |
+
You may convey a work based on the Program, or the modifications to
|
| 211 |
+
produce it from the Program, in the form of source code under the
|
| 212 |
+
terms of section 4, provided that you also meet all of these conditions:
|
| 213 |
+
|
| 214 |
+
a) The work must carry prominent notices stating that you modified
|
| 215 |
+
it, and giving a relevant date.
|
| 216 |
+
|
| 217 |
+
b) The work must carry prominent notices stating that it is
|
| 218 |
+
released under this License and any conditions added under section
|
| 219 |
+
7. This requirement modifies the requirement in section 4 to
|
| 220 |
+
"keep intact all notices".
|
| 221 |
+
|
| 222 |
+
c) You must license the entire work, as a whole, under this
|
| 223 |
+
License to anyone who comes into possession of a copy. This
|
| 224 |
+
License will therefore apply, along with any applicable section 7
|
| 225 |
+
additional terms, to the whole of the work, and all its parts,
|
| 226 |
+
regardless of how they are packaged. This License gives no
|
| 227 |
+
permission to license the work in any other way, but it does not
|
| 228 |
+
invalidate such permission if you have separately received it.
|
| 229 |
+
|
| 230 |
+
d) If the work has interactive user interfaces, each must display
|
| 231 |
+
Appropriate Legal Notices; however, if the Program has interactive
|
| 232 |
+
interfaces that do not display Appropriate Legal Notices, your
|
| 233 |
+
work need not make them do so.
|
| 234 |
+
|
| 235 |
+
A compilation of a covered work with other separate and independent
|
| 236 |
+
works, which are not by their nature extensions of the covered work,
|
| 237 |
+
and which are not combined with it such as to form a larger program,
|
| 238 |
+
in or on a volume of a storage or distribution medium, is called an
|
| 239 |
+
"aggregate" if the compilation and its resulting copyright are not
|
| 240 |
+
used to limit the access or legal rights of the compilation's users
|
| 241 |
+
beyond what the individual works permit. Inclusion of a covered work
|
| 242 |
+
in an aggregate does not cause this License to apply to the other
|
| 243 |
+
parts of the aggregate.
|
| 244 |
+
|
| 245 |
+
6. Conveying Non-Source Forms.
|
| 246 |
+
|
| 247 |
+
You may convey a covered work in object code form under the terms
|
| 248 |
+
of sections 4 and 5, provided that you also convey the
|
| 249 |
+
machine-readable Corresponding Source under the terms of this License,
|
| 250 |
+
in one of these ways:
|
| 251 |
+
|
| 252 |
+
a) Convey the object code in, or embodied in, a physical product
|
| 253 |
+
(including a physical distribution medium), accompanied by the
|
| 254 |
+
Corresponding Source fixed on a durable physical medium
|
| 255 |
+
customarily used for software interchange.
|
| 256 |
+
|
| 257 |
+
b) Convey the object code in, or embodied in, a physical product
|
| 258 |
+
(including a physical distribution medium), accompanied by a
|
| 259 |
+
written offer, valid for at least three years and valid for as
|
| 260 |
+
long as you offer spare parts or customer support for that product
|
| 261 |
+
model, to give anyone who possesses the object code either (1) a
|
| 262 |
+
copy of the Corresponding Source for all the software in the
|
| 263 |
+
product that is covered by this License, on a durable physical
|
| 264 |
+
medium customarily used for software interchange, for a price no
|
| 265 |
+
more than your reasonable cost of physically performing this
|
| 266 |
+
conveying of source, or (2) access to copy the
|
| 267 |
+
Corresponding Source from a network server at no charge.
|
| 268 |
+
|
| 269 |
+
c) Convey individual copies of the object code with a copy of the
|
| 270 |
+
written offer to provide the Corresponding Source. This
|
| 271 |
+
alternative is allowed only occasionally and noncommercially, and
|
| 272 |
+
only if you received the object code with such an offer, in accord
|
| 273 |
+
with subsection 6b.
|
| 274 |
+
|
| 275 |
+
d) Convey the object code by offering access from a designated
|
| 276 |
+
place (gratis or for a charge), and offer equivalent access to the
|
| 277 |
+
Corresponding Source in the same way through the same place at no
|
| 278 |
+
further charge. You need not require recipients to copy the
|
| 279 |
+
Corresponding Source along with the object code. If the place to
|
| 280 |
+
copy the object code is a network server, the Corresponding Source
|
| 281 |
+
may be on a different server (operated by you or a third party)
|
| 282 |
+
that supports equivalent copying facilities, provided you maintain
|
| 283 |
+
clear directions next to the object code saying where to find the
|
| 284 |
+
Corresponding Source. Regardless of what server hosts the
|
| 285 |
+
Corresponding Source, you remain obligated to ensure that it is
|
| 286 |
+
available for as long as needed to satisfy these requirements.
|
| 287 |
+
|
| 288 |
+
e) Convey the object code using peer-to-peer transmission, provided
|
| 289 |
+
you inform other peers where the object code and Corresponding
|
| 290 |
+
Source of the work are being offered to the general public at no
|
| 291 |
+
charge under subsection 6d.
|
| 292 |
+
|
| 293 |
+
A separable portion of the object code, whose source code is excluded
|
| 294 |
+
from the Corresponding Source as a System Library, need not be
|
| 295 |
+
included in conveying the object code work.
|
| 296 |
+
|
| 297 |
+
A "User Product" is either (1) a "consumer product", which means any
|
| 298 |
+
tangible personal property which is normally used for personal, family,
|
| 299 |
+
or household purposes, or (2) anything designed or sold for incorporation
|
| 300 |
+
into a dwelling. In determining whether a product is a consumer product,
|
| 301 |
+
doubtful cases shall be resolved in favor of coverage. For a particular
|
| 302 |
+
product received by a particular user, "normally used" refers to a
|
| 303 |
+
typical or common use of that class of product, regardless of the status
|
| 304 |
+
of the particular user or of the way in which the particular user
|
| 305 |
+
actually uses, or expects or is expected to use, the product. A product
|
| 306 |
+
is a consumer product regardless of whether the product has substantial
|
| 307 |
+
commercial, industrial or non-consumer uses, unless such uses represent
|
| 308 |
+
the only significant mode of use of the product.
|
| 309 |
+
|
| 310 |
+
"Installation Information" for a User Product means any methods,
|
| 311 |
+
procedures, authorization keys, or other information required to install
|
| 312 |
+
and execute modified versions of a covered work in that User Product from
|
| 313 |
+
a modified version of its Corresponding Source. The information must
|
| 314 |
+
suffice to ensure that the continued functioning of the modified object
|
| 315 |
+
code is in no case prevented or interfered with solely because
|
| 316 |
+
modification has been made.
|
| 317 |
+
|
| 318 |
+
If you convey an object code work under this section in, or with, or
|
| 319 |
+
specifically for use in, a User Product, and the conveying occurs as
|
| 320 |
+
part of a transaction in which the right of possession and use of the
|
| 321 |
+
User Product is transferred to the recipient in perpetuity or for a
|
| 322 |
+
fixed term (regardless of how the transaction is characterized), the
|
| 323 |
+
Corresponding Source conveyed under this section must be accompanied
|
| 324 |
+
by the Installation Information. But this requirement does not apply
|
| 325 |
+
if neither you nor any third party retains the ability to install
|
| 326 |
+
modified object code on the User Product (for example, the work has
|
| 327 |
+
been installed in ROM).
|
| 328 |
+
|
| 329 |
+
The requirement to provide Installation Information does not include a
|
| 330 |
+
requirement to continue to provide support service, warranty, or updates
|
| 331 |
+
for a work that has been modified or installed by the recipient, or for
|
| 332 |
+
the User Product in which it has been modified or installed. Access to a
|
| 333 |
+
network may be denied when the modification itself materially and
|
| 334 |
+
adversely affects the operation of the network or violates the rules and
|
| 335 |
+
protocols for communication across the network.
|
| 336 |
+
|
| 337 |
+
Corresponding Source conveyed, and Installation Information provided,
|
| 338 |
+
in accord with this section must be in a format that is publicly
|
| 339 |
+
documented (and with an implementation available to the public in
|
| 340 |
+
source code form), and must require no special password or key for
|
| 341 |
+
unpacking, reading or copying.
|
| 342 |
+
|
| 343 |
+
7. Additional Terms.
|
| 344 |
+
|
| 345 |
+
"Additional permissions" are terms that supplement the terms of this
|
| 346 |
+
License by making exceptions from one or more of its conditions.
|
| 347 |
+
Additional permissions that are applicable to the entire Program shall
|
| 348 |
+
be treated as though they were included in this License, to the extent
|
| 349 |
+
that they are valid under applicable law. If additional permissions
|
| 350 |
+
apply only to part of the Program, that part may be used separately
|
| 351 |
+
under those permissions, but the entire Program remains governed by
|
| 352 |
+
this License without regard to the additional permissions.
|
| 353 |
+
|
| 354 |
+
When you convey a copy of a covered work, you may at your option
|
| 355 |
+
remove any additional permissions from that copy, or from any part of
|
| 356 |
+
it. (Additional permissions may be written to require their own
|
| 357 |
+
removal in certain cases when you modify the work.) You may place
|
| 358 |
+
additional permissions on material, added by you to a covered work,
|
| 359 |
+
for which you have or can give appropriate copyright permission.
|
| 360 |
+
|
| 361 |
+
Notwithstanding any other provision of this License, for material you
|
| 362 |
+
add to a covered work, you may (if authorized by the copyright holders of
|
| 363 |
+
that material) supplement the terms of this License with terms:
|
| 364 |
+
|
| 365 |
+
a) Disclaiming warranty or limiting liability differently from the
|
| 366 |
+
terms of sections 15 and 16 of this License; or
|
| 367 |
+
|
| 368 |
+
b) Requiring preservation of specified reasonable legal notices or
|
| 369 |
+
author attributions in that material or in the Appropriate Legal
|
| 370 |
+
Notices displayed by works containing it; or
|
| 371 |
+
|
| 372 |
+
c) Prohibiting misrepresentation of the origin of that material, or
|
| 373 |
+
requiring that modified versions of such material be marked in
|
| 374 |
+
reasonable ways as different from the original version; or
|
| 375 |
+
|
| 376 |
+
d) Limiting the use for publicity purposes of names of licensors or
|
| 377 |
+
authors of the material; or
|
| 378 |
+
|
| 379 |
+
e) Declining to grant rights under trademark law for use of some
|
| 380 |
+
trade names, trademarks, or service marks; or
|
| 381 |
+
|
| 382 |
+
f) Requiring indemnification of licensors and authors of that
|
| 383 |
+
material by anyone who conveys the material (or modified versions of
|
| 384 |
+
it) with contractual assumptions of liability to the recipient, for
|
| 385 |
+
any liability that these contractual assumptions directly impose on
|
| 386 |
+
those licensors and authors.
|
| 387 |
+
|
| 388 |
+
All other non-permissive additional terms are considered "further
|
| 389 |
+
restrictions" within the meaning of section 10. If the Program as you
|
| 390 |
+
received it, or any part of it, contains a notice stating that it is
|
| 391 |
+
governed by this License along with a term that is a further
|
| 392 |
+
restriction, you may remove that term. If a license document contains
|
| 393 |
+
a further restriction but permits relicensing or conveying under this
|
| 394 |
+
License, you may add to a covered work material governed by the terms
|
| 395 |
+
of that license document, provided that the further restriction does
|
| 396 |
+
not survive such relicensing or conveying.
|
| 397 |
+
|
| 398 |
+
If you add terms to a covered work in accord with this section, you
|
| 399 |
+
must place, in the relevant source files, a statement of the
|
| 400 |
+
additional terms that apply to those files, or a notice indicating
|
| 401 |
+
where to find the applicable terms.
|
| 402 |
+
|
| 403 |
+
Additional terms, permissive or non-permissive, may be stated in the
|
| 404 |
+
form of a separately written license, or stated as exceptions;
|
| 405 |
+
the above requirements apply either way.
|
| 406 |
+
|
| 407 |
+
8. Termination.
|
| 408 |
+
|
| 409 |
+
You may not propagate or modify a covered work except as expressly
|
| 410 |
+
provided under this License. Any attempt otherwise to propagate or
|
| 411 |
+
modify it is void, and will automatically terminate your rights under
|
| 412 |
+
this License (including any patent licenses granted under the third
|
| 413 |
+
paragraph of section 11).
|
| 414 |
+
|
| 415 |
+
However, if you cease all violation of this License, then your
|
| 416 |
+
license from a particular copyright holder is reinstated (a)
|
| 417 |
+
provisionally, unless and until the copyright holder explicitly and
|
| 418 |
+
finally terminates your license, and (b) permanently, if the copyright
|
| 419 |
+
holder fails to notify you of the violation by some reasonable means
|
| 420 |
+
prior to 60 days after the cessation.
|
| 421 |
+
|
| 422 |
+
Moreover, your license from a particular copyright holder is
|
| 423 |
+
reinstated permanently if the copyright holder notifies you of the
|
| 424 |
+
violation by some reasonable means, this is the first time you have
|
| 425 |
+
received notice of violation of this License (for any work) from that
|
| 426 |
+
copyright holder, and you cure the violation prior to 30 days after
|
| 427 |
+
your receipt of the notice.
|
| 428 |
+
|
| 429 |
+
Termination of your rights under this section does not terminate the
|
| 430 |
+
licenses of parties who have received copies or rights from you under
|
| 431 |
+
this License. If your rights have been terminated and not permanently
|
| 432 |
+
reinstated, you do not qualify to receive new licenses for the same
|
| 433 |
+
material under section 10.
|
| 434 |
+
|
| 435 |
+
9. Acceptance Not Required for Having Copies.
|
| 436 |
+
|
| 437 |
+
You are not required to accept this License in order to receive or
|
| 438 |
+
run a copy of the Program. Ancillary propagation of a covered work
|
| 439 |
+
occurring solely as a consequence of using peer-to-peer transmission
|
| 440 |
+
to receive a copy likewise does not require acceptance. However,
|
| 441 |
+
nothing other than this License grants you permission to propagate or
|
| 442 |
+
modify any covered work. These actions infringe copyright if you do
|
| 443 |
+
not accept this License. Therefore, by modifying or propagating a
|
| 444 |
+
covered work, you indicate your acceptance of this License to do so.
|
| 445 |
+
|
| 446 |
+
10. Automatic Licensing of Downstream Recipients.
|
| 447 |
+
|
| 448 |
+
Each time you convey a covered work, the recipient automatically
|
| 449 |
+
receives a license from the original licensors, to run, modify and
|
| 450 |
+
propagate that work, subject to this License. You are not responsible
|
| 451 |
+
for enforcing compliance by third parties with this License.
|
| 452 |
+
|
| 453 |
+
An "entity transaction" is a transaction transferring control of an
|
| 454 |
+
organization, or substantially all assets of one, or subdividing an
|
| 455 |
+
organization, or merging organizations. If propagation of a covered
|
| 456 |
+
work results from an entity transaction, each party to that
|
| 457 |
+
transaction who receives a copy of the work also receives whatever
|
| 458 |
+
licenses to the work the party's predecessor in interest had or could
|
| 459 |
+
give under the previous paragraph, plus a right to possession of the
|
| 460 |
+
Corresponding Source of the work from the predecessor in interest, if
|
| 461 |
+
the predecessor has it or can get it with reasonable efforts.
|
| 462 |
+
|
| 463 |
+
You may not impose any further restrictions on the exercise of the
|
| 464 |
+
rights granted or affirmed under this License. For example, you may
|
| 465 |
+
not impose a license fee, royalty, or other charge for exercise of
|
| 466 |
+
rights granted under this License, and you may not initiate litigation
|
| 467 |
+
(including a cross-claim or counterclaim in a lawsuit) alleging that
|
| 468 |
+
any patent claim is infringed by making, using, selling, offering for
|
| 469 |
+
sale, or importing the Program or any portion of it.
|
| 470 |
+
|
| 471 |
+
11. Patents.
|
| 472 |
+
|
| 473 |
+
A "contributor" is a copyright holder who authorizes use under this
|
| 474 |
+
License of the Program or a work on which the Program is based. The
|
| 475 |
+
work thus licensed is called the contributor's "contributor version".
|
| 476 |
+
|
| 477 |
+
A contributor's "essential patent claims" are all patent claims
|
| 478 |
+
owned or controlled by the contributor, whether already acquired or
|
| 479 |
+
hereafter acquired, that would be infringed by some manner, permitted
|
| 480 |
+
by this License, of making, using, or selling its contributor version,
|
| 481 |
+
but do not include claims that would be infringed only as a
|
| 482 |
+
consequence of further modification of the contributor version. For
|
| 483 |
+
purposes of this definition, "control" includes the right to grant
|
| 484 |
+
patent sublicenses in a manner consistent with the requirements of
|
| 485 |
+
this License.
|
| 486 |
+
|
| 487 |
+
Each contributor grants you a non-exclusive, worldwide, royalty-free
|
| 488 |
+
patent license under the contributor's essential patent claims, to
|
| 489 |
+
make, use, sell, offer for sale, import and otherwise run, modify and
|
| 490 |
+
propagate the contents of its contributor version.
|
| 491 |
+
|
| 492 |
+
In the following three paragraphs, a "patent license" is any express
|
| 493 |
+
agreement or commitment, however denominated, not to enforce a patent
|
| 494 |
+
(such as an express permission to practice a patent or covenant not to
|
| 495 |
+
sue for patent infringement). To "grant" such a patent license to a
|
| 496 |
+
party means to make such an agreement or commitment not to enforce a
|
| 497 |
+
patent against the party.
|
| 498 |
+
|
| 499 |
+
If you convey a covered work, knowingly relying on a patent license,
|
| 500 |
+
and the Corresponding Source of the work is not available for anyone
|
| 501 |
+
to copy, free of charge and under the terms of this License, through a
|
| 502 |
+
publicly available network server or other readily accessible means,
|
| 503 |
+
then you must either (1) cause the Corresponding Source to be so
|
| 504 |
+
available, or (2) arrange to deprive yourself of the benefit of the
|
| 505 |
+
patent license for this particular work, or (3) arrange, in a manner
|
| 506 |
+
consistent with the requirements of this License, to extend the patent
|
| 507 |
+
license to downstream recipients. "Knowingly relying" means you have
|
| 508 |
+
actual knowledge that, but for the patent license, your conveying the
|
| 509 |
+
covered work in a country, or your recipient's use of the covered work
|
| 510 |
+
in a country, would infringe one or more identifiable patents in that
|
| 511 |
+
country that you have reason to believe are valid.
|
| 512 |
+
|
| 513 |
+
If, pursuant to or in connection with a single transaction or
|
| 514 |
+
arrangement, you convey, or propagate by procuring conveyance of, a
|
| 515 |
+
covered work, and grant a patent license to some of the parties
|
| 516 |
+
receiving the covered work authorizing them to use, propagate, modify
|
| 517 |
+
or convey a specific copy of the covered work, then the patent license
|
| 518 |
+
you grant is automatically extended to all recipients of the covered
|
| 519 |
+
work and works based on it.
|
| 520 |
+
|
| 521 |
+
A patent license is "discriminatory" if it does not include within
|
| 522 |
+
the scope of its coverage, prohibits the exercise of, or is
|
| 523 |
+
conditioned on the non-exercise of one or more of the rights that are
|
| 524 |
+
specifically granted under this License. You may not convey a covered
|
| 525 |
+
work if you are a party to an arrangement with a third party that is
|
| 526 |
+
in the business of distributing software, under which you make payment
|
| 527 |
+
to the third party based on the extent of your activity of conveying
|
| 528 |
+
the work, and under which the third party grants, to any of the
|
| 529 |
+
parties who would receive the covered work from you, a discriminatory
|
| 530 |
+
patent license (a) in connection with copies of the covered work
|
| 531 |
+
conveyed by you (or copies made from those copies), or (b) primarily
|
| 532 |
+
for and in connection with specific products or compilations that
|
| 533 |
+
contain the covered work, unless you entered into that arrangement,
|
| 534 |
+
or that patent license was granted, prior to 28 March 2007.
|
| 535 |
+
|
| 536 |
+
Nothing in this License shall be construed as excluding or limiting
|
| 537 |
+
any implied license or other defenses to infringement that may
|
| 538 |
+
otherwise be available to you under applicable patent law.
|
| 539 |
+
|
| 540 |
+
12. No Surrender of Others' Freedom.
|
| 541 |
+
|
| 542 |
+
If conditions are imposed on you (whether by court order, agreement or
|
| 543 |
+
otherwise) that contradict the conditions of this License, they do not
|
| 544 |
+
excuse you from the conditions of this License. If you cannot convey a
|
| 545 |
+
covered work so as to satisfy simultaneously your obligations under this
|
| 546 |
+
License and any other pertinent obligations, then as a consequence you may
|
| 547 |
+
not convey it at all. For example, if you agree to terms that obligate you
|
| 548 |
+
to collect a royalty for further conveying from those to whom you convey
|
| 549 |
+
the Program, the only way you could satisfy both those terms and this
|
| 550 |
+
License would be to refrain entirely from conveying the Program.
|
| 551 |
+
|
| 552 |
+
13. Use with the GNU Affero General Public License.
|
| 553 |
+
|
| 554 |
+
Notwithstanding any other provision of this License, you have
|
| 555 |
+
permission to link or combine any covered work with a work licensed
|
| 556 |
+
under version 3 of the GNU Affero General Public License into a single
|
| 557 |
+
combined work, and to convey the resulting work. The terms of this
|
| 558 |
+
License will continue to apply to the part which is the covered work,
|
| 559 |
+
but the special requirements of the GNU Affero General Public License,
|
| 560 |
+
section 13, concerning interaction through a network will apply to the
|
| 561 |
+
combination as such.
|
| 562 |
+
|
| 563 |
+
14. Revised Versions of this License.
|
| 564 |
+
|
| 565 |
+
The Free Software Foundation may publish revised and/or new versions of
|
| 566 |
+
the GNU General Public License from time to time. Such new versions will
|
| 567 |
+
be similar in spirit to the present version, but may differ in detail to
|
| 568 |
+
address new problems or concerns.
|
| 569 |
+
|
| 570 |
+
Each version is given a distinguishing version number. If the
|
| 571 |
+
Program specifies that a certain numbered version of the GNU General
|
| 572 |
+
Public License "or any later version" applies to it, you have the
|
| 573 |
+
option of following the terms and conditions either of that numbered
|
| 574 |
+
version or of any later version published by the Free Software
|
| 575 |
+
Foundation. If the Program does not specify a version number of the
|
| 576 |
+
GNU General Public License, you may choose any version ever published
|
| 577 |
+
by the Free Software Foundation.
|
| 578 |
+
|
| 579 |
+
If the Program specifies that a proxy can decide which future
|
| 580 |
+
versions of the GNU General Public License can be used, that proxy's
|
| 581 |
+
public statement of acceptance of a version permanently authorizes you
|
| 582 |
+
to choose that version for the Program.
|
| 583 |
+
|
| 584 |
+
Later license versions may give you additional or different
|
| 585 |
+
permissions. However, no additional obligations are imposed on any
|
| 586 |
+
author or copyright holder as a result of your choosing to follow a
|
| 587 |
+
later version.
|
| 588 |
+
|
| 589 |
+
15. Disclaimer of Warranty.
|
| 590 |
+
|
| 591 |
+
THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
|
| 592 |
+
APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
|
| 593 |
+
HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
|
| 594 |
+
OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
|
| 595 |
+
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
|
| 596 |
+
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
|
| 597 |
+
IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
|
| 598 |
+
ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
|
| 599 |
+
|
| 600 |
+
16. Limitation of Liability.
|
| 601 |
+
|
| 602 |
+
IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
|
| 603 |
+
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
|
| 604 |
+
THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
|
| 605 |
+
GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
|
| 606 |
+
USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
|
| 607 |
+
DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
|
| 608 |
+
PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
|
| 609 |
+
EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
|
| 610 |
+
SUCH DAMAGES.
|
| 611 |
+
|
| 612 |
+
17. Interpretation of Sections 15 and 16.
|
| 613 |
+
|
| 614 |
+
If the disclaimer of warranty and limitation of liability provided
|
| 615 |
+
above cannot be given local legal effect according to their terms,
|
| 616 |
+
reviewing courts shall apply local law that most closely approximates
|
| 617 |
+
an absolute waiver of all civil liability in connection with the
|
| 618 |
+
Program, unless a warranty or assumption of liability accompanies a
|
| 619 |
+
copy of the Program in return for a fee.
|
| 620 |
+
|
| 621 |
+
END OF TERMS AND CONDITIONS
|
| 622 |
+
|
| 623 |
+
How to Apply These Terms to Your New Programs
|
| 624 |
+
|
| 625 |
+
If you develop a new program, and you want it to be of the greatest
|
| 626 |
+
possible use to the public, the best way to achieve this is to make it
|
| 627 |
+
free software which everyone can redistribute and change under these terms.
|
| 628 |
+
|
| 629 |
+
To do so, attach the following notices to the program. It is safest
|
| 630 |
+
to attach them to the start of each source file to most effectively
|
| 631 |
+
state the exclusion of warranty; and each file should have at least
|
| 632 |
+
the "copyright" line and a pointer to where the full notice is found.
|
| 633 |
+
|
| 634 |
+
<one line to give the program's name and a brief idea of what it does.>
|
| 635 |
+
Copyright (C) <year> <name of author>
|
| 636 |
+
|
| 637 |
+
This program is free software: you can redistribute it and/or modify
|
| 638 |
+
it under the terms of the GNU General Public License as published by
|
| 639 |
+
the Free Software Foundation, either version 3 of the License, or
|
| 640 |
+
(at your option) any later version.
|
| 641 |
+
|
| 642 |
+
This program is distributed in the hope that it will be useful,
|
| 643 |
+
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
| 644 |
+
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
| 645 |
+
GNU General Public License for more details.
|
| 646 |
+
|
| 647 |
+
You should have received a copy of the GNU General Public License
|
| 648 |
+
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
| 649 |
+
|
| 650 |
+
Also add information on how to contact you by electronic and paper mail.
|
| 651 |
+
|
| 652 |
+
If the program does terminal interaction, make it output a short
|
| 653 |
+
notice like this when it starts in an interactive mode:
|
| 654 |
+
|
| 655 |
+
<program> Copyright (C) <year> <name of author>
|
| 656 |
+
This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
|
| 657 |
+
This is free software, and you are welcome to redistribute it
|
| 658 |
+
under certain conditions; type `show c' for details.
|
| 659 |
+
|
| 660 |
+
The hypothetical commands `show w' and `show c' should show the appropriate
|
| 661 |
+
parts of the General Public License. Of course, your program's commands
|
| 662 |
+
might be different; for a GUI interface, you would use an "about box".
|
| 663 |
+
|
| 664 |
+
You should also get your employer (if you work as a programmer) or school,
|
| 665 |
+
if any, to sign a "copyright disclaimer" for the program, if necessary.
|
| 666 |
+
For more information on this, and how to apply and follow the GNU GPL, see
|
| 667 |
+
<http://www.gnu.org/licenses/>.
|
| 668 |
+
|
| 669 |
+
The GNU General Public License does not permit incorporating your program
|
| 670 |
+
into proprietary programs. If your program is a subroutine library, you
|
| 671 |
+
may consider it more useful to permit linking proprietary applications with
|
| 672 |
+
the library. If this is what you want to do, use the GNU Lesser General
|
| 673 |
+
Public License instead of this License. But first, please read
|
| 674 |
+
<http://www.gnu.org/philosophy/why-not-lgpl.html>.
|
datasets/coco128/README.txt
ADDED
|
@@ -0,0 +1,22 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Introduction
|
| 2 |
+
|
| 3 |
+
This directory contains software developed by Ultralytics LLC, and **is freely available for redistribution under the GPL-3.0 license**. For more information please visit https://www.ultralytics.com.
|
| 4 |
+
|
| 5 |
+
# Description
|
| 6 |
+
|
| 7 |
+
The https://github.com/ultralytics/COCO2YOLO repo contains code to convert JSON datasets into YOLO (darknet) format. The code works on Linux, MacOS and Windows.
|
| 8 |
+
|
| 9 |
+
# Requirements
|
| 10 |
+
|
| 11 |
+
Python 3.7 or later with the following `pip3 install -U -r requirements.txt` packages:
|
| 12 |
+
|
| 13 |
+
- `numpy`
|
| 14 |
+
- `tqdm`
|
| 15 |
+
|
| 16 |
+
# Citation
|
| 17 |
+
|
| 18 |
+
[](https://zenodo.org/badge/latestdoi/186122711)
|
| 19 |
+
|
| 20 |
+
# Contact
|
| 21 |
+
|
| 22 |
+
Issues should be raised directly in the repository. For additional questions or comments please email Glenn Jocher at glenn.jocher@ultralytics.com or visit us at https://contact.ultralytics.com.
|
datasets/coco128/labels/train2017.cache
ADDED
|
Binary file (49 kB). View file
|
|
|
datasets/coco128/labels/train2017/000000000009.txt
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
45 0.479492 0.688771 0.955609 0.5955
|
| 2 |
+
45 0.736516 0.247188 0.498875 0.476417
|
| 3 |
+
50 0.637063 0.732938 0.494125 0.510583
|
| 4 |
+
45 0.339438 0.418896 0.678875 0.7815
|
| 5 |
+
49 0.646836 0.132552 0.118047 0.0969375
|
| 6 |
+
49 0.773148 0.129802 0.0907344 0.0972292
|
| 7 |
+
49 0.668297 0.226906 0.131281 0.146896
|
| 8 |
+
49 0.642859 0.0792187 0.148063 0.148062
|
datasets/coco128/labels/train2017/000000000144.txt
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
23 0.650563 0.626781 0.573031 0.746438
|
| 2 |
+
23 0.536969 0.637385 0.469781 0.725229
|
| 3 |
+
23 0.38343 0.583146 0.615172 0.833708
|
datasets/coco128/labels/train2017/000000000149.txt
ADDED
|
@@ -0,0 +1,22 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
0 0.613805 0.7741 0.0150156 0.0311449
|
| 2 |
+
0 0.535719 0.755491 0.01075 0.0305607
|
| 3 |
+
0 0.525578 0.753984 0.00984375 0.0325935
|
| 4 |
+
0 0.639203 0.776121 0.0229687 0.0302804
|
| 5 |
+
33 0.692844 0.46715 0.0286875 0.0350467
|
| 6 |
+
33 0.446031 0.596834 0.0151562 0.0148832
|
| 7 |
+
33 0.689094 0.207897 0.0162188 0.0292056
|
| 8 |
+
33 0.475727 0.499147 0.0350781 0.0250234
|
| 9 |
+
0 0.879875 0.763516 0.0110937 0.0432477
|
| 10 |
+
0 0.845305 0.755491 0.00795313 0.0343925
|
| 11 |
+
2 0.442828 0.734521 0.0151562 0.0124533
|
| 12 |
+
2 0.494555 0.745853 0.0163906 0.0110514
|
| 13 |
+
2 0.467687 0.744346 0.0134375 0.0096729
|
| 14 |
+
2 0.415742 0.759311 0.0303906 0.0168458
|
| 15 |
+
33 0.130477 0.81125 0.0651094 0.031285
|
| 16 |
+
33 0.630531 0.660187 0.0588437 0.0371963
|
| 17 |
+
0 0.434891 0.778084 0.0125312 0.0299533
|
| 18 |
+
0 0.85457 0.76118 0.00695313 0.0380607
|
| 19 |
+
0 0.919844 0.762196 0.0070625 0.0230841
|
| 20 |
+
0 0.394578 0.765829 0.0083125 0.0538084
|
| 21 |
+
0 0.37107 0.765047 0.0122344 0.056729
|
| 22 |
+
0 0.349812 0.764147 0.0119375 0.0635748
|
datasets/coco128/labels/train2017/000000000164.txt
ADDED
|
@@ -0,0 +1,40 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
39 0.615391 0.411156 0.0125312 0.0559792
|
| 2 |
+
39 0.590367 0.416885 0.0107344 0.0436042
|
| 3 |
+
39 0.58018 0.413521 0.0110156 0.057375
|
| 4 |
+
39 0.60432 0.416 0.0112656 0.0505
|
| 5 |
+
39 0.692109 0.61676 0.028625 0.0653542
|
| 6 |
+
72 0.745406 0.500187 0.151125 0.287583
|
| 7 |
+
39 0.731344 0.62699 0.0155 0.0761458
|
| 8 |
+
39 0.632141 0.354646 0.0146875 0.035625
|
| 9 |
+
39 0.591961 0.298708 0.0163906 0.0315833
|
| 10 |
+
39 0.639766 0.292698 0.0152812 0.0328125
|
| 11 |
+
39 0.65693 0.290938 0.0166406 0.035125
|
| 12 |
+
56 0.36675 0.926208 0.2365 0.147583
|
| 13 |
+
40 0.250586 0.425167 0.0200469 0.058875
|
| 14 |
+
40 0.232906 0.435479 0.0251563 0.076125
|
| 15 |
+
40 0.180586 0.443792 0.0223594 0.0695833
|
| 16 |
+
40 0.106906 0.447781 0.0307187 0.0783958
|
| 17 |
+
40 0.139813 0.448458 0.024125 0.0825
|
| 18 |
+
40 0.15907 0.447073 0.0184844 0.0769375
|
| 19 |
+
41 0.25 0.508854 0.0418437 0.0433333
|
| 20 |
+
41 0.197148 0.513687 0.0362969 0.0406667
|
| 21 |
+
41 0.291938 0.50151 0.0314688 0.0336042
|
| 22 |
+
41 0.322883 0.49299 0.0312344 0.0323125
|
| 23 |
+
45 0.834883 0.472427 0.0877344 0.0219375
|
| 24 |
+
68 0.631812 0.505479 0.08325 0.06325
|
| 25 |
+
69 0.465656 0.584354 0.0731563 0.0712917
|
| 26 |
+
40 0.127484 0.447563 0.0169375 0.0826667
|
| 27 |
+
40 0.198609 0.437896 0.0247812 0.079
|
| 28 |
+
40 0.21668 0.438781 0.0167969 0.0736875
|
| 29 |
+
41 0.266141 0.504708 0.0339375 0.04425
|
| 30 |
+
41 0.813328 0.301812 0.0240625 0.0445417
|
| 31 |
+
41 0.844102 0.305635 0.0237344 0.0285625
|
| 32 |
+
41 0.795687 0.314125 0.00978125 0.0170833
|
| 33 |
+
41 0.279133 0.44301 0.0277344 0.0392708
|
| 34 |
+
41 0.220984 0.507156 0.0239375 0.0421042
|
| 35 |
+
45 0.813344 0.445646 0.0455938 0.00975
|
| 36 |
+
45 0.833727 0.461135 0.0888906 0.00877083
|
| 37 |
+
45 0.836367 0.454271 0.0812969 0.0109167
|
| 38 |
+
45 0.835375 0.449427 0.0869062 0.0126458
|
| 39 |
+
45 0.577438 0.366531 0.020875 0.0188542
|
| 40 |
+
60 0.689609 0.972083 0.214281 0.0311667
|
datasets/coco128/labels/train2017/000000000263.txt
ADDED
|
@@ -0,0 +1,2 @@
|
|
|
|
|
|
|
|
|
|
| 1 |
+
20 0.632327 0.626688 0.735347 0.724219
|
| 2 |
+
20 0.330499 0.483117 0.655381 0.924672
|
datasets/coco128/labels/train2017/000000000338.txt
ADDED
|
@@ -0,0 +1,6 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
72 0.414813 0.72896 0.149656 0.54208
|
| 2 |
+
74 0.734047 0.308853 0.0363125 0.0752599
|
| 3 |
+
0 0.581609 0.715352 0.141344 0.561774
|
| 4 |
+
0 0.730945 0.765627 0.0889219 0.468746
|
| 5 |
+
69 0.146391 0.866284 0.217 0.240459
|
| 6 |
+
26 0.746844 0.768563 0.0400937 0.120306
|
datasets/coco128/labels/train2017/000000000349.txt
ADDED
|
@@ -0,0 +1,4 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
6 0.421352 0.540448 0.842703 0.537062
|
| 2 |
+
58 0.6685 0.665531 0.09825 0.163271
|
| 3 |
+
58 0.750336 0.629198 0.0790469 0.130479
|
| 4 |
+
58 0.80107 0.635146 0.0448594 0.0831667
|
datasets/coco128/labels/train2017/000000000357.txt
ADDED
|
@@ -0,0 +1,17 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
34 0.845453 0.619358 0.00625 0.124954
|
| 2 |
+
35 0.892836 0.870573 0.0139219 0.0306881
|
| 3 |
+
35 0.125352 0.466812 0.0108906 0.0422477
|
| 4 |
+
35 0.440953 0.125642 0.00853125 0.0216514
|
| 5 |
+
0 0.595023 0.178188 0.0269531 0.126743
|
| 6 |
+
0 0.444703 0.169633 0.0422187 0.170459
|
| 7 |
+
0 0.344438 0.174839 0.0346875 0.142248
|
| 8 |
+
0 0.13107 0.473211 0.0289531 0.22055
|
| 9 |
+
0 0.852109 0.750023 0.045375 0.250413
|
| 10 |
+
0 0.907797 0.821261 0.0418125 0.17445
|
| 11 |
+
0 0.946813 0.81656 0.0424687 0.213761
|
| 12 |
+
0 0.879648 0.132087 0.0217031 0.0443578
|
| 13 |
+
0 0.859398 0.156514 0.0150781 0.12
|
| 14 |
+
0 0.939578 0.0609404 0.014 0.0465596
|
| 15 |
+
0 0.428398 0.0922018 0.0276406 0.125413
|
| 16 |
+
0 0.897008 0.188716 0.0185469 0.108899
|
| 17 |
+
0 0.913047 0.202523 0.0105 0.109725
|
datasets/coco128/labels/train2017/000000000359.txt
ADDED
|
@@ -0,0 +1,4 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
9 0.37311 0.354111 0.13074 0.103163
|
| 2 |
+
9 0.53852 0.334759 0.102 0.0674699
|
| 3 |
+
9 0.56142 0.890166 0.00892 0.0123795
|
| 4 |
+
2 0.12372 0.930422 0.24744 0.113193
|
datasets/coco128/labels/train2017/000000000387.txt
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
63 0.682586 0.394385 0.586516 0.577521
|
| 2 |
+
63 0.605953 0.430167 0.735719 0.650792
|
| 3 |
+
67 0.683594 0.33074 0.328125 0.195312
|
datasets/coco128/labels/train2017/000000000394.txt
ADDED
|
@@ -0,0 +1,2 @@
|
|
|
|
|
|
|
|
|
|
| 1 |
+
16 0.488914 0.494869 0.977828 0.936809
|
| 2 |
+
29 0.645445 0.542463 0.555422 0.477889
|
datasets/coco128/labels/train2017/000000000395.txt
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
67 0.470422 0.518578 0.031 0.0396034
|
| 2 |
+
0 0.523391 0.613483 0.676125 0.750552
|
| 3 |
+
0 0.0631328 0.597897 0.126266 0.480897
|
| 4 |
+
0 0.184836 0.643534 0.128984 0.352862
|
| 5 |
+
0 0.902508 0.672655 0.194984 0.65469
|
| 6 |
+
67 0.979633 0.537129 0.0247344 0.0199828
|
| 7 |
+
0 0.200016 0.441362 0.0607188 0.0808621
|
| 8 |
+
0 0.284094 0.507862 0.128312 0.188759
|
| 9 |
+
0 0.670172 0.427164 0.0514687 0.182707
|
| 10 |
+
0 0.7045 0.453991 0.0685937 0.195086
|
| 11 |
+
0 0.296867 0.630474 0.0943594 0.115466
|
| 12 |
+
0 0.123273 0.479983 0.0756094 0.218862
|
| 13 |
+
0 0.755555 0.513638 0.110609 0.154586
|
datasets/coco128/labels/train2017/000000000404.txt
ADDED
|
@@ -0,0 +1,5 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
8 0.496162 0.629578 0.737535 0.135094
|
| 2 |
+
8 0.684789 0.598344 0.467512 0.0718125
|
| 3 |
+
8 0.776596 0.576383 0.368732 0.0462656
|
| 4 |
+
8 0.718721 0.571922 0.201338 0.0254375
|
| 5 |
+
8 0.669155 0.564172 0.0579812 0.0172187
|
datasets/coco128/labels/train2017/000000000443.txt
ADDED
|
@@ -0,0 +1,6 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
15 0.601289 0.507552 0.581891 0.793104
|
| 2 |
+
0 0.589883 0.494385 0.812359 0.984271
|
| 3 |
+
0 0.881742 0.320229 0.236516 0.631458
|
| 4 |
+
65 0.891086 0.564917 0.217828 0.317875
|
| 5 |
+
57 0.446102 0.493792 0.888828 0.979667
|
| 6 |
+
0 0.115742 0.642802 0.224078 0.649396
|
datasets/coco128/labels/train2017/000000000486.txt
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
72 0.661219 0.540585 0.0985 0.257283
|
| 2 |
+
69 0.806289 0.82192 0.387422 0.356159
|
| 3 |
+
39 0.987359 0.590995 0.0250312 0.0893911
|
| 4 |
+
43 0.354859 0.511148 0.0108125 0.121686
|
| 5 |
+
39 0.797414 0.681768 0.0360156 0.059274
|
| 6 |
+
39 0.133781 0.54733 0.008 0.068103
|
| 7 |
+
43 0.370891 0.489778 0.00609375 0.0387119
|
| 8 |
+
45 0.49707 0.805504 0.205297 0.206604
|
datasets/coco128/labels/train2017/000000000491.txt
ADDED
|
@@ -0,0 +1,4 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
77 0.53007 0.511406 0.52238 0.950799
|
| 2 |
+
77 0.77515 0.250783 0.39914 0.496645
|
| 3 |
+
77 0.09187 0.305192 0.18374 0.579201
|
| 4 |
+
77 0.3722 0.194617 0.42652 0.383419
|
datasets/coco128/labels/train2017/000000000531.txt
ADDED
|
@@ -0,0 +1,15 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
1 0.0961484 0.577531 0.0396094 0.0350625
|
| 2 |
+
0 0.441242 0.610219 0.0615781 0.185812
|
| 3 |
+
1 0.0487266 0.581052 0.0393594 0.0324375
|
| 4 |
+
0 0.158914 0.60201 0.0588594 0.136771
|
| 5 |
+
0 0.402781 0.554979 0.0191562 0.0547917
|
| 6 |
+
32 0.4245 0.616625 0.00290625 0.00575
|
| 7 |
+
0 0.34607 0.556073 0.0166094 0.0496042
|
| 8 |
+
0 0.708234 0.550083 0.0200625 0.0737917
|
| 9 |
+
0 0.797523 0.542563 0.0198594 0.0664583
|
| 10 |
+
38 0.471602 0.638062 0.0230469 0.0662083
|
| 11 |
+
0 0.618039 0.555833 0.0188906 0.0434583
|
| 12 |
+
0 0.0276328 0.575719 0.0350781 0.0746042
|
| 13 |
+
38 0.0979609 0.567479 0.106297 0.0743333
|
| 14 |
+
38 0.398789 0.564906 0.00676562 0.0088125
|
| 15 |
+
1 0.990477 0.564375 0.0163906 0.0199167
|
datasets/coco128/labels/train2017/000000000532.txt
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
5 0.495508 0.537823 0.721359 0.546063
|
| 2 |
+
0 0.455234 0.651458 0.0695625 0.325542
|
| 3 |
+
0 0.229922 0.646854 0.0713437 0.237542
|
| 4 |
+
0 0.359898 0.462552 0.0281094 0.0383125
|
| 5 |
+
0 0.250852 0.471458 0.0191719 0.0409583
|
| 6 |
+
5 0.0761484 0.538552 0.151234 0.395854
|
| 7 |
+
26 0.25575 0.596667 0.0329688 0.0740417
|
| 8 |
+
26 0.199906 0.686667 0.0235938 0.0528333
|
datasets/coco128/labels/train2017/000000000569.txt
ADDED
|
@@ -0,0 +1,5 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
0 0.200297 0.712146 0.125281 0.302875
|
| 2 |
+
33 0.318227 0.461302 0.0469844 0.0648958
|
| 3 |
+
33 0.278828 0.485896 0.0260312 0.067875
|
| 4 |
+
33 0.245305 0.502354 0.0359219 0.049375
|
| 5 |
+
33 0.230844 0.523781 0.0400937 0.0485208
|
datasets/coco128/labels/train2017/000000000659.txt
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
0 0.132172 0.552259 0.118562 0.537176
|
| 2 |
+
0 0.249211 0.569659 0.104453 0.456165
|
| 3 |
+
0 0.0285469 0.491588 0.0545625 0.312024
|
| 4 |
+
0 0.0884609 0.379012 0.0463594 0.112612
|
| 5 |
+
6 0.446703 0.554741 0.554625 0.794565
|
| 6 |
+
0 0.165211 0.391718 0.0635781 0.0516706
|
| 7 |
+
0 0.165625 0.400082 0.0372188 0.130424
|
| 8 |
+
0 0.178945 0.354788 0.0235156 0.0436471
|
| 9 |
+
26 0.174266 0.664047 0.0525 0.119341
|
ultralytics/docker/Dockerfile
ADDED
|
@@ -0,0 +1,89 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Ultralytics YOLO 🚀, AGPL-3.0 license
|
| 2 |
+
# Builds ultralytics/ultralytics:latest image on DockerHub https://hub.docker.com/r/ultralytics/ultralytics
|
| 3 |
+
# Image is CUDA-optimized for YOLOv8 single/multi-GPU training and inference
|
| 4 |
+
|
| 5 |
+
# Start FROM PyTorch image https://hub.docker.com/r/pytorch/pytorch or nvcr.io/nvidia/pytorch:23.03-py3
|
| 6 |
+
FROM pytorch/pytorch:2.3.1-cuda12.1-cudnn8-runtime
|
| 7 |
+
|
| 8 |
+
# Set environment variables
|
| 9 |
+
# Avoid DDP error "MKL_THREADING_LAYER=INTEL is incompatible with libgomp.so.1 library" https://github.com/pytorch/pytorch/issues/37377
|
| 10 |
+
ENV PYTHONUNBUFFERED=1 \
|
| 11 |
+
PYTHONDONTWRITEBYTECODE=1 \
|
| 12 |
+
PIP_NO_CACHE_DIR=1 \
|
| 13 |
+
PIP_BREAK_SYSTEM_PACKAGES=1 \
|
| 14 |
+
MKL_THREADING_LAYER=GNU
|
| 15 |
+
|
| 16 |
+
# Downloads to user config dir
|
| 17 |
+
ADD https://github.com/ultralytics/assets/releases/download/v0.0.0/Arial.ttf \
|
| 18 |
+
https://github.com/ultralytics/assets/releases/download/v0.0.0/Arial.Unicode.ttf \
|
| 19 |
+
/root/.config/Ultralytics/
|
| 20 |
+
|
| 21 |
+
# Install linux packages
|
| 22 |
+
# g++ required to build 'tflite_support' and 'lap' packages, libusb-1.0-0 required for 'tflite_support' package
|
| 23 |
+
# libsm6 required by libqxcb to create QT-based windows for visualization; set 'QT_DEBUG_PLUGINS=1' to test in docker
|
| 24 |
+
RUN apt update \
|
| 25 |
+
&& apt install --no-install-recommends -y gcc git zip unzip wget curl htop libgl1 libglib2.0-0 libpython3-dev gnupg g++ libusb-1.0-0 libsm6
|
| 26 |
+
|
| 27 |
+
# Security updates
|
| 28 |
+
# https://security.snyk.io/vuln/SNYK-UBUNTU1804-OPENSSL-3314796
|
| 29 |
+
RUN apt upgrade --no-install-recommends -y openssl tar
|
| 30 |
+
|
| 31 |
+
# Create working directory
|
| 32 |
+
WORKDIR /ultralytics
|
| 33 |
+
|
| 34 |
+
# Copy contents and configure git
|
| 35 |
+
COPY . .
|
| 36 |
+
RUN sed -i '/^\[http "https:\/\/github\.com\/"\]/,+1d' .git/config
|
| 37 |
+
ADD https://github.com/ultralytics/assets/releases/download/v8.2.0/yolov8n.pt .
|
| 38 |
+
|
| 39 |
+
# Install pip packages
|
| 40 |
+
RUN python3 -m pip install --upgrade pip wheel
|
| 41 |
+
# Pin TensorRT-cu12==10.1.0 to avoid 10.2.0 bug https://github.com/ultralytics/ultralytics/pull/14239 (note -cu12 must be used)
|
| 42 |
+
RUN pip install -e ".[export]" "tensorrt-cu12==10.1.0" "albumentations>=1.4.6" comet pycocotools
|
| 43 |
+
|
| 44 |
+
# Run exports to AutoInstall packages
|
| 45 |
+
# Edge TPU export fails the first time so is run twice here
|
| 46 |
+
RUN yolo export model=tmp/yolov8n.pt format=edgetpu imgsz=32 || yolo export model=tmp/yolov8n.pt format=edgetpu imgsz=32
|
| 47 |
+
RUN yolo export model=tmp/yolov8n.pt format=ncnn imgsz=32
|
| 48 |
+
# Requires <= Python 3.10, bug with paddlepaddle==2.5.0 https://github.com/PaddlePaddle/X2Paddle/issues/991
|
| 49 |
+
RUN pip install "paddlepaddle>=2.6.0" x2paddle
|
| 50 |
+
# Fix error: `np.bool` was a deprecated alias for the builtin `bool` segmentation error in Tests
|
| 51 |
+
RUN pip install numpy==1.23.5
|
| 52 |
+
# Remove exported models
|
| 53 |
+
RUN rm -rf tmp
|
| 54 |
+
|
| 55 |
+
|
| 56 |
+
# Usage Examples -------------------------------------------------------------------------------------------------------
|
| 57 |
+
|
| 58 |
+
# Build and Push
|
| 59 |
+
# t=ultralytics/ultralytics:latest && sudo docker build -f docker/Dockerfile -t $t . && sudo docker push $t
|
| 60 |
+
|
| 61 |
+
# Pull and Run with access to all GPUs
|
| 62 |
+
# t=ultralytics/ultralytics:latest && sudo docker pull $t && sudo docker run -it --ipc=host --gpus all $t
|
| 63 |
+
|
| 64 |
+
# Pull and Run with access to GPUs 2 and 3 (inside container CUDA devices will appear as 0 and 1)
|
| 65 |
+
# t=ultralytics/ultralytics:latest && sudo docker pull $t && sudo docker run -it --ipc=host --gpus '"device=2,3"' $t
|
| 66 |
+
|
| 67 |
+
# Pull and Run with local directory access
|
| 68 |
+
# t=ultralytics/ultralytics:latest && sudo docker pull $t && sudo docker run -it --ipc=host --gpus all -v "$(pwd)"/shared/datasets:/datasets $t
|
| 69 |
+
|
| 70 |
+
# Kill all
|
| 71 |
+
# sudo docker kill $(sudo docker ps -q)
|
| 72 |
+
|
| 73 |
+
# Kill all image-based
|
| 74 |
+
# sudo docker kill $(sudo docker ps -qa --filter ancestor=ultralytics/ultralytics:latest)
|
| 75 |
+
|
| 76 |
+
# DockerHub tag update
|
| 77 |
+
# t=ultralytics/ultralytics:latest tnew=ultralytics/ultralytics:v6.2 && sudo docker pull $t && sudo docker tag $t $tnew && sudo docker push $tnew
|
| 78 |
+
|
| 79 |
+
# Clean up
|
| 80 |
+
# sudo docker system prune -a --volumes
|
| 81 |
+
|
| 82 |
+
# Update Ubuntu drivers
|
| 83 |
+
# https://www.maketecheasier.com/install-nvidia-drivers-ubuntu/
|
| 84 |
+
|
| 85 |
+
# DDP test
|
| 86 |
+
# python -m torch.distributed.run --nproc_per_node 2 --master_port 1 train.py --epochs 3
|
| 87 |
+
|
| 88 |
+
# GCP VM from Image
|
| 89 |
+
# docker.io/ultralytics/ultralytics:latest
|
ultralytics/docker/Dockerfile-arm64
ADDED
|
@@ -0,0 +1,54 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Ultralytics YOLO 🚀, AGPL-3.0 license
|
| 2 |
+
# Builds ultralytics/ultralytics:latest-arm64 image on DockerHub https://hub.docker.com/r/ultralytics/ultralytics
|
| 3 |
+
# Image is aarch64-compatible for Apple M1, M2, M3, Raspberry Pi and other ARM architectures
|
| 4 |
+
|
| 5 |
+
# Start FROM Ubuntu image https://hub.docker.com/_/ubuntu with "FROM arm64v8/ubuntu:22.04" (deprecated)
|
| 6 |
+
# Start FROM Debian image for arm64v8 https://hub.docker.com/r/arm64v8/debian (new)
|
| 7 |
+
FROM arm64v8/debian:bookworm-slim
|
| 8 |
+
|
| 9 |
+
# Set environment variables
|
| 10 |
+
ENV PYTHONUNBUFFERED=1 \
|
| 11 |
+
PYTHONDONTWRITEBYTECODE=1 \
|
| 12 |
+
PIP_NO_CACHE_DIR=1 \
|
| 13 |
+
PIP_BREAK_SYSTEM_PACKAGES=1
|
| 14 |
+
|
| 15 |
+
# Downloads to user config dir
|
| 16 |
+
ADD https://github.com/ultralytics/assets/releases/download/v0.0.0/Arial.ttf \
|
| 17 |
+
https://github.com/ultralytics/assets/releases/download/v0.0.0/Arial.Unicode.ttf \
|
| 18 |
+
/root/.config/Ultralytics/
|
| 19 |
+
|
| 20 |
+
# Install linux packages
|
| 21 |
+
# g++ required to build 'tflite_support' and 'lap' packages, libusb-1.0-0 required for 'tflite_support' package
|
| 22 |
+
# pkg-config and libhdf5-dev (not included) are needed to build 'h5py==3.11.0' aarch64 wheel required by 'tensorflow'
|
| 23 |
+
RUN apt update \
|
| 24 |
+
&& apt install --no-install-recommends -y python3-pip git zip unzip wget curl htop gcc libgl1 libglib2.0-0 libpython3-dev gnupg g++ libusb-1.0-0
|
| 25 |
+
|
| 26 |
+
# Create working directory
|
| 27 |
+
WORKDIR /ultralytics
|
| 28 |
+
|
| 29 |
+
# Copy contents and configure git
|
| 30 |
+
COPY . .
|
| 31 |
+
RUN sed -i '/^\[http "https:\/\/github\.com\/"\]/,+1d' .git/config
|
| 32 |
+
ADD https://github.com/ultralytics/assets/releases/download/v8.2.0/yolov8n.pt .
|
| 33 |
+
|
| 34 |
+
# Install pip packages
|
| 35 |
+
RUN python3 -m pip install --upgrade pip wheel
|
| 36 |
+
RUN pip install -e ".[export]"
|
| 37 |
+
|
| 38 |
+
# Creates a symbolic link to make 'python' point to 'python3'
|
| 39 |
+
RUN ln -sf /usr/bin/python3 /usr/bin/python
|
| 40 |
+
|
| 41 |
+
|
| 42 |
+
# Usage Examples -------------------------------------------------------------------------------------------------------
|
| 43 |
+
|
| 44 |
+
# Build and Push
|
| 45 |
+
# t=ultralytics/ultralytics:latest-arm64 && sudo docker build --platform linux/arm64 -f docker/Dockerfile-arm64 -t $t . && sudo docker push $t
|
| 46 |
+
|
| 47 |
+
# Run
|
| 48 |
+
# t=ultralytics/ultralytics:latest-arm64 && sudo docker run -it --ipc=host $t
|
| 49 |
+
|
| 50 |
+
# Pull and Run
|
| 51 |
+
# t=ultralytics/ultralytics:latest-arm64 && sudo docker pull $t && sudo docker run -it --ipc=host $t
|
| 52 |
+
|
| 53 |
+
# Pull and Run with local volume mounted
|
| 54 |
+
# t=ultralytics/ultralytics:latest-arm64 && sudo docker pull $t && sudo docker run -it --ipc=host -v "$(pwd)"/shared/datasets:/datasets $t
|
ultralytics/docker/Dockerfile-conda
ADDED
|
@@ -0,0 +1,46 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Ultralytics YOLO 🚀, AGPL-3.0 license
|
| 2 |
+
# Builds ultralytics/ultralytics:latest-conda image on DockerHub https://hub.docker.com/r/ultralytics/ultralytics
|
| 3 |
+
# Image is optimized for Ultralytics Anaconda (https://anaconda.org/conda-forge/ultralytics) installation and usage
|
| 4 |
+
|
| 5 |
+
# Start FROM miniconda3 image https://hub.docker.com/r/continuumio/miniconda3
|
| 6 |
+
FROM continuumio/miniconda3:latest
|
| 7 |
+
|
| 8 |
+
# Set environment variables
|
| 9 |
+
ENV PYTHONUNBUFFERED=1 \
|
| 10 |
+
PYTHONDONTWRITEBYTECODE=1 \
|
| 11 |
+
PIP_NO_CACHE_DIR=1 \
|
| 12 |
+
PIP_BREAK_SYSTEM_PACKAGES=1
|
| 13 |
+
|
| 14 |
+
# Downloads to user config dir
|
| 15 |
+
ADD https://github.com/ultralytics/assets/releases/download/v0.0.0/Arial.ttf \
|
| 16 |
+
https://github.com/ultralytics/assets/releases/download/v0.0.0/Arial.Unicode.ttf \
|
| 17 |
+
/root/.config/Ultralytics/
|
| 18 |
+
|
| 19 |
+
# Install linux packages
|
| 20 |
+
RUN apt update \
|
| 21 |
+
&& apt install --no-install-recommends -y libgl1
|
| 22 |
+
|
| 23 |
+
# Copy contents
|
| 24 |
+
ADD https://github.com/ultralytics/assets/releases/download/v8.2.0/yolov8n.pt .
|
| 25 |
+
|
| 26 |
+
# Install conda packages
|
| 27 |
+
# mkl required to fix 'OSError: libmkl_intel_lp64.so.2: cannot open shared object file: No such file or directory'
|
| 28 |
+
RUN conda config --set solver libmamba && \
|
| 29 |
+
conda install pytorch torchvision pytorch-cuda=12.1 -c pytorch -c nvidia && \
|
| 30 |
+
conda install -c conda-forge ultralytics mkl
|
| 31 |
+
# conda install -c pytorch -c nvidia -c conda-forge pytorch torchvision pytorch-cuda=12.1 ultralytics mkl
|
| 32 |
+
|
| 33 |
+
|
| 34 |
+
# Usage Examples -------------------------------------------------------------------------------------------------------
|
| 35 |
+
|
| 36 |
+
# Build and Push
|
| 37 |
+
# t=ultralytics/ultralytics:latest-conda && sudo docker build -f docker/Dockerfile-cpu -t $t . && sudo docker push $t
|
| 38 |
+
|
| 39 |
+
# Run
|
| 40 |
+
# t=ultralytics/ultralytics:latest-conda && sudo docker run -it --ipc=host $t
|
| 41 |
+
|
| 42 |
+
# Pull and Run
|
| 43 |
+
# t=ultralytics/ultralytics:latest-conda && sudo docker pull $t && sudo docker run -it --ipc=host $t
|
| 44 |
+
|
| 45 |
+
# Pull and Run with local volume mounted
|
| 46 |
+
# t=ultralytics/ultralytics:latest-conda && sudo docker pull $t && sudo docker run -it --ipc=host -v "$(pwd)"/shared/datasets:/datasets $t
|
ultralytics/docker/Dockerfile-cpu
ADDED
|
@@ -0,0 +1,60 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Ultralytics YOLO 🚀, AGPL-3.0 license
|
| 2 |
+
# Builds ultralytics/ultralytics:latest-cpu image on DockerHub https://hub.docker.com/r/ultralytics/ultralytics
|
| 3 |
+
# Image is CPU-optimized for ONNX, OpenVINO and PyTorch YOLOv8 deployments
|
| 4 |
+
|
| 5 |
+
# Start FROM Ubuntu image https://hub.docker.com/_/ubuntu
|
| 6 |
+
FROM ubuntu:23.10
|
| 7 |
+
|
| 8 |
+
# Set environment variables
|
| 9 |
+
ENV PYTHONUNBUFFERED=1 \
|
| 10 |
+
PYTHONDONTWRITEBYTECODE=1 \
|
| 11 |
+
PIP_NO_CACHE_DIR=1 \
|
| 12 |
+
PIP_BREAK_SYSTEM_PACKAGES=1
|
| 13 |
+
|
| 14 |
+
# Downloads to user config dir
|
| 15 |
+
ADD https://github.com/ultralytics/assets/releases/download/v0.0.0/Arial.ttf \
|
| 16 |
+
https://github.com/ultralytics/assets/releases/download/v0.0.0/Arial.Unicode.ttf \
|
| 17 |
+
/root/.config/Ultralytics/
|
| 18 |
+
|
| 19 |
+
# Install linux packages
|
| 20 |
+
# g++ required to build 'tflite_support' and 'lap' packages, libusb-1.0-0 required for 'tflite_support' package
|
| 21 |
+
RUN apt update \
|
| 22 |
+
&& apt install --no-install-recommends -y python3-pip git zip unzip wget curl htop libgl1 libglib2.0-0 libpython3-dev gnupg g++ libusb-1.0-0
|
| 23 |
+
|
| 24 |
+
# Create working directory
|
| 25 |
+
WORKDIR /ultralytics
|
| 26 |
+
|
| 27 |
+
# Copy contents and configure git
|
| 28 |
+
COPY . .
|
| 29 |
+
RUN sed -i '/^\[http "https:\/\/github\.com\/"\]/,+1d' .git/config
|
| 30 |
+
ADD https://github.com/ultralytics/assets/releases/download/v8.2.0/yolov8n.pt .
|
| 31 |
+
|
| 32 |
+
# Install pip packages
|
| 33 |
+
RUN python3 -m pip install --upgrade pip wheel
|
| 34 |
+
RUN pip install -e ".[export]" --extra-index-url https://download.pytorch.org/whl/cpu
|
| 35 |
+
|
| 36 |
+
# Run exports to AutoInstall packages
|
| 37 |
+
RUN yolo export model=tmp/yolov8n.pt format=edgetpu imgsz=32
|
| 38 |
+
RUN yolo export model=tmp/yolov8n.pt format=ncnn imgsz=32
|
| 39 |
+
# Requires Python<=3.10, bug with paddlepaddle==2.5.0 https://github.com/PaddlePaddle/X2Paddle/issues/991
|
| 40 |
+
# RUN pip install "paddlepaddle>=2.6.0" x2paddle
|
| 41 |
+
# Remove exported models
|
| 42 |
+
RUN rm -rf tmp
|
| 43 |
+
|
| 44 |
+
# Creates a symbolic link to make 'python' point to 'python3'
|
| 45 |
+
RUN ln -sf /usr/bin/python3 /usr/bin/python
|
| 46 |
+
|
| 47 |
+
|
| 48 |
+
# Usage Examples -------------------------------------------------------------------------------------------------------
|
| 49 |
+
|
| 50 |
+
# Build and Push
|
| 51 |
+
# t=ultralytics/ultralytics:latest-cpu && sudo docker build -f docker/Dockerfile-cpu -t $t . && sudo docker push $t
|
| 52 |
+
|
| 53 |
+
# Run
|
| 54 |
+
# t=ultralytics/ultralytics:latest-cpu && sudo docker run -it --ipc=host --name NAME $t
|
| 55 |
+
|
| 56 |
+
# Pull and Run
|
| 57 |
+
# t=ultralytics/ultralytics:latest-cpu && sudo docker pull $t && sudo docker run -it --ipc=host --name NAME $t
|
| 58 |
+
|
| 59 |
+
# Pull and Run with local volume mounted
|
| 60 |
+
# t=ultralytics/ultralytics:latest-cpu && sudo docker pull $t && sudo docker run -it --ipc=host -v "$(pwd)"/shared/datasets:/datasets $t
|
ultralytics/docker/Dockerfile-jetson-jetpack4
ADDED
|
@@ -0,0 +1,65 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Ultralytics YOLO 🚀, AGPL-3.0 license
|
| 2 |
+
# Builds ultralytics/ultralytics:jetson-jetpack4 image on DockerHub https://hub.docker.com/r/ultralytics/ultralytics
|
| 3 |
+
# Supports JetPack4.x for YOLOv8 on Jetson Nano, TX2, Xavier NX, AGX Xavier
|
| 4 |
+
|
| 5 |
+
# Start FROM https://catalog.ngc.nvidia.com/orgs/nvidia/containers/l4t-cuda
|
| 6 |
+
FROM nvcr.io/nvidia/l4t-cuda:10.2.460-runtime
|
| 7 |
+
|
| 8 |
+
# Set environment variables
|
| 9 |
+
ENV PYTHONUNBUFFERED=1 \
|
| 10 |
+
PYTHONDONTWRITEBYTECODE=1
|
| 11 |
+
|
| 12 |
+
# Downloads to user config dir
|
| 13 |
+
ADD https://github.com/ultralytics/assets/releases/download/v0.0.0/Arial.ttf \
|
| 14 |
+
https://github.com/ultralytics/assets/releases/download/v0.0.0/Arial.Unicode.ttf \
|
| 15 |
+
/root/.config/Ultralytics/
|
| 16 |
+
|
| 17 |
+
# Add NVIDIA repositories for TensorRT dependencies
|
| 18 |
+
RUN wget -q -O - https://repo.download.nvidia.com/jetson/jetson-ota-public.asc | apt-key add - && \
|
| 19 |
+
echo "deb https://repo.download.nvidia.com/jetson/common r32.7 main" > /etc/apt/sources.list.d/nvidia-l4t-apt-source.list && \
|
| 20 |
+
echo "deb https://repo.download.nvidia.com/jetson/t194 r32.7 main" >> /etc/apt/sources.list.d/nvidia-l4t-apt-source.list
|
| 21 |
+
|
| 22 |
+
# Install dependencies
|
| 23 |
+
RUN apt update && \
|
| 24 |
+
apt install --no-install-recommends -y git python3.8 python3.8-dev python3-pip python3-libnvinfer libopenmpi-dev libopenblas-base libomp-dev gcc
|
| 25 |
+
|
| 26 |
+
# Create symbolic links for python3.8 and pip3
|
| 27 |
+
RUN ln -sf /usr/bin/python3.8 /usr/bin/python3
|
| 28 |
+
RUN ln -s /usr/bin/pip3 /usr/bin/pip
|
| 29 |
+
|
| 30 |
+
# Create working directory
|
| 31 |
+
WORKDIR /ultralytics
|
| 32 |
+
|
| 33 |
+
# Copy contents and configure git
|
| 34 |
+
COPY . .
|
| 35 |
+
RUN sed -i '/^\[http "https:\/\/github\.com\/"\]/,+1d' .git/config
|
| 36 |
+
ADD https://github.com/ultralytics/assets/releases/download/v8.2.0/yolov8n.pt .
|
| 37 |
+
|
| 38 |
+
# Download onnxruntime-gpu 1.8.0 and tensorrt 8.2.0.6
|
| 39 |
+
# Other versions can be seen in https://elinux.org/Jetson_Zoo and https://forums.developer.nvidia.com/t/pytorch-for-jetson/72048
|
| 40 |
+
ADD https://nvidia.box.com/shared/static/gjqofg7rkg97z3gc8jeyup6t8n9j8xjw.whl onnxruntime_gpu-1.8.0-cp38-cp38-linux_aarch64.whl
|
| 41 |
+
ADD https://forums.developer.nvidia.com/uploads/short-url/hASzFOm9YsJx6VVFrDW1g44CMmv.whl tensorrt-8.2.0.6-cp38-none-linux_aarch64.whl
|
| 42 |
+
|
| 43 |
+
# Install pip packages
|
| 44 |
+
RUN python3 -m pip install --upgrade pip wheel
|
| 45 |
+
RUN pip install \
|
| 46 |
+
onnxruntime_gpu-1.8.0-cp38-cp38-linux_aarch64.whl \
|
| 47 |
+
tensorrt-8.2.0.6-cp38-none-linux_aarch64.whl \
|
| 48 |
+
https://github.com/ultralytics/assets/releases/download/v0.0.0/torch-1.11.0a0+gitbc2c6ed-cp38-cp38-linux_aarch64.whl \
|
| 49 |
+
https://github.com/ultralytics/assets/releases/download/v0.0.0/torchvision-0.12.0a0+9b5a3fe-cp38-cp38-linux_aarch64.whl
|
| 50 |
+
RUN pip install -e ".[export]"
|
| 51 |
+
RUN rm *.whl
|
| 52 |
+
|
| 53 |
+
# Usage Examples -------------------------------------------------------------------------------------------------------
|
| 54 |
+
|
| 55 |
+
# Build and Push
|
| 56 |
+
# t=ultralytics/ultralytics:latest-jetson-jetpack4 && sudo docker build --platform linux/arm64 -f docker/Dockerfile-jetson-jetpack4 -t $t . && sudo docker push $t
|
| 57 |
+
|
| 58 |
+
# Run
|
| 59 |
+
# t=ultralytics/ultralytics:latest-jetson-jetpack4 && sudo docker run -it --ipc=host $t
|
| 60 |
+
|
| 61 |
+
# Pull and Run
|
| 62 |
+
# t=ultralytics/ultralytics:latest-jetson-jetpack4 && sudo docker pull $t && sudo docker run -it --ipc=host $t
|
| 63 |
+
|
| 64 |
+
# Pull and Run with NVIDIA runtime
|
| 65 |
+
# t=ultralytics/ultralytics:latest-jetson-jetpack4 && sudo docker pull $t && sudo docker run -it --ipc=host --runtime=nvidia $t
|
ultralytics/docker/Dockerfile-jetson-jetpack5
ADDED
|
@@ -0,0 +1,59 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Ultralytics YOLO 🚀, AGPL-3.0 license
|
| 2 |
+
# Builds ultralytics/ultralytics:jetson-jetson-jetpack5 image on DockerHub https://hub.docker.com/r/ultralytics/ultralytics
|
| 3 |
+
# Supports JetPack5.x for YOLOv8 on Jetson Xavier NX, AGX Xavier, AGX Orin, Orin Nano and Orin NX
|
| 4 |
+
|
| 5 |
+
# Start FROM https://catalog.ngc.nvidia.com/orgs/nvidia/containers/l4t-pytorch
|
| 6 |
+
FROM nvcr.io/nvidia/l4t-pytorch:r35.2.1-pth2.0-py3
|
| 7 |
+
|
| 8 |
+
# Set environment variables
|
| 9 |
+
ENV PYTHONUNBUFFERED=1 \
|
| 10 |
+
PYTHONDONTWRITEBYTECODE=1 \
|
| 11 |
+
PIP_NO_CACHE_DIR=1 \
|
| 12 |
+
PIP_BREAK_SYSTEM_PACKAGES=1
|
| 13 |
+
|
| 14 |
+
# Downloads to user config dir
|
| 15 |
+
ADD https://github.com/ultralytics/assets/releases/download/v0.0.0/Arial.ttf \
|
| 16 |
+
https://github.com/ultralytics/assets/releases/download/v0.0.0/Arial.Unicode.ttf \
|
| 17 |
+
/root/.config/Ultralytics/
|
| 18 |
+
|
| 19 |
+
# Install linux packages
|
| 20 |
+
# g++ required to build 'tflite_support' and 'lap' packages
|
| 21 |
+
# libusb-1.0-0 required for 'tflite_support' package when exporting to TFLite
|
| 22 |
+
# pkg-config and libhdf5-dev (not included) are needed to build 'h5py==3.11.0' aarch64 wheel required by 'tensorflow'
|
| 23 |
+
RUN apt update \
|
| 24 |
+
&& apt install --no-install-recommends -y gcc git zip unzip wget curl htop libgl1 libglib2.0-0 libpython3-dev gnupg g++ libusb-1.0-0
|
| 25 |
+
|
| 26 |
+
# Create working directory
|
| 27 |
+
WORKDIR /ultralytics
|
| 28 |
+
|
| 29 |
+
# Copy contents and configure git
|
| 30 |
+
COPY . .
|
| 31 |
+
RUN sed -i '/^\[http "https:\/\/github\.com\/"\]/,+1d' .git/config
|
| 32 |
+
ADD https://github.com/ultralytics/assets/releases/download/v8.2.0/yolov8n.pt .
|
| 33 |
+
|
| 34 |
+
# Remove opencv-python from Ultralytics dependencies as it conflicts with opencv-python installed in base image
|
| 35 |
+
RUN sed -i '/opencv-python/d' pyproject.toml
|
| 36 |
+
|
| 37 |
+
# Download onnxruntime-gpu 1.15.1 for Jetson Linux 35.2.1 (JetPack 5.1). Other versions can be seen in https://elinux.org/Jetson_Zoo#ONNX_Runtime
|
| 38 |
+
ADD https://nvidia.box.com/shared/static/mvdcltm9ewdy2d5nurkiqorofz1s53ww.whl onnxruntime_gpu-1.15.1-cp38-cp38-linux_aarch64.whl
|
| 39 |
+
|
| 40 |
+
# Install pip packages manually for TensorRT compatibility https://github.com/NVIDIA/TensorRT/issues/2567
|
| 41 |
+
RUN python3 -m pip install --upgrade pip wheel
|
| 42 |
+
RUN pip install onnxruntime_gpu-1.15.1-cp38-cp38-linux_aarch64.whl
|
| 43 |
+
RUN pip install -e ".[export]"
|
| 44 |
+
RUN rm *.whl
|
| 45 |
+
|
| 46 |
+
|
| 47 |
+
# Usage Examples -------------------------------------------------------------------------------------------------------
|
| 48 |
+
|
| 49 |
+
# Build and Push
|
| 50 |
+
# t=ultralytics/ultralytics:latest-jetson-jetpack5 && sudo docker build --platform linux/arm64 -f docker/Dockerfile-jetson-jetpack5 -t $t . && sudo docker push $t
|
| 51 |
+
|
| 52 |
+
# Run
|
| 53 |
+
# t=ultralytics/ultralytics:latest-jetson-jetpack5 && sudo docker run -it --ipc=host $t
|
| 54 |
+
|
| 55 |
+
# Pull and Run
|
| 56 |
+
# t=ultralytics/ultralytics:latest-jetson-jetpack5 && sudo docker pull $t && sudo docker run -it --ipc=host $t
|
| 57 |
+
|
| 58 |
+
# Pull and Run with NVIDIA runtime
|
| 59 |
+
# t=ultralytics/ultralytics:latest-jetson-jetpack5 && sudo docker pull $t && sudo docker run -it --ipc=host --runtime=nvidia $t
|
ultralytics/docker/Dockerfile-jetson-jetpack6
ADDED
|
@@ -0,0 +1,55 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Ultralytics YOLO 🚀, AGPL-3.0 license
|
| 2 |
+
# Builds ultralytics/ultralytics:jetson-jetpack6 image on DockerHub https://hub.docker.com/r/ultralytics/ultralytics
|
| 3 |
+
# Supports JetPack6.x for YOLOv8 on Jetson AGX Orin, Orin NX and Orin Nano Series
|
| 4 |
+
|
| 5 |
+
# Start FROM https://catalog.ngc.nvidia.com/orgs/nvidia/containers/l4t-jetpack
|
| 6 |
+
FROM nvcr.io/nvidia/l4t-jetpack:r36.3.0
|
| 7 |
+
|
| 8 |
+
# Set environment variables
|
| 9 |
+
ENV PYTHONUNBUFFERED=1 \
|
| 10 |
+
PYTHONDONTWRITEBYTECODE=1 \
|
| 11 |
+
PIP_NO_CACHE_DIR=1 \
|
| 12 |
+
PIP_BREAK_SYSTEM_PACKAGES=1
|
| 13 |
+
|
| 14 |
+
# Downloads to user config dir
|
| 15 |
+
ADD https://github.com/ultralytics/assets/releases/download/v0.0.0/Arial.ttf \
|
| 16 |
+
https://github.com/ultralytics/assets/releases/download/v0.0.0/Arial.Unicode.ttf \
|
| 17 |
+
/root/.config/Ultralytics/
|
| 18 |
+
|
| 19 |
+
# Install dependencies
|
| 20 |
+
RUN apt update && \
|
| 21 |
+
apt install --no-install-recommends -y git python3-pip libopenmpi-dev libopenblas-base libomp-dev
|
| 22 |
+
|
| 23 |
+
# Create working directory
|
| 24 |
+
WORKDIR /ultralytics
|
| 25 |
+
|
| 26 |
+
# Copy contents and configure git
|
| 27 |
+
COPY . .
|
| 28 |
+
RUN sed -i '/^\[http "https:\/\/github\.com\/"\]/,+1d' .git/config
|
| 29 |
+
ADD https://github.com/ultralytics/assets/releases/download/v8.2.0/yolov8n.pt .
|
| 30 |
+
|
| 31 |
+
# Download onnxruntime-gpu 1.18.0 from https://elinux.org/Jetson_Zoo and https://forums.developer.nvidia.com/t/pytorch-for-jetson/72048
|
| 32 |
+
ADD https://nvidia.box.com/shared/static/48dtuob7meiw6ebgfsfqakc9vse62sg4.whl onnxruntime_gpu-1.18.0-cp310-cp310-linux_aarch64.whl
|
| 33 |
+
|
| 34 |
+
# Pip install onnxruntime-gpu, torch, torchvision and ultralytics
|
| 35 |
+
RUN python3 -m pip install --upgrade pip wheel
|
| 36 |
+
RUN pip install \
|
| 37 |
+
onnxruntime_gpu-1.18.0-cp310-cp310-linux_aarch64.whl \
|
| 38 |
+
https://github.com/ultralytics/assets/releases/download/v0.0.0/torch-2.3.0-cp310-cp310-linux_aarch64.whl \
|
| 39 |
+
https://github.com/ultralytics/assets/releases/download/v0.0.0/torchvision-0.18.0a0+6043bc2-cp310-cp310-linux_aarch64.whl
|
| 40 |
+
RUN pip install -e ".[export]"
|
| 41 |
+
RUN rm *.whl
|
| 42 |
+
|
| 43 |
+
# Usage Examples -------------------------------------------------------------------------------------------------------
|
| 44 |
+
|
| 45 |
+
# Build and Push
|
| 46 |
+
# t=ultralytics/ultralytics:latest-jetson-jetpack6 && sudo docker build --platform linux/arm64 -f docker/Dockerfile-jetson-jetpack6 -t $t . && sudo docker push $t
|
| 47 |
+
|
| 48 |
+
# Run
|
| 49 |
+
# t=ultralytics/ultralytics:latest-jetson-jetpack6 && sudo docker run -it --ipc=host $t
|
| 50 |
+
|
| 51 |
+
# Pull and Run
|
| 52 |
+
# t=ultralytics/ultralytics:latest-jetson-jetpack6 && sudo docker pull $t && sudo docker run -it --ipc=host $t
|
| 53 |
+
|
| 54 |
+
# Pull and Run with NVIDIA runtime
|
| 55 |
+
# t=ultralytics/ultralytics:latest-jetson-jetpack6 && sudo docker pull $t && sudo docker run -it --ipc=host --runtime=nvidia $t
|
ultralytics/docker/Dockerfile-python
ADDED
|
@@ -0,0 +1,57 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Ultralytics YOLO 🚀, AGPL-3.0 license
|
| 2 |
+
# Builds ultralytics/ultralytics:latest-cpu image on DockerHub https://hub.docker.com/r/ultralytics/ultralytics
|
| 3 |
+
# Image is CPU-optimized for ONNX, OpenVINO and PyTorch YOLOv8 deployments
|
| 4 |
+
|
| 5 |
+
# Use the official Python 3.10 slim-bookworm as base image
|
| 6 |
+
FROM python:3.10-slim-bookworm
|
| 7 |
+
|
| 8 |
+
# Set environment variables
|
| 9 |
+
ENV PYTHONUNBUFFERED=1 \
|
| 10 |
+
PYTHONDONTWRITEBYTECODE=1 \
|
| 11 |
+
PIP_NO_CACHE_DIR=1 \
|
| 12 |
+
PIP_BREAK_SYSTEM_PACKAGES=1
|
| 13 |
+
|
| 14 |
+
# Downloads to user config dir
|
| 15 |
+
ADD https://github.com/ultralytics/assets/releases/download/v0.0.0/Arial.ttf \
|
| 16 |
+
https://github.com/ultralytics/assets/releases/download/v0.0.0/Arial.Unicode.ttf \
|
| 17 |
+
/root/.config/Ultralytics/
|
| 18 |
+
|
| 19 |
+
# Install linux packages
|
| 20 |
+
# g++ required to build 'tflite_support' and 'lap' packages, libusb-1.0-0 required for 'tflite_support' package
|
| 21 |
+
RUN apt update \
|
| 22 |
+
&& apt install --no-install-recommends -y python3-pip git zip unzip wget curl htop libgl1 libglib2.0-0 libpython3-dev gnupg g++ libusb-1.0-0
|
| 23 |
+
|
| 24 |
+
# Create working directory
|
| 25 |
+
WORKDIR /ultralytics
|
| 26 |
+
|
| 27 |
+
# Copy contents and configure git
|
| 28 |
+
COPY . .
|
| 29 |
+
RUN sed -i '/^\[http "https:\/\/github\.com\/"\]/,+1d' .git/config
|
| 30 |
+
ADD https://github.com/ultralytics/assets/releases/download/v8.2.0/yolov8n.pt .
|
| 31 |
+
|
| 32 |
+
# Install pip packages
|
| 33 |
+
RUN python3 -m pip install --upgrade pip wheel
|
| 34 |
+
RUN pip install -e ".[export]" --extra-index-url https://download.pytorch.org/whl/cpu
|
| 35 |
+
|
| 36 |
+
# Run exports to AutoInstall packages
|
| 37 |
+
RUN yolo export model=tmp/yolov8n.pt format=edgetpu imgsz=32
|
| 38 |
+
RUN yolo export model=tmp/yolov8n.pt format=ncnn imgsz=32
|
| 39 |
+
# Requires Python<=3.10, bug with paddlepaddle==2.5.0 https://github.com/PaddlePaddle/X2Paddle/issues/991
|
| 40 |
+
RUN pip install "paddlepaddle>=2.6.0" x2paddle
|
| 41 |
+
# Remove exported models
|
| 42 |
+
RUN rm -rf tmp
|
| 43 |
+
|
| 44 |
+
|
| 45 |
+
# Usage Examples -------------------------------------------------------------------------------------------------------
|
| 46 |
+
|
| 47 |
+
# Build and Push
|
| 48 |
+
# t=ultralytics/ultralytics:latest-python && sudo docker build -f docker/Dockerfile-python -t $t . && sudo docker push $t
|
| 49 |
+
|
| 50 |
+
# Run
|
| 51 |
+
# t=ultralytics/ultralytics:latest-python && sudo docker run -it --ipc=host $t
|
| 52 |
+
|
| 53 |
+
# Pull and Run
|
| 54 |
+
# t=ultralytics/ultralytics:latest-python && sudo docker pull $t && sudo docker run -it --ipc=host $t
|
| 55 |
+
|
| 56 |
+
# Pull and Run with local volume mounted
|
| 57 |
+
# t=ultralytics/ultralytics:latest-python && sudo docker pull $t && sudo docker run -it --ipc=host -v "$(pwd)"/shared/datasets:/datasets $t
|
ultralytics/docker/Dockerfile-runner
ADDED
|
@@ -0,0 +1,45 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Ultralytics YOLO 🚀, AGPL-3.0 license
|
| 2 |
+
# Builds GitHub actions CI runner image for deployment to DockerHub https://hub.docker.com/r/ultralytics/ultralytics
|
| 3 |
+
# Image is CUDA-optimized for YOLOv8 single/multi-GPU training and inference tests
|
| 4 |
+
|
| 5 |
+
# Start FROM Ultralytics GPU image
|
| 6 |
+
FROM ultralytics/ultralytics:latest
|
| 7 |
+
|
| 8 |
+
# Set environment variables
|
| 9 |
+
ENV PYTHONUNBUFFERED=1 \
|
| 10 |
+
PYTHONDONTWRITEBYTECODE=1 \
|
| 11 |
+
PIP_NO_CACHE_DIR=1 \
|
| 12 |
+
PIP_BREAK_SYSTEM_PACKAGES=1 \
|
| 13 |
+
RUNNER_ALLOW_RUNASROOT=1 \
|
| 14 |
+
DEBIAN_FRONTEND=noninteractive
|
| 15 |
+
|
| 16 |
+
# Set the working directory
|
| 17 |
+
WORKDIR /actions-runner
|
| 18 |
+
|
| 19 |
+
# Download and unpack the latest runner from https://github.com/actions/runner
|
| 20 |
+
RUN FILENAME=actions-runner-linux-x64-2.317.0.tar.gz && \
|
| 21 |
+
curl -o $FILENAME -L https://github.com/actions/runner/releases/download/v2.317.0/$FILENAME && \
|
| 22 |
+
tar xzf $FILENAME && \
|
| 23 |
+
rm $FILENAME
|
| 24 |
+
|
| 25 |
+
# Install runner dependencies
|
| 26 |
+
RUN pip install pytest-cov
|
| 27 |
+
RUN ./bin/installdependencies.sh && \
|
| 28 |
+
apt-get -y install libicu-dev
|
| 29 |
+
|
| 30 |
+
# Inline ENTRYPOINT command to configure and start runner with default TOKEN and NAME
|
| 31 |
+
ENTRYPOINT sh -c './config.sh --url https://github.com/ultralytics/ultralytics \
|
| 32 |
+
--token ${GITHUB_RUNNER_TOKEN:-TOKEN} \
|
| 33 |
+
--name ${GITHUB_RUNNER_NAME:-NAME} \
|
| 34 |
+
--labels gpu-latest \
|
| 35 |
+
--replace && \
|
| 36 |
+
./run.sh'
|
| 37 |
+
|
| 38 |
+
|
| 39 |
+
# Usage Examples -------------------------------------------------------------------------------------------------------
|
| 40 |
+
|
| 41 |
+
# Build and Push
|
| 42 |
+
# t=ultralytics/ultralytics:latest-runner && sudo docker build -f docker/Dockerfile-runner -t $t . && sudo docker push $t
|
| 43 |
+
|
| 44 |
+
# Pull and Run in detached mode with access to GPUs 0 and 1
|
| 45 |
+
# t=ultralytics/ultralytics:latest-runner && sudo docker run -d -e GITHUB_RUNNER_TOKEN=TOKEN -e GITHUB_RUNNER_NAME=NAME --ipc=host --gpus '"device=0,1"' $t
|
ultralytics/docs/en/datasets/detect/argoverse.md
ADDED
|
@@ -0,0 +1,153 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
comments: true
|
| 3 |
+
description: Explore the comprehensive Argoverse dataset by Argo AI for 3D tracking, motion forecasting, and stereo depth estimation in autonomous driving research.
|
| 4 |
+
keywords: Argoverse dataset, autonomous driving, 3D tracking, motion forecasting, stereo depth estimation, Argo AI, LiDAR point clouds, high-resolution images, HD maps
|
| 5 |
+
---
|
| 6 |
+
|
| 7 |
+
# Argoverse Dataset
|
| 8 |
+
|
| 9 |
+
The [Argoverse](https://www.argoverse.org/) dataset is a collection of data designed to support research in autonomous driving tasks, such as 3D tracking, motion forecasting, and stereo depth estimation. Developed by Argo AI, the dataset provides a wide range of high-quality sensor data, including high-resolution images, LiDAR point clouds, and map data.
|
| 10 |
+
|
| 11 |
+
!!! note
|
| 12 |
+
|
| 13 |
+
The Argoverse dataset `*.zip` file required for training was removed from Amazon S3 after the shutdown of Argo AI by Ford, but we have made it available for manual download on [Google Drive](https://drive.google.com/file/d/1st9qW3BeIwQsnR0t8mRpvbsSWIo16ACi/view?usp=drive_link).
|
| 14 |
+
|
| 15 |
+
## Key Features
|
| 16 |
+
|
| 17 |
+
- Argoverse contains over 290K labeled 3D object tracks and 5 million object instances across 1,263 distinct scenes.
|
| 18 |
+
- The dataset includes high-resolution camera images, LiDAR point clouds, and richly annotated HD maps.
|
| 19 |
+
- Annotations include 3D bounding boxes for objects, object tracks, and trajectory information.
|
| 20 |
+
- Argoverse provides multiple subsets for different tasks, such as 3D tracking, motion forecasting, and stereo depth estimation.
|
| 21 |
+
|
| 22 |
+
## Dataset Structure
|
| 23 |
+
|
| 24 |
+
The Argoverse dataset is organized into three main subsets:
|
| 25 |
+
|
| 26 |
+
1. **Argoverse 3D Tracking**: This subset contains 113 scenes with over 290K labeled 3D object tracks, focusing on 3D object tracking tasks. It includes LiDAR point clouds, camera images, and sensor calibration information.
|
| 27 |
+
2. **Argoverse Motion Forecasting**: This subset consists of 324K vehicle trajectories collected from 60 hours of driving data, suitable for motion forecasting tasks.
|
| 28 |
+
3. **Argoverse Stereo Depth Estimation**: This subset is designed for stereo depth estimation tasks and includes over 10K stereo image pairs with corresponding LiDAR point clouds for ground truth depth estimation.
|
| 29 |
+
|
| 30 |
+
## Applications
|
| 31 |
+
|
| 32 |
+
The Argoverse dataset is widely used for training and evaluating deep learning models in autonomous driving tasks such as 3D object tracking, motion forecasting, and stereo depth estimation. The dataset's diverse set of sensor data, object annotations, and map information make it a valuable resource for researchers and practitioners in the field of autonomous driving.
|
| 33 |
+
|
| 34 |
+
## Dataset YAML
|
| 35 |
+
|
| 36 |
+
A YAML (Yet Another Markup Language) file is used to define the dataset configuration. It contains information about the dataset's paths, classes, and other relevant information. For the case of the Argoverse dataset, the `Argoverse.yaml` file is maintained at [https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/Argoverse.yaml](https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/Argoverse.yaml).
|
| 37 |
+
|
| 38 |
+
!!! example "ultralytics/cfg/datasets/Argoverse.yaml"
|
| 39 |
+
|
| 40 |
+
```yaml
|
| 41 |
+
--8<-- "ultralytics/cfg/datasets/Argoverse.yaml"
|
| 42 |
+
```
|
| 43 |
+
|
| 44 |
+
## Usage
|
| 45 |
+
|
| 46 |
+
To train a YOLOv8n model on the Argoverse dataset for 100 epochs with an image size of 640, you can use the following code snippets. For a comprehensive list of available arguments, refer to the model [Training](../../modes/train.md) page.
|
| 47 |
+
|
| 48 |
+
!!! example "Train Example"
|
| 49 |
+
|
| 50 |
+
=== "Python"
|
| 51 |
+
|
| 52 |
+
```python
|
| 53 |
+
from ultralytics import YOLO
|
| 54 |
+
|
| 55 |
+
# Load a model
|
| 56 |
+
model = YOLO("yolov8n.pt") # load a pretrained model (recommended for training)
|
| 57 |
+
|
| 58 |
+
# Train the model
|
| 59 |
+
results = model.train(data="Argoverse.yaml", epochs=100, imgsz=640)
|
| 60 |
+
```
|
| 61 |
+
|
| 62 |
+
=== "CLI"
|
| 63 |
+
|
| 64 |
+
```bash
|
| 65 |
+
# Start training from a pretrained *.pt model
|
| 66 |
+
yolo detect train data=Argoverse.yaml model=yolov8n.pt epochs=100 imgsz=640
|
| 67 |
+
```
|
| 68 |
+
|
| 69 |
+
## Sample Data and Annotations
|
| 70 |
+
|
| 71 |
+
The Argoverse dataset contains a diverse set of sensor data, including camera images, LiDAR point clouds, and HD map information, providing rich context for autonomous driving tasks. Here are some examples of data from the dataset, along with their corresponding annotations:
|
| 72 |
+
|
| 73 |
+

|
| 74 |
+
|
| 75 |
+
- **Argoverse 3D Tracking**: This image demonstrates an example of 3D object tracking, where objects are annotated with 3D bounding boxes. The dataset provides LiDAR point clouds and camera images to facilitate the development of models for this task.
|
| 76 |
+
|
| 77 |
+
The example showcases the variety and complexity of the data in the Argoverse dataset and highlights the importance of high-quality sensor data for autonomous driving tasks.
|
| 78 |
+
|
| 79 |
+
## Citations and Acknowledgments
|
| 80 |
+
|
| 81 |
+
If you use the Argoverse dataset in your research or development work, please cite the following paper:
|
| 82 |
+
|
| 83 |
+
!!! quote ""
|
| 84 |
+
|
| 85 |
+
=== "BibTeX"
|
| 86 |
+
|
| 87 |
+
```bibtex
|
| 88 |
+
@inproceedings{chang2019argoverse,
|
| 89 |
+
title={Argoverse: 3D Tracking and Forecasting with Rich Maps},
|
| 90 |
+
author={Chang, Ming-Fang and Lambert, John and Sangkloy, Patsorn and Singh, Jagjeet and Bak, Slawomir and Hartnett, Andrew and Wang, Dequan and Carr, Peter and Lucey, Simon and Ramanan, Deva and others},
|
| 91 |
+
booktitle={Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition},
|
| 92 |
+
pages={8748--8757},
|
| 93 |
+
year={2019}
|
| 94 |
+
}
|
| 95 |
+
```
|
| 96 |
+
|
| 97 |
+
We would like to acknowledge Argo AI for creating and maintaining the Argoverse dataset as a valuable resource for the autonomous driving research community. For more information about the Argoverse dataset and its creators, visit the [Argoverse dataset website](https://www.argoverse.org/).
|
| 98 |
+
|
| 99 |
+
## FAQ
|
| 100 |
+
|
| 101 |
+
### What is the Argoverse dataset and its key features?
|
| 102 |
+
|
| 103 |
+
The [Argoverse](https://www.argoverse.org/) dataset, developed by Argo AI, supports autonomous driving research. It includes over 290K labeled 3D object tracks and 5 million object instances across 1,263 distinct scenes. The dataset provides high-resolution camera images, LiDAR point clouds, and annotated HD maps, making it valuable for tasks like 3D tracking, motion forecasting, and stereo depth estimation.
|
| 104 |
+
|
| 105 |
+
### How can I train an Ultralytics YOLO model using the Argoverse dataset?
|
| 106 |
+
|
| 107 |
+
To train a YOLOv8 model with the Argoverse dataset, use the provided YAML configuration file and the following code:
|
| 108 |
+
|
| 109 |
+
!!! example "Train Example"
|
| 110 |
+
|
| 111 |
+
=== "Python"
|
| 112 |
+
|
| 113 |
+
```python
|
| 114 |
+
from ultralytics import YOLO
|
| 115 |
+
|
| 116 |
+
# Load a model
|
| 117 |
+
model = YOLO("yolov8n.pt") # load a pretrained model (recommended for training)
|
| 118 |
+
|
| 119 |
+
# Train the model
|
| 120 |
+
results = model.train(data="Argoverse.yaml", epochs=100, imgsz=640)
|
| 121 |
+
```
|
| 122 |
+
|
| 123 |
+
|
| 124 |
+
=== "CLI"
|
| 125 |
+
|
| 126 |
+
```bash
|
| 127 |
+
# Start training from a pretrained *.pt model
|
| 128 |
+
yolo detect train data=Argoverse.yaml model=yolov8n.pt epochs=100 imgsz=640
|
| 129 |
+
```
|
| 130 |
+
|
| 131 |
+
For a detailed explanation of the arguments, refer to the model [Training](../../modes/train.md) page.
|
| 132 |
+
|
| 133 |
+
### What types of data and annotations are available in the Argoverse dataset?
|
| 134 |
+
|
| 135 |
+
The Argoverse dataset includes various sensor data types such as high-resolution camera images, LiDAR point clouds, and HD map data. Annotations include 3D bounding boxes, object tracks, and trajectory information. These comprehensive annotations are essential for accurate model training in tasks like 3D object tracking, motion forecasting, and stereo depth estimation.
|
| 136 |
+
|
| 137 |
+
### How is the Argoverse dataset structured?
|
| 138 |
+
|
| 139 |
+
The dataset is divided into three main subsets:
|
| 140 |
+
|
| 141 |
+
1. **Argoverse 3D Tracking**: Contains 113 scenes with over 290K labeled 3D object tracks, focusing on 3D object tracking tasks. It includes LiDAR point clouds, camera images, and sensor calibration information.
|
| 142 |
+
2. **Argoverse Motion Forecasting**: Consists of 324K vehicle trajectories collected from 60 hours of driving data, suitable for motion forecasting tasks.
|
| 143 |
+
3. **Argoverse Stereo Depth Estimation**: Includes over 10K stereo image pairs with corresponding LiDAR point clouds for ground truth depth estimation.
|
| 144 |
+
|
| 145 |
+
### Where can I download the Argoverse dataset now that it has been removed from Amazon S3?
|
| 146 |
+
|
| 147 |
+
The Argoverse dataset `*.zip` file, previously available on Amazon S3, can now be manually downloaded from [Google Drive](https://drive.google.com/file/d/1st9qW3BeIwQsnR0t8mRpvbsSWIo16ACi/view?usp=drive_link).
|
| 148 |
+
|
| 149 |
+
### What is the YAML configuration file used for with the Argoverse dataset?
|
| 150 |
+
|
| 151 |
+
A YAML file contains the dataset's paths, classes, and other essential information. For the Argoverse dataset, the configuration file, `Argoverse.yaml`, can be found at the following link: [Argoverse.yaml](https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/Argoverse.yaml).
|
| 152 |
+
|
| 153 |
+
For more information about YAML configurations, see our [datasets](../index.md) guide.
|
ultralytics/docs/en/datasets/detect/coco.md
ADDED
|
@@ -0,0 +1,177 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
comments: true
|
| 3 |
+
description: Explore the COCO dataset for object detection and segmentation. Learn about its structure, usage, pretrained models, and key features.
|
| 4 |
+
keywords: COCO dataset, object detection, segmentation, benchmarking, computer vision, pose estimation, YOLO models, COCO annotations
|
| 5 |
+
---
|
| 6 |
+
|
| 7 |
+
# COCO Dataset
|
| 8 |
+
|
| 9 |
+
The [COCO](https://cocodataset.org/#home) (Common Objects in Context) dataset is a large-scale object detection, segmentation, and captioning dataset. It is designed to encourage research on a wide variety of object categories and is commonly used for benchmarking computer vision models. It is an essential dataset for researchers and developers working on object detection, segmentation, and pose estimation tasks.
|
| 10 |
+
|
| 11 |
+
<p align="center">
|
| 12 |
+
<br>
|
| 13 |
+
<iframe loading="lazy" width="720" height="405" src="https://www.youtube.com/embed/uDrn9QZJ2lk"
|
| 14 |
+
title="YouTube video player" frameborder="0"
|
| 15 |
+
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share"
|
| 16 |
+
allowfullscreen>
|
| 17 |
+
</iframe>
|
| 18 |
+
<br>
|
| 19 |
+
<strong>Watch:</strong> Ultralytics COCO Dataset Overview
|
| 20 |
+
</p>
|
| 21 |
+
|
| 22 |
+
## COCO Pretrained Models
|
| 23 |
+
|
| 24 |
+
| Model | size<br><sup>(pixels) | mAP<sup>val<br>50-95 | Speed<br><sup>CPU ONNX<br>(ms) | Speed<br><sup>A100 TensorRT<br>(ms) | params<br><sup>(M) | FLOPs<br><sup>(B) |
|
| 25 |
+
| ------------------------------------------------------------------------------------ | --------------------- | -------------------- | ------------------------------ | ----------------------------------- | ------------------ | ----------------- |
|
| 26 |
+
| [YOLOv8n](https://github.com/ultralytics/assets/releases/download/v8.2.0/yolov8n.pt) | 640 | 37.3 | 80.4 | 0.99 | 3.2 | 8.7 |
|
| 27 |
+
| [YOLOv8s](https://github.com/ultralytics/assets/releases/download/v8.2.0/yolov8s.pt) | 640 | 44.9 | 128.4 | 1.20 | 11.2 | 28.6 |
|
| 28 |
+
| [YOLOv8m](https://github.com/ultralytics/assets/releases/download/v8.2.0/yolov8m.pt) | 640 | 50.2 | 234.7 | 1.83 | 25.9 | 78.9 |
|
| 29 |
+
| [YOLOv8l](https://github.com/ultralytics/assets/releases/download/v8.2.0/yolov8l.pt) | 640 | 52.9 | 375.2 | 2.39 | 43.7 | 165.2 |
|
| 30 |
+
| [YOLOv8x](https://github.com/ultralytics/assets/releases/download/v8.2.0/yolov8x.pt) | 640 | 53.9 | 479.1 | 3.53 | 68.2 | 257.8 |
|
| 31 |
+
|
| 32 |
+
## Key Features
|
| 33 |
+
|
| 34 |
+
- COCO contains 330K images, with 200K images having annotations for object detection, segmentation, and captioning tasks.
|
| 35 |
+
- The dataset comprises 80 object categories, including common objects like cars, bicycles, and animals, as well as more specific categories such as umbrellas, handbags, and sports equipment.
|
| 36 |
+
- Annotations include object bounding boxes, segmentation masks, and captions for each image.
|
| 37 |
+
- COCO provides standardized evaluation metrics like mean Average Precision (mAP) for object detection, and mean Average Recall (mAR) for segmentation tasks, making it suitable for comparing model performance.
|
| 38 |
+
|
| 39 |
+
## Dataset Structure
|
| 40 |
+
|
| 41 |
+
The COCO dataset is split into three subsets:
|
| 42 |
+
|
| 43 |
+
1. **Train2017**: This subset contains 118K images for training object detection, segmentation, and captioning models.
|
| 44 |
+
2. **Val2017**: This subset has 5K images used for validation purposes during model training.
|
| 45 |
+
3. **Test2017**: This subset consists of 20K images used for testing and benchmarking the trained models. Ground truth annotations for this subset are not publicly available, and the results are submitted to the [COCO evaluation server](https://codalab.lisn.upsaclay.fr/competitions/7384) for performance evaluation.
|
| 46 |
+
|
| 47 |
+
## Applications
|
| 48 |
+
|
| 49 |
+
The COCO dataset is widely used for training and evaluating deep learning models in object detection (such as YOLO, Faster R-CNN, and SSD), instance segmentation (such as Mask R-CNN), and keypoint detection (such as OpenPose). The dataset's diverse set of object categories, large number of annotated images, and standardized evaluation metrics make it an essential resource for computer vision researchers and practitioners.
|
| 50 |
+
|
| 51 |
+
## Dataset YAML
|
| 52 |
+
|
| 53 |
+
A YAML (Yet Another Markup Language) file is used to define the dataset configuration. It contains information about the dataset's paths, classes, and other relevant information. In the case of the COCO dataset, the `coco.yaml` file is maintained at [https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/coco.yaml](https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/coco.yaml).
|
| 54 |
+
|
| 55 |
+
!!! example "ultralytics/cfg/datasets/coco.yaml"
|
| 56 |
+
|
| 57 |
+
```yaml
|
| 58 |
+
--8<-- "ultralytics/cfg/datasets/coco.yaml"
|
| 59 |
+
```
|
| 60 |
+
|
| 61 |
+
## Usage
|
| 62 |
+
|
| 63 |
+
To train a YOLOv8n model on the COCO dataset for 100 epochs with an image size of 640, you can use the following code snippets. For a comprehensive list of available arguments, refer to the model [Training](../../modes/train.md) page.
|
| 64 |
+
|
| 65 |
+
!!! example "Train Example"
|
| 66 |
+
|
| 67 |
+
=== "Python"
|
| 68 |
+
|
| 69 |
+
```python
|
| 70 |
+
from ultralytics import YOLO
|
| 71 |
+
|
| 72 |
+
# Load a model
|
| 73 |
+
model = YOLO("yolov8n.pt") # load a pretrained model (recommended for training)
|
| 74 |
+
|
| 75 |
+
# Train the model
|
| 76 |
+
results = model.train(data="coco.yaml", epochs=100, imgsz=640)
|
| 77 |
+
```
|
| 78 |
+
|
| 79 |
+
=== "CLI"
|
| 80 |
+
|
| 81 |
+
```bash
|
| 82 |
+
# Start training from a pretrained *.pt model
|
| 83 |
+
yolo detect train data=coco.yaml model=yolov8n.pt epochs=100 imgsz=640
|
| 84 |
+
```
|
| 85 |
+
|
| 86 |
+
## Sample Images and Annotations
|
| 87 |
+
|
| 88 |
+
The COCO dataset contains a diverse set of images with various object categories and complex scenes. Here are some examples of images from the dataset, along with their corresponding annotations:
|
| 89 |
+
|
| 90 |
+

|
| 91 |
+
|
| 92 |
+
- **Mosaiced Image**: This image demonstrates a training batch composed of mosaiced dataset images. Mosaicing is a technique used during training that combines multiple images into a single image to increase the variety of objects and scenes within each training batch. This helps improve the model's ability to generalize to different object sizes, aspect ratios, and contexts.
|
| 93 |
+
|
| 94 |
+
The example showcases the variety and complexity of the images in the COCO dataset and the benefits of using mosaicing during the training process.
|
| 95 |
+
|
| 96 |
+
## Citations and Acknowledgments
|
| 97 |
+
|
| 98 |
+
If you use the COCO dataset in your research or development work, please cite the following paper:
|
| 99 |
+
|
| 100 |
+
!!! quote ""
|
| 101 |
+
|
| 102 |
+
=== "BibTeX"
|
| 103 |
+
|
| 104 |
+
```bibtex
|
| 105 |
+
@misc{lin2015microsoft,
|
| 106 |
+
title={Microsoft COCO: Common Objects in Context},
|
| 107 |
+
author={Tsung-Yi Lin and Michael Maire and Serge Belongie and Lubomir Bourdev and Ross Girshick and James Hays and Pietro Perona and Deva Ramanan and C. Lawrence Zitnick and Piotr Dollár},
|
| 108 |
+
year={2015},
|
| 109 |
+
eprint={1405.0312},
|
| 110 |
+
archivePrefix={arXiv},
|
| 111 |
+
primaryClass={cs.CV}
|
| 112 |
+
}
|
| 113 |
+
```
|
| 114 |
+
|
| 115 |
+
We would like to acknowledge the COCO Consortium for creating and maintaining this valuable resource for the computer vision community. For more information about the COCO dataset and its creators, visit the [COCO dataset website](https://cocodataset.org/#home).
|
| 116 |
+
|
| 117 |
+
## FAQ
|
| 118 |
+
|
| 119 |
+
### What is the COCO dataset and why is it important for computer vision?
|
| 120 |
+
|
| 121 |
+
The [COCO dataset](https://cocodataset.org/#home) (Common Objects in Context) is a large-scale dataset used for object detection, segmentation, and captioning. It contains 330K images with detailed annotations for 80 object categories, making it essential for benchmarking and training computer vision models. Researchers use COCO due to its diverse categories and standardized evaluation metrics like mean Average Precision (mAP).
|
| 122 |
+
|
| 123 |
+
### How can I train a YOLO model using the COCO dataset?
|
| 124 |
+
|
| 125 |
+
To train a YOLOv8 model using the COCO dataset, you can use the following code snippets:
|
| 126 |
+
|
| 127 |
+
!!! example "Train Example"
|
| 128 |
+
|
| 129 |
+
=== "Python"
|
| 130 |
+
|
| 131 |
+
```python
|
| 132 |
+
from ultralytics import YOLO
|
| 133 |
+
|
| 134 |
+
# Load a model
|
| 135 |
+
model = YOLO("yolov8n.pt") # load a pretrained model (recommended for training)
|
| 136 |
+
|
| 137 |
+
# Train the model
|
| 138 |
+
results = model.train(data="coco.yaml", epochs=100, imgsz=640)
|
| 139 |
+
```
|
| 140 |
+
|
| 141 |
+
=== "CLI"
|
| 142 |
+
|
| 143 |
+
```bash
|
| 144 |
+
# Start training from a pretrained *.pt model
|
| 145 |
+
yolo detect train data=coco.yaml model=yolov8n.pt epochs=100 imgsz=640
|
| 146 |
+
```
|
| 147 |
+
|
| 148 |
+
Refer to the [Training page](../../modes/train.md) for more details on available arguments.
|
| 149 |
+
|
| 150 |
+
### What are the key features of the COCO dataset?
|
| 151 |
+
|
| 152 |
+
The COCO dataset includes:
|
| 153 |
+
|
| 154 |
+
- 330K images, with 200K annotated for object detection, segmentation, and captioning.
|
| 155 |
+
- 80 object categories ranging from common items like cars and animals to specific ones like handbags and sports equipment.
|
| 156 |
+
- Standardized evaluation metrics for object detection (mAP) and segmentation (mean Average Recall, mAR).
|
| 157 |
+
- **Mosaicing** technique in training batches to enhance model generalization across various object sizes and contexts.
|
| 158 |
+
|
| 159 |
+
### Where can I find pretrained YOLOv8 models trained on the COCO dataset?
|
| 160 |
+
|
| 161 |
+
Pretrained YOLOv8 models on the COCO dataset can be downloaded from the links provided in the documentation. Examples include:
|
| 162 |
+
|
| 163 |
+
- [YOLOv8n](https://github.com/ultralytics/assets/releases/download/v8.2.0/yolov8n.pt)
|
| 164 |
+
- [YOLOv8s](https://github.com/ultralytics/assets/releases/download/v8.2.0/yolov8s.pt)
|
| 165 |
+
- [YOLOv8m](https://github.com/ultralytics/assets/releases/download/v8.2.0/yolov8m.pt)
|
| 166 |
+
|
| 167 |
+
These models vary in size, mAP, and inference speed, providing options for different performance and resource requirements.
|
| 168 |
+
|
| 169 |
+
### How is the COCO dataset structured and how do I use it?
|
| 170 |
+
|
| 171 |
+
The COCO dataset is split into three subsets:
|
| 172 |
+
|
| 173 |
+
1. **Train2017**: 118K images for training.
|
| 174 |
+
2. **Val2017**: 5K images for validation during training.
|
| 175 |
+
3. **Test2017**: 20K images for benchmarking trained models. Results need to be submitted to the [COCO evaluation server](https://codalab.lisn.upsaclay.fr/competitions/7384) for performance evaluation.
|
| 176 |
+
|
| 177 |
+
The dataset's YAML configuration file is available at [coco.yaml](https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/coco.yaml), which defines paths, classes, and dataset details.
|
ultralytics/docs/en/datasets/detect/coco8.md
ADDED
|
@@ -0,0 +1,135 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
comments: true
|
| 3 |
+
description: Explore the Ultralytics COCO8 dataset, a versatile and manageable set of 8 images perfect for testing object detection models and training pipelines.
|
| 4 |
+
keywords: COCO8, Ultralytics, dataset, object detection, YOLOv8, training, validation, machine learning, computer vision
|
| 5 |
+
---
|
| 6 |
+
|
| 7 |
+
# COCO8 Dataset
|
| 8 |
+
|
| 9 |
+
## Introduction
|
| 10 |
+
|
| 11 |
+
[Ultralytics](https://www.ultralytics.com/) COCO8 is a small, but versatile object detection dataset composed of the first 8 images of the COCO train 2017 set, 4 for training and 4 for validation. This dataset is ideal for testing and debugging object detection models, or for experimenting with new detection approaches. With 8 images, it is small enough to be easily manageable, yet diverse enough to test training pipelines for errors and act as a sanity check before training larger datasets.
|
| 12 |
+
|
| 13 |
+
<p align="center">
|
| 14 |
+
<br>
|
| 15 |
+
<iframe loading="lazy" width="720" height="405" src="https://www.youtube.com/embed/uDrn9QZJ2lk"
|
| 16 |
+
title="YouTube video player" frameborder="0"
|
| 17 |
+
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share"
|
| 18 |
+
allowfullscreen>
|
| 19 |
+
</iframe>
|
| 20 |
+
<br>
|
| 21 |
+
<strong>Watch:</strong> Ultralytics COCO Dataset Overview
|
| 22 |
+
</p>
|
| 23 |
+
|
| 24 |
+
This dataset is intended for use with Ultralytics [HUB](https://hub.ultralytics.com/) and [YOLOv8](https://github.com/ultralytics/ultralytics).
|
| 25 |
+
|
| 26 |
+
## Dataset YAML
|
| 27 |
+
|
| 28 |
+
A YAML (Yet Another Markup Language) file is used to define the dataset configuration. It contains information about the dataset's paths, classes, and other relevant information. In the case of the COCO8 dataset, the `coco8.yaml` file is maintained at [https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/coco8.yaml](https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/coco8.yaml).
|
| 29 |
+
|
| 30 |
+
!!! example "ultralytics/cfg/datasets/coco8.yaml"
|
| 31 |
+
|
| 32 |
+
```yaml
|
| 33 |
+
--8<-- "ultralytics/cfg/datasets/coco8.yaml"
|
| 34 |
+
```
|
| 35 |
+
|
| 36 |
+
## Usage
|
| 37 |
+
|
| 38 |
+
To train a YOLOv8n model on the COCO8 dataset for 100 epochs with an image size of 640, you can use the following code snippets. For a comprehensive list of available arguments, refer to the model [Training](../../modes/train.md) page.
|
| 39 |
+
|
| 40 |
+
!!! example "Train Example"
|
| 41 |
+
|
| 42 |
+
=== "Python"
|
| 43 |
+
|
| 44 |
+
```python
|
| 45 |
+
from ultralytics import YOLO
|
| 46 |
+
|
| 47 |
+
# Load a model
|
| 48 |
+
model = YOLO("yolov8n.pt") # load a pretrained model (recommended for training)
|
| 49 |
+
|
| 50 |
+
# Train the model
|
| 51 |
+
results = model.train(data="coco8.yaml", epochs=100, imgsz=640)
|
| 52 |
+
```
|
| 53 |
+
|
| 54 |
+
=== "CLI"
|
| 55 |
+
|
| 56 |
+
```bash
|
| 57 |
+
# Start training from a pretrained *.pt model
|
| 58 |
+
yolo detect train data=coco8.yaml model=yolov8n.pt epochs=100 imgsz=640
|
| 59 |
+
```
|
| 60 |
+
|
| 61 |
+
## Sample Images and Annotations
|
| 62 |
+
|
| 63 |
+
Here are some examples of images from the COCO8 dataset, along with their corresponding annotations:
|
| 64 |
+
|
| 65 |
+
<img src="https://github.com/ultralytics/docs/releases/download/0/mosaiced-training-batch-1.avif" alt="Dataset sample image" width="800">
|
| 66 |
+
|
| 67 |
+
- **Mosaiced Image**: This image demonstrates a training batch composed of mosaiced dataset images. Mosaicing is a technique used during training that combines multiple images into a single image to increase the variety of objects and scenes within each training batch. This helps improve the model's ability to generalize to different object sizes, aspect ratios, and contexts.
|
| 68 |
+
|
| 69 |
+
The example showcases the variety and complexity of the images in the COCO8 dataset and the benefits of using mosaicing during the training process.
|
| 70 |
+
|
| 71 |
+
## Citations and Acknowledgments
|
| 72 |
+
|
| 73 |
+
If you use the COCO dataset in your research or development work, please cite the following paper:
|
| 74 |
+
|
| 75 |
+
!!! quote ""
|
| 76 |
+
|
| 77 |
+
=== "BibTeX"
|
| 78 |
+
|
| 79 |
+
```bibtex
|
| 80 |
+
@misc{lin2015microsoft,
|
| 81 |
+
title={Microsoft COCO: Common Objects in Context},
|
| 82 |
+
author={Tsung-Yi Lin and Michael Maire and Serge Belongie and Lubomir Bourdev and Ross Girshick and James Hays and Pietro Perona and Deva Ramanan and C. Lawrence Zitnick and Piotr Dollár},
|
| 83 |
+
year={2015},
|
| 84 |
+
eprint={1405.0312},
|
| 85 |
+
archivePrefix={arXiv},
|
| 86 |
+
primaryClass={cs.CV}
|
| 87 |
+
}
|
| 88 |
+
```
|
| 89 |
+
|
| 90 |
+
We would like to acknowledge the COCO Consortium for creating and maintaining this valuable resource for the computer vision community. For more information about the COCO dataset and its creators, visit the [COCO dataset website](https://cocodataset.org/#home).
|
| 91 |
+
|
| 92 |
+
## FAQ
|
| 93 |
+
|
| 94 |
+
### What is the Ultralytics COCO8 dataset used for?
|
| 95 |
+
|
| 96 |
+
The Ultralytics COCO8 dataset is a compact yet versatile object detection dataset consisting of the first 8 images from the COCO train 2017 set, with 4 images for training and 4 for validation. It is designed for testing and debugging object detection models and experimentation with new detection approaches. Despite its small size, COCO8 offers enough diversity to act as a sanity check for your training pipelines before deploying larger datasets. For more details, view the [COCO8 dataset](https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/coco8.yaml).
|
| 97 |
+
|
| 98 |
+
### How do I train a YOLOv8 model using the COCO8 dataset?
|
| 99 |
+
|
| 100 |
+
To train a YOLOv8 model using the COCO8 dataset, you can employ either Python or CLI commands. Here's how you can start:
|
| 101 |
+
|
| 102 |
+
!!! example "Train Example"
|
| 103 |
+
|
| 104 |
+
=== "Python"
|
| 105 |
+
|
| 106 |
+
```python
|
| 107 |
+
from ultralytics import YOLO
|
| 108 |
+
|
| 109 |
+
# Load a model
|
| 110 |
+
model = YOLO("yolov8n.pt") # load a pretrained model (recommended for training)
|
| 111 |
+
|
| 112 |
+
# Train the model
|
| 113 |
+
results = model.train(data="coco8.yaml", epochs=100, imgsz=640)
|
| 114 |
+
```
|
| 115 |
+
|
| 116 |
+
=== "CLI"
|
| 117 |
+
|
| 118 |
+
```bash
|
| 119 |
+
# Start training from a pretrained *.pt model
|
| 120 |
+
yolo detect train data=coco8.yaml model=yolov8n.pt epochs=100 imgsz=640
|
| 121 |
+
```
|
| 122 |
+
|
| 123 |
+
For a comprehensive list of available arguments, refer to the model [Training](../../modes/train.md) page.
|
| 124 |
+
|
| 125 |
+
### Why should I use Ultralytics HUB for managing my COCO8 training?
|
| 126 |
+
|
| 127 |
+
Ultralytics HUB is an all-in-one web tool designed to simplify the training and deployment of YOLO models, including the Ultralytics YOLOv8 models on the COCO8 dataset. It offers cloud training, real-time tracking, and seamless dataset management. HUB allows you to start training with a single click and avoids the complexities of manual setups. Discover more about [Ultralytics HUB](https://hub.ultralytics.com/) and its benefits.
|
| 128 |
+
|
| 129 |
+
### What are the benefits of using mosaic augmentation in training with the COCO8 dataset?
|
| 130 |
+
|
| 131 |
+
Mosaic augmentation, demonstrated in the COCO8 dataset, combines multiple images into a single image during training. This technique increases the variety of objects and scenes in each training batch, improving the model's ability to generalize across different object sizes, aspect ratios, and contexts. This results in a more robust object detection model. For more details, refer to the [training guide](#usage).
|
| 132 |
+
|
| 133 |
+
### How can I validate my YOLOv8 model trained on the COCO8 dataset?
|
| 134 |
+
|
| 135 |
+
Validation of your YOLOv8 model trained on the COCO8 dataset can be performed using the model's validation commands. You can invoke the validation mode via CLI or Python script to evaluate the model's performance using precise metrics. For detailed instructions, visit the [Validation](../../modes/val.md) page.
|
ultralytics/docs/en/datasets/detect/globalwheat2020.md
ADDED
|
@@ -0,0 +1,145 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
comments: true
|
| 3 |
+
description: Explore the Global Wheat Head Dataset to develop accurate wheat head detection models. Includes training images, annotations, and usage for crop management.
|
| 4 |
+
keywords: Global Wheat Head Dataset, wheat head detection, wheat phenotyping, crop management, deep learning, object detection, training datasets
|
| 5 |
+
---
|
| 6 |
+
|
| 7 |
+
# Global Wheat Head Dataset
|
| 8 |
+
|
| 9 |
+
The [Global Wheat Head Dataset](https://www.global-wheat.com/) is a collection of images designed to support the development of accurate wheat head detection models for applications in wheat phenotyping and crop management. Wheat heads, also known as spikes, are the grain-bearing parts of the wheat plant. Accurate estimation of wheat head density and size is essential for assessing crop health, maturity, and yield potential. The dataset, created by a collaboration of nine research institutes from seven countries, covers multiple growing regions to ensure models generalize well across different environments.
|
| 10 |
+
|
| 11 |
+
## Key Features
|
| 12 |
+
|
| 13 |
+
- The dataset contains over 3,000 training images from Europe (France, UK, Switzerland) and North America (Canada).
|
| 14 |
+
- It includes approximately 1,000 test images from Australia, Japan, and China.
|
| 15 |
+
- Images are outdoor field images, capturing the natural variability in wheat head appearances.
|
| 16 |
+
- Annotations include wheat head bounding boxes to support object detection tasks.
|
| 17 |
+
|
| 18 |
+
## Dataset Structure
|
| 19 |
+
|
| 20 |
+
The Global Wheat Head Dataset is organized into two main subsets:
|
| 21 |
+
|
| 22 |
+
1. **Training Set**: This subset contains over 3,000 images from Europe and North America. The images are labeled with wheat head bounding boxes, providing ground truth for training object detection models.
|
| 23 |
+
2. **Test Set**: This subset consists of approximately 1,000 images from Australia, Japan, and China. These images are used for evaluating the performance of trained models on unseen genotypes, environments, and observational conditions.
|
| 24 |
+
|
| 25 |
+
## Applications
|
| 26 |
+
|
| 27 |
+
The Global Wheat Head Dataset is widely used for training and evaluating deep learning models in wheat head detection tasks. The dataset's diverse set of images, capturing a wide range of appearances, environments, and conditions, make it a valuable resource for researchers and practitioners in the field of plant phenotyping and crop management.
|
| 28 |
+
|
| 29 |
+
## Dataset YAML
|
| 30 |
+
|
| 31 |
+
A YAML (Yet Another Markup Language) file is used to define the dataset configuration. It contains information about the dataset's paths, classes, and other relevant information. For the case of the Global Wheat Head Dataset, the `GlobalWheat2020.yaml` file is maintained at [https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/GlobalWheat2020.yaml](https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/GlobalWheat2020.yaml).
|
| 32 |
+
|
| 33 |
+
!!! example "ultralytics/cfg/datasets/GlobalWheat2020.yaml"
|
| 34 |
+
|
| 35 |
+
```yaml
|
| 36 |
+
--8<-- "ultralytics/cfg/datasets/GlobalWheat2020.yaml"
|
| 37 |
+
```
|
| 38 |
+
|
| 39 |
+
## Usage
|
| 40 |
+
|
| 41 |
+
To train a YOLOv8n model on the Global Wheat Head Dataset for 100 epochs with an image size of 640, you can use the following code snippets. For a comprehensive list of available arguments, refer to the model [Training](../../modes/train.md) page.
|
| 42 |
+
|
| 43 |
+
!!! example "Train Example"
|
| 44 |
+
|
| 45 |
+
=== "Python"
|
| 46 |
+
|
| 47 |
+
```python
|
| 48 |
+
from ultralytics import YOLO
|
| 49 |
+
|
| 50 |
+
# Load a model
|
| 51 |
+
model = YOLO("yolov8n.pt") # load a pretrained model (recommended for training)
|
| 52 |
+
|
| 53 |
+
# Train the model
|
| 54 |
+
results = model.train(data="GlobalWheat2020.yaml", epochs=100, imgsz=640)
|
| 55 |
+
```
|
| 56 |
+
|
| 57 |
+
=== "CLI"
|
| 58 |
+
|
| 59 |
+
```bash
|
| 60 |
+
# Start training from a pretrained *.pt model
|
| 61 |
+
yolo detect train data=GlobalWheat2020.yaml model=yolov8n.pt epochs=100 imgsz=640
|
| 62 |
+
```
|
| 63 |
+
|
| 64 |
+
## Sample Data and Annotations
|
| 65 |
+
|
| 66 |
+
The Global Wheat Head Dataset contains a diverse set of outdoor field images, capturing the natural variability in wheat head appearances, environments, and conditions. Here are some examples of data from the dataset, along with their corresponding annotations:
|
| 67 |
+
|
| 68 |
+

|
| 69 |
+
|
| 70 |
+
- **Wheat Head Detection**: This image demonstrates an example of wheat head detection, where wheat heads are annotated with bounding boxes. The dataset provides a variety of images to facilitate the development of models for this task.
|
| 71 |
+
|
| 72 |
+
The example showcases the variety and complexity of the data in the Global Wheat Head Dataset and highlights the importance of accurate wheat head detection for applications in wheat phenotyping and crop management.
|
| 73 |
+
|
| 74 |
+
## Citations and Acknowledgments
|
| 75 |
+
|
| 76 |
+
If you use the Global Wheat Head Dataset in your research or development work, please cite the following paper:
|
| 77 |
+
|
| 78 |
+
!!! quote ""
|
| 79 |
+
|
| 80 |
+
=== "BibTeX"
|
| 81 |
+
|
| 82 |
+
```bibtex
|
| 83 |
+
@article{david2020global,
|
| 84 |
+
title={Global Wheat Head Detection (GWHD) Dataset: A Large and Diverse Dataset of High-Resolution RGB-Labelled Images to Develop and Benchmark Wheat Head Detection Methods},
|
| 85 |
+
author={David, Etienne and Madec, Simon and Sadeghi-Tehran, Pouria and Aasen, Helge and Zheng, Bangyou and Liu, Shouyang and Kirchgessner, Norbert and Ishikawa, Goro and Nagasawa, Koichi and Badhon, Minhajul and others},
|
| 86 |
+
journal={arXiv preprint arXiv:2005.02162},
|
| 87 |
+
year={2020}
|
| 88 |
+
}
|
| 89 |
+
```
|
| 90 |
+
|
| 91 |
+
We would like to acknowledge the researchers and institutions that contributed to the creation and maintenance of the Global Wheat Head Dataset as a valuable resource for the plant phenotyping and crop management research community. For more information about the dataset and its creators, visit the [Global Wheat Head Dataset website](https://www.global-wheat.com/).
|
| 92 |
+
|
| 93 |
+
## FAQ
|
| 94 |
+
|
| 95 |
+
### What is the Global Wheat Head Dataset used for?
|
| 96 |
+
|
| 97 |
+
The Global Wheat Head Dataset is primarily used for developing and training deep learning models aimed at wheat head detection. This is crucial for applications in wheat phenotyping and crop management, allowing for more accurate estimations of wheat head density, size, and overall crop yield potential. Accurate detection methods help in assessing crop health and maturity, essential for efficient crop management.
|
| 98 |
+
|
| 99 |
+
### How do I train a YOLOv8n model on the Global Wheat Head Dataset?
|
| 100 |
+
|
| 101 |
+
To train a YOLOv8n model on the Global Wheat Head Dataset, you can use the following code snippets. Make sure you have the `GlobalWheat2020.yaml` configuration file specifying dataset paths and classes:
|
| 102 |
+
|
| 103 |
+
!!! example "Train Example"
|
| 104 |
+
|
| 105 |
+
=== "Python"
|
| 106 |
+
|
| 107 |
+
```python
|
| 108 |
+
from ultralytics import YOLO
|
| 109 |
+
|
| 110 |
+
# Load a pre-trained model (recommended for training)
|
| 111 |
+
model = YOLO("yolov8n.pt")
|
| 112 |
+
|
| 113 |
+
# Train the model
|
| 114 |
+
results = model.train(data="GlobalWheat2020.yaml", epochs=100, imgsz=640)
|
| 115 |
+
```
|
| 116 |
+
|
| 117 |
+
=== "CLI"
|
| 118 |
+
|
| 119 |
+
```bash
|
| 120 |
+
# Start training from a pretrained *.pt model
|
| 121 |
+
yolo detect train data=GlobalWheat2020.yaml model=yolov8n.pt epochs=100 imgsz=640
|
| 122 |
+
```
|
| 123 |
+
|
| 124 |
+
For a comprehensive list of available arguments, refer to the model [Training](../../modes/train.md) page.
|
| 125 |
+
|
| 126 |
+
### What are the key features of the Global Wheat Head Dataset?
|
| 127 |
+
|
| 128 |
+
Key features of the Global Wheat Head Dataset include:
|
| 129 |
+
|
| 130 |
+
- Over 3,000 training images from Europe (France, UK, Switzerland) and North America (Canada).
|
| 131 |
+
- Approximately 1,000 test images from Australia, Japan, and China.
|
| 132 |
+
- High variability in wheat head appearances due to different growing environments.
|
| 133 |
+
- Detailed annotations with wheat head bounding boxes to aid object detection models.
|
| 134 |
+
|
| 135 |
+
These features facilitate the development of robust models capable of generalization across multiple regions.
|
| 136 |
+
|
| 137 |
+
### Where can I find the configuration YAML file for the Global Wheat Head Dataset?
|
| 138 |
+
|
| 139 |
+
The configuration YAML file for the Global Wheat Head Dataset, named `GlobalWheat2020.yaml`, is available on GitHub. You can access it at this [link](https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/GlobalWheat2020.yaml). This file contains necessary information about dataset paths, classes, and other configuration details needed for model training in Ultralytics YOLO.
|
| 140 |
+
|
| 141 |
+
### Why is wheat head detection important in crop management?
|
| 142 |
+
|
| 143 |
+
Wheat head detection is critical in crop management because it enables accurate estimation of wheat head density and size, which are essential for evaluating crop health, maturity, and yield potential. By leveraging deep learning models trained on datasets like the Global Wheat Head Dataset, farmers and researchers can better monitor and manage crops, leading to improved productivity and optimized resource use in agricultural practices. This technological advancement supports sustainable agriculture and food security initiatives.
|
| 144 |
+
|
| 145 |
+
For more information on applications of AI in agriculture, visit [AI in Agriculture](https://www.ultralytics.com/solutions/ai-in-agriculture).
|
ultralytics/docs/en/datasets/detect/index.md
ADDED
|
@@ -0,0 +1,188 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
comments: true
|
| 3 |
+
description: Learn about dataset formats compatible with Ultralytics YOLO for robust object detection. Explore supported datasets and learn how to convert formats.
|
| 4 |
+
keywords: Ultralytics, YOLO, object detection datasets, dataset formats, COCO, dataset conversion, training datasets
|
| 5 |
+
---
|
| 6 |
+
|
| 7 |
+
# Object Detection Datasets Overview
|
| 8 |
+
|
| 9 |
+
Training a robust and accurate object detection model requires a comprehensive dataset. This guide introduces various formats of datasets that are compatible with the Ultralytics YOLO model and provides insights into their structure, usage, and how to convert between different formats.
|
| 10 |
+
|
| 11 |
+
## Supported Dataset Formats
|
| 12 |
+
|
| 13 |
+
### Ultralytics YOLO format
|
| 14 |
+
|
| 15 |
+
The Ultralytics YOLO format is a dataset configuration format that allows you to define the dataset root directory, the relative paths to training/validation/testing image directories or `*.txt` files containing image paths, and a dictionary of class names. Here is an example:
|
| 16 |
+
|
| 17 |
+
```yaml
|
| 18 |
+
# Train/val/test sets as 1) dir: path/to/imgs, 2) file: path/to/imgs.txt, or 3) list: [path/to/imgs1, path/to/imgs2, ..]
|
| 19 |
+
path: ../datasets/coco8 # dataset root dir
|
| 20 |
+
train: images/train # train images (relative to 'path') 4 images
|
| 21 |
+
val: images/val # val images (relative to 'path') 4 images
|
| 22 |
+
test: # test images (optional)
|
| 23 |
+
|
| 24 |
+
# Classes (80 COCO classes)
|
| 25 |
+
names:
|
| 26 |
+
0: person
|
| 27 |
+
1: bicycle
|
| 28 |
+
2: car
|
| 29 |
+
# ...
|
| 30 |
+
77: teddy bear
|
| 31 |
+
78: hair drier
|
| 32 |
+
79: toothbrush
|
| 33 |
+
```
|
| 34 |
+
|
| 35 |
+
Labels for this format should be exported to YOLO format with one `*.txt` file per image. If there are no objects in an image, no `*.txt` file is required. The `*.txt` file should be formatted with one row per object in `class x_center y_center width height` format. Box coordinates must be in **normalized xywh** format (from 0 to 1). If your boxes are in pixels, you should divide `x_center` and `width` by image width, and `y_center` and `height` by image height. Class numbers should be zero-indexed (start with 0).
|
| 36 |
+
|
| 37 |
+
<p align="center"><img width="750" src="https://github.com/ultralytics/docs/releases/download/0/two-persons-tie.avif" alt="Example labelled image"></p>
|
| 38 |
+
|
| 39 |
+
The label file corresponding to the above image contains 2 persons (class `0`) and a tie (class `27`):
|
| 40 |
+
|
| 41 |
+
<p align="center"><img width="428" src="https://github.com/ultralytics/docs/releases/download/0/two-persons-tie-1.avif" alt="Example label file"></p>
|
| 42 |
+
|
| 43 |
+
When using the Ultralytics YOLO format, organize your training and validation images and labels as shown in the [COCO8 dataset](coco8.md) example below.
|
| 44 |
+
|
| 45 |
+
<p align="center"><img width="800" src="https://github.com/ultralytics/docs/releases/download/0/two-persons-tie-2.avif" alt="Example dataset directory structure"></p>
|
| 46 |
+
|
| 47 |
+
## Usage
|
| 48 |
+
|
| 49 |
+
Here's how you can use these formats to train your model:
|
| 50 |
+
|
| 51 |
+
!!! example
|
| 52 |
+
|
| 53 |
+
=== "Python"
|
| 54 |
+
|
| 55 |
+
```python
|
| 56 |
+
from ultralytics import YOLO
|
| 57 |
+
|
| 58 |
+
# Load a model
|
| 59 |
+
model = YOLO("yolov8n.pt") # load a pretrained model (recommended for training)
|
| 60 |
+
|
| 61 |
+
# Train the model
|
| 62 |
+
results = model.train(data="coco8.yaml", epochs=100, imgsz=640)
|
| 63 |
+
```
|
| 64 |
+
|
| 65 |
+
=== "CLI"
|
| 66 |
+
|
| 67 |
+
```bash
|
| 68 |
+
# Start training from a pretrained *.pt model
|
| 69 |
+
yolo detect train data=coco8.yaml model=yolov8n.pt epochs=100 imgsz=640
|
| 70 |
+
```
|
| 71 |
+
|
| 72 |
+
## Supported Datasets
|
| 73 |
+
|
| 74 |
+
Here is a list of the supported datasets and a brief description for each:
|
| 75 |
+
|
| 76 |
+
- [Argoverse](argoverse.md): A dataset containing 3D tracking and motion forecasting data from urban environments with rich annotations.
|
| 77 |
+
- [COCO](coco.md): Common Objects in Context (COCO) is a large-scale object detection, segmentation, and captioning dataset with 80 object categories.
|
| 78 |
+
- [LVIS](lvis.md): A large-scale object detection, segmentation, and captioning dataset with 1203 object categories.
|
| 79 |
+
- [COCO8](coco8.md): A smaller subset of the first 4 images from COCO train and COCO val, suitable for quick tests.
|
| 80 |
+
- [COCO128](coco.md): A smaller subset of the first 128 images from COCO train and COCO val, suitable for tests.
|
| 81 |
+
- [Global Wheat 2020](globalwheat2020.md): A dataset containing images of wheat heads for the Global Wheat Challenge 2020.
|
| 82 |
+
- [Objects365](objects365.md): A high-quality, large-scale dataset for object detection with 365 object categories and over 600K annotated images.
|
| 83 |
+
- [OpenImagesV7](open-images-v7.md): A comprehensive dataset by Google with 1.7M train images and 42k validation images.
|
| 84 |
+
- [SKU-110K](sku-110k.md): A dataset featuring dense object detection in retail environments with over 11K images and 1.7 million bounding boxes.
|
| 85 |
+
- [VisDrone](visdrone.md): A dataset containing object detection and multi-object tracking data from drone-captured imagery with over 10K images and video sequences.
|
| 86 |
+
- [VOC](voc.md): The Pascal Visual Object Classes (VOC) dataset for object detection and segmentation with 20 object classes and over 11K images.
|
| 87 |
+
- [xView](xview.md): A dataset for object detection in overhead imagery with 60 object categories and over 1 million annotated objects.
|
| 88 |
+
- [Roboflow 100](roboflow-100.md): A diverse object detection benchmark with 100 datasets spanning seven imagery domains for comprehensive model evaluation.
|
| 89 |
+
- [Brain-tumor](brain-tumor.md): A dataset for detecting brain tumors includes MRI or CT scan images with details on tumor presence, location, and characteristics.
|
| 90 |
+
- [African-wildlife](african-wildlife.md): A dataset featuring images of African wildlife, including buffalo, elephant, rhino, and zebras.
|
| 91 |
+
- [Signature](signature.md): A dataset featuring images of various documents with annotated signatures, supporting document verification and fraud detection research.
|
| 92 |
+
|
| 93 |
+
### Adding your own dataset
|
| 94 |
+
|
| 95 |
+
If you have your own dataset and would like to use it for training detection models with Ultralytics YOLO format, ensure that it follows the format specified above under "Ultralytics YOLO format". Convert your annotations to the required format and specify the paths, number of classes, and class names in the YAML configuration file.
|
| 96 |
+
|
| 97 |
+
## Port or Convert Label Formats
|
| 98 |
+
|
| 99 |
+
### COCO Dataset Format to YOLO Format
|
| 100 |
+
|
| 101 |
+
You can easily convert labels from the popular COCO dataset format to the YOLO format using the following code snippet:
|
| 102 |
+
|
| 103 |
+
!!! example
|
| 104 |
+
|
| 105 |
+
=== "Python"
|
| 106 |
+
|
| 107 |
+
```python
|
| 108 |
+
from ultralytics.data.converter import convert_coco
|
| 109 |
+
|
| 110 |
+
convert_coco(labels_dir="path/to/coco/annotations/")
|
| 111 |
+
```
|
| 112 |
+
|
| 113 |
+
This conversion tool can be used to convert the COCO dataset or any dataset in the COCO format to the Ultralytics YOLO format.
|
| 114 |
+
|
| 115 |
+
Remember to double-check if the dataset you want to use is compatible with your model and follows the necessary format conventions. Properly formatted datasets are crucial for training successful object detection models.
|
| 116 |
+
|
| 117 |
+
## FAQ
|
| 118 |
+
|
| 119 |
+
### What is the Ultralytics YOLO dataset format and how to structure it?
|
| 120 |
+
|
| 121 |
+
The Ultralytics YOLO format is a structured configuration for defining datasets in your training projects. It involves setting paths to your training, validation, and testing images and corresponding labels. For example:
|
| 122 |
+
|
| 123 |
+
```yaml
|
| 124 |
+
path: ../datasets/coco8 # dataset root directory
|
| 125 |
+
train: images/train # training images (relative to 'path')
|
| 126 |
+
val: images/val # validation images (relative to 'path')
|
| 127 |
+
test: # optional test images
|
| 128 |
+
names:
|
| 129 |
+
0: person
|
| 130 |
+
1: bicycle
|
| 131 |
+
2: car
|
| 132 |
+
# ...
|
| 133 |
+
```
|
| 134 |
+
|
| 135 |
+
Labels are saved in `*.txt` files with one file per image, formatted as `class x_center y_center width height` with normalized coordinates. For a detailed guide, see the [COCO8 dataset example](coco8.md).
|
| 136 |
+
|
| 137 |
+
### How do I convert a COCO dataset to the YOLO format?
|
| 138 |
+
|
| 139 |
+
You can convert a COCO dataset to the YOLO format using the Ultralytics conversion tools. Here's a quick method:
|
| 140 |
+
|
| 141 |
+
```python
|
| 142 |
+
from ultralytics.data.converter import convert_coco
|
| 143 |
+
|
| 144 |
+
convert_coco(labels_dir="path/to/coco/annotations/")
|
| 145 |
+
```
|
| 146 |
+
|
| 147 |
+
This code will convert your COCO annotations to YOLO format, enabling seamless integration with Ultralytics YOLO models. For additional details, visit the [Port or Convert Label Formats](#port-or-convert-label-formats) section.
|
| 148 |
+
|
| 149 |
+
### Which datasets are supported by Ultralytics YOLO for object detection?
|
| 150 |
+
|
| 151 |
+
Ultralytics YOLO supports a wide range of datasets, including:
|
| 152 |
+
|
| 153 |
+
- [Argoverse](argoverse.md)
|
| 154 |
+
- [COCO](coco.md)
|
| 155 |
+
- [LVIS](lvis.md)
|
| 156 |
+
- [COCO8](coco8.md)
|
| 157 |
+
- [Global Wheat 2020](globalwheat2020.md)
|
| 158 |
+
- [Objects365](objects365.md)
|
| 159 |
+
- [OpenImagesV7](open-images-v7.md)
|
| 160 |
+
|
| 161 |
+
Each dataset page provides detailed information on the structure and usage tailored for efficient YOLOv8 training. Explore the full list in the [Supported Datasets](#supported-datasets) section.
|
| 162 |
+
|
| 163 |
+
### How do I start training a YOLOv8 model using my dataset?
|
| 164 |
+
|
| 165 |
+
To start training a YOLOv8 model, ensure your dataset is formatted correctly and the paths are defined in a YAML file. Use the following script to begin training:
|
| 166 |
+
|
| 167 |
+
!!! example
|
| 168 |
+
|
| 169 |
+
=== "Python"
|
| 170 |
+
|
| 171 |
+
```python
|
| 172 |
+
from ultralytics import YOLO
|
| 173 |
+
|
| 174 |
+
model = YOLO("yolov8n.pt") # Load a pretrained model
|
| 175 |
+
results = model.train(data="path/to/your_dataset.yaml", epochs=100, imgsz=640)
|
| 176 |
+
```
|
| 177 |
+
|
| 178 |
+
=== "CLI"
|
| 179 |
+
|
| 180 |
+
```bash
|
| 181 |
+
yolo detect train data=path/to/your_dataset.yaml model=yolov8n.pt epochs=100 imgsz=640
|
| 182 |
+
```
|
| 183 |
+
|
| 184 |
+
Refer to the [Usage](#usage) section for more details on utilizing different modes, including CLI commands.
|
| 185 |
+
|
| 186 |
+
### Where can I find practical examples of using Ultralytics YOLO for object detection?
|
| 187 |
+
|
| 188 |
+
Ultralytics provides numerous examples and practical guides for using YOLOv8 in diverse applications. For a comprehensive overview, visit the [Ultralytics Blog](https://www.ultralytics.com/blog) where you can find case studies, detailed tutorials, and community stories showcasing object detection, segmentation, and more with YOLOv8. For specific examples, check the [Usage](../../modes/predict.md) section in the documentation.
|
ultralytics/docs/en/datasets/detect/lvis.md
ADDED
|
@@ -0,0 +1,159 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
comments: true
|
| 3 |
+
description: Discover the LVIS dataset by Facebook AI Research, a benchmark for object detection and instance segmentation with a large, diverse vocabulary. Learn how to utilize it.
|
| 4 |
+
keywords: LVIS dataset, object detection, instance segmentation, Facebook AI Research, YOLO, computer vision, model training, LVIS examples
|
| 5 |
+
---
|
| 6 |
+
|
| 7 |
+
# LVIS Dataset
|
| 8 |
+
|
| 9 |
+
The [LVIS dataset](https://www.lvisdataset.org/) is a large-scale, fine-grained vocabulary-level annotation dataset developed and released by Facebook AI Research (FAIR). It is primarily used as a research benchmark for object detection and instance segmentation with a large vocabulary of categories, aiming to drive further advancements in computer vision field.
|
| 10 |
+
|
| 11 |
+
<p align="center">
|
| 12 |
+
<br>
|
| 13 |
+
<iframe loading="lazy" width="720" height="405" src="https://www.youtube.com/embed/cfTKj96TjSE"
|
| 14 |
+
title="YouTube video player" frameborder="0"
|
| 15 |
+
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share"
|
| 16 |
+
allowfullscreen>
|
| 17 |
+
</iframe>
|
| 18 |
+
<br>
|
| 19 |
+
<strong>Watch:</strong> YOLO World training workflow with LVIS dataset
|
| 20 |
+
</p>
|
| 21 |
+
|
| 22 |
+
<p align="center">
|
| 23 |
+
<img width="640" src="https://github.com/ultralytics/docs/releases/download/0/lvis-dataset-example-images.avif" alt="LVIS Dataset example images">
|
| 24 |
+
</p>
|
| 25 |
+
|
| 26 |
+
## Key Features
|
| 27 |
+
|
| 28 |
+
- LVIS contains 160k images and 2M instance annotations for object detection, segmentation, and captioning tasks.
|
| 29 |
+
- The dataset comprises 1203 object categories, including common objects like cars, bicycles, and animals, as well as more specific categories such as umbrellas, handbags, and sports equipment.
|
| 30 |
+
- Annotations include object bounding boxes, segmentation masks, and captions for each image.
|
| 31 |
+
- LVIS provides standardized evaluation metrics like mean Average Precision (mAP) for object detection, and mean Average Recall (mAR) for segmentation tasks, making it suitable for comparing model performance.
|
| 32 |
+
- LVIS uses exactly the same images as [COCO](./coco.md) dataset, but with different splits and different annotations.
|
| 33 |
+
|
| 34 |
+
## Dataset Structure
|
| 35 |
+
|
| 36 |
+
The LVIS dataset is split into three subsets:
|
| 37 |
+
|
| 38 |
+
1. **Train**: This subset contains 100k images for training object detection, segmentation, and captioning models.
|
| 39 |
+
2. **Val**: This subset has 20k images used for validation purposes during model training.
|
| 40 |
+
3. **Minival**: This subset is exactly the same as COCO val2017 set which has 5k images used for validation purposes during model training.
|
| 41 |
+
4. **Test**: This subset consists of 20k images used for testing and benchmarking the trained models. Ground truth annotations for this subset are not publicly available, and the results are submitted to the [LVIS evaluation server](https://eval.ai/web/challenges/challenge-page/675/overview) for performance evaluation.
|
| 42 |
+
|
| 43 |
+
## Applications
|
| 44 |
+
|
| 45 |
+
The LVIS dataset is widely used for training and evaluating deep learning models in object detection (such as YOLO, Faster R-CNN, and SSD), instance segmentation (such as Mask R-CNN). The dataset's diverse set of object categories, large number of annotated images, and standardized evaluation metrics make it an essential resource for computer vision researchers and practitioners.
|
| 46 |
+
|
| 47 |
+
## Dataset YAML
|
| 48 |
+
|
| 49 |
+
A YAML (Yet Another Markup Language) file is used to define the dataset configuration. It contains information about the dataset's paths, classes, and other relevant information. In the case of the LVIS dataset, the `lvis.yaml` file is maintained at [https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/lvis.yaml](https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/lvis.yaml).
|
| 50 |
+
|
| 51 |
+
!!! example "ultralytics/cfg/datasets/lvis.yaml"
|
| 52 |
+
|
| 53 |
+
```yaml
|
| 54 |
+
--8<-- "ultralytics/cfg/datasets/lvis.yaml"
|
| 55 |
+
```
|
| 56 |
+
|
| 57 |
+
## Usage
|
| 58 |
+
|
| 59 |
+
To train a YOLOv8n model on the LVIS dataset for 100 epochs with an image size of 640, you can use the following code snippets. For a comprehensive list of available arguments, refer to the model [Training](../../modes/train.md) page.
|
| 60 |
+
|
| 61 |
+
!!! example "Train Example"
|
| 62 |
+
|
| 63 |
+
=== "Python"
|
| 64 |
+
|
| 65 |
+
```python
|
| 66 |
+
from ultralytics import YOLO
|
| 67 |
+
|
| 68 |
+
# Load a model
|
| 69 |
+
model = YOLO("yolov8n.pt") # load a pretrained model (recommended for training)
|
| 70 |
+
|
| 71 |
+
# Train the model
|
| 72 |
+
results = model.train(data="lvis.yaml", epochs=100, imgsz=640)
|
| 73 |
+
```
|
| 74 |
+
|
| 75 |
+
=== "CLI"
|
| 76 |
+
|
| 77 |
+
```bash
|
| 78 |
+
# Start training from a pretrained *.pt model
|
| 79 |
+
yolo detect train data=lvis.yaml model=yolov8n.pt epochs=100 imgsz=640
|
| 80 |
+
```
|
| 81 |
+
|
| 82 |
+
## Sample Images and Annotations
|
| 83 |
+
|
| 84 |
+
The LVIS dataset contains a diverse set of images with various object categories and complex scenes. Here are some examples of images from the dataset, along with their corresponding annotations:
|
| 85 |
+
|
| 86 |
+

|
| 87 |
+
|
| 88 |
+
- **Mosaiced Image**: This image demonstrates a training batch composed of mosaiced dataset images. Mosaicing is a technique used during training that combines multiple images into a single image to increase the variety of objects and scenes within each training batch. This helps improve the model's ability to generalize to different object sizes, aspect ratios, and contexts.
|
| 89 |
+
|
| 90 |
+
The example showcases the variety and complexity of the images in the LVIS dataset and the benefits of using mosaicing during the training process.
|
| 91 |
+
|
| 92 |
+
## Citations and Acknowledgments
|
| 93 |
+
|
| 94 |
+
If you use the LVIS dataset in your research or development work, please cite the following paper:
|
| 95 |
+
|
| 96 |
+
!!! quote ""
|
| 97 |
+
|
| 98 |
+
=== "BibTeX"
|
| 99 |
+
|
| 100 |
+
```bibtex
|
| 101 |
+
@inproceedings{gupta2019lvis,
|
| 102 |
+
title={LVIS: A Dataset for Large Vocabulary Instance Segmentation},
|
| 103 |
+
author={Gupta, Agrim and Dollar, Piotr and Girshick, Ross},
|
| 104 |
+
booktitle={Proceedings of the {IEEE} Conference on Computer Vision and Pattern Recognition},
|
| 105 |
+
year={2019}
|
| 106 |
+
}
|
| 107 |
+
```
|
| 108 |
+
|
| 109 |
+
We would like to acknowledge the LVIS Consortium for creating and maintaining this valuable resource for the computer vision community. For more information about the LVIS dataset and its creators, visit the [LVIS dataset website](https://www.lvisdataset.org/).
|
| 110 |
+
|
| 111 |
+
## FAQ
|
| 112 |
+
|
| 113 |
+
### What is the LVIS dataset, and how is it used in computer vision?
|
| 114 |
+
|
| 115 |
+
The [LVIS dataset](https://www.lvisdataset.org/) is a large-scale dataset with fine-grained vocabulary-level annotations developed by Facebook AI Research (FAIR). It is primarily used for object detection and instance segmentation, featuring over 1203 object categories and 2 million instance annotations. Researchers and practitioners use it to train and benchmark models like Ultralytics YOLO for advanced computer vision tasks. The dataset's extensive size and diversity make it an essential resource for pushing the boundaries of model performance in detection and segmentation.
|
| 116 |
+
|
| 117 |
+
### How can I train a YOLOv8n model using the LVIS dataset?
|
| 118 |
+
|
| 119 |
+
To train a YOLOv8n model on the LVIS dataset for 100 epochs with an image size of 640, follow the example below. This process utilizes Ultralytics' framework, which offers comprehensive training features.
|
| 120 |
+
|
| 121 |
+
!!! example "Train Example"
|
| 122 |
+
|
| 123 |
+
=== "Python"
|
| 124 |
+
|
| 125 |
+
```python
|
| 126 |
+
from ultralytics import YOLO
|
| 127 |
+
|
| 128 |
+
# Load a model
|
| 129 |
+
model = YOLO("yolov8n.pt") # load a pretrained model (recommended for training)
|
| 130 |
+
|
| 131 |
+
# Train the model
|
| 132 |
+
results = model.train(data="lvis.yaml", epochs=100, imgsz=640)
|
| 133 |
+
```
|
| 134 |
+
|
| 135 |
+
|
| 136 |
+
=== "CLI"
|
| 137 |
+
|
| 138 |
+
```bash
|
| 139 |
+
# Start training from a pretrained *.pt model
|
| 140 |
+
yolo detect train data=lvis.yaml model=yolov8n.pt epochs=100 imgsz=640
|
| 141 |
+
```
|
| 142 |
+
|
| 143 |
+
For detailed training configurations, refer to the [Training](../../modes/train.md) documentation.
|
| 144 |
+
|
| 145 |
+
### How does the LVIS dataset differ from the COCO dataset?
|
| 146 |
+
|
| 147 |
+
The images in the LVIS dataset are the same as those in the [COCO dataset](./coco.md), but the two differ in terms of splitting and annotations. LVIS provides a larger and more detailed vocabulary with 1203 object categories compared to COCO's 80 categories. Additionally, LVIS focuses on annotation completeness and diversity, aiming to push the limits of object detection and instance segmentation models by offering more nuanced and comprehensive data.
|
| 148 |
+
|
| 149 |
+
### Why should I use Ultralytics YOLO for training on the LVIS dataset?
|
| 150 |
+
|
| 151 |
+
Ultralytics YOLO models, including the latest YOLOv8, are optimized for real-time object detection with state-of-the-art accuracy and speed. They support a wide range of annotations, such as the fine-grained ones provided by the LVIS dataset, making them ideal for advanced computer vision applications. Moreover, Ultralytics offers seamless integration with various [training](../../modes/train.md), [validation](../../modes/val.md), and [prediction](../../modes/predict.md) modes, ensuring efficient model development and deployment.
|
| 152 |
+
|
| 153 |
+
### Can I see some sample annotations from the LVIS dataset?
|
| 154 |
+
|
| 155 |
+
Yes, the LVIS dataset includes a variety of images with diverse object categories and complex scenes. Here is an example of a sample image along with its annotations:
|
| 156 |
+
|
| 157 |
+

|
| 158 |
+
|
| 159 |
+
This mosaiced image demonstrates a training batch composed of multiple dataset images combined into one. Mosaicing increases the variety of objects and scenes within each training batch, enhancing the model's ability to generalize across different contexts. For more details on the LVIS dataset, explore the [LVIS dataset documentation](#key-features).
|
ultralytics/docs/en/datasets/detect/objects365.md
ADDED
|
@@ -0,0 +1,141 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
comments: true
|
| 3 |
+
description: Explore the Objects365 Dataset with 2M images and 30M bounding boxes across 365 categories. Enhance your object detection models with diverse, high-quality data.
|
| 4 |
+
keywords: Objects365 dataset, object detection, machine learning, deep learning, computer vision, annotated images, bounding boxes, YOLOv8, high-resolution images, dataset configuration
|
| 5 |
+
---
|
| 6 |
+
|
| 7 |
+
# Objects365 Dataset
|
| 8 |
+
|
| 9 |
+
The [Objects365](https://www.objects365.org/) dataset is a large-scale, high-quality dataset designed to foster object detection research with a focus on diverse objects in the wild. Created by a team of [Megvii](https://en.megvii.com/) researchers, the dataset offers a wide range of high-resolution images with a comprehensive set of annotated bounding boxes covering 365 object categories.
|
| 10 |
+
|
| 11 |
+
## Key Features
|
| 12 |
+
|
| 13 |
+
- Objects365 contains 365 object categories, with 2 million images and over 30 million bounding boxes.
|
| 14 |
+
- The dataset includes diverse objects in various scenarios, providing a rich and challenging benchmark for object detection tasks.
|
| 15 |
+
- Annotations include bounding boxes for objects, making it suitable for training and evaluating object detection models.
|
| 16 |
+
- Objects365 pre-trained models significantly outperform ImageNet pre-trained models, leading to better generalization on various tasks.
|
| 17 |
+
|
| 18 |
+
## Dataset Structure
|
| 19 |
+
|
| 20 |
+
The Objects365 dataset is organized into a single set of images with corresponding annotations:
|
| 21 |
+
|
| 22 |
+
- **Images**: The dataset includes 2 million high-resolution images, each containing a variety of objects across 365 categories.
|
| 23 |
+
- **Annotations**: The images are annotated with over 30 million bounding boxes, providing comprehensive ground truth information for object detection tasks.
|
| 24 |
+
|
| 25 |
+
## Applications
|
| 26 |
+
|
| 27 |
+
The Objects365 dataset is widely used for training and evaluating deep learning models in object detection tasks. The dataset's diverse set of object categories and high-quality annotations make it a valuable resource for researchers and practitioners in the field of computer vision.
|
| 28 |
+
|
| 29 |
+
## Dataset YAML
|
| 30 |
+
|
| 31 |
+
A YAML (Yet Another Markup Language) file is used to define the dataset configuration. It contains information about the dataset's paths, classes, and other relevant information. For the case of the Objects365 Dataset, the `Objects365.yaml` file is maintained at [https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/Objects365.yaml](https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/Objects365.yaml).
|
| 32 |
+
|
| 33 |
+
!!! example "ultralytics/cfg/datasets/Objects365.yaml"
|
| 34 |
+
|
| 35 |
+
```yaml
|
| 36 |
+
--8<-- "ultralytics/cfg/datasets/Objects365.yaml"
|
| 37 |
+
```
|
| 38 |
+
|
| 39 |
+
## Usage
|
| 40 |
+
|
| 41 |
+
To train a YOLOv8n model on the Objects365 dataset for 100 epochs with an image size of 640, you can use the following code snippets. For a comprehensive list of available arguments, refer to the model [Training](../../modes/train.md) page.
|
| 42 |
+
|
| 43 |
+
!!! example "Train Example"
|
| 44 |
+
|
| 45 |
+
=== "Python"
|
| 46 |
+
|
| 47 |
+
```python
|
| 48 |
+
from ultralytics import YOLO
|
| 49 |
+
|
| 50 |
+
# Load a model
|
| 51 |
+
model = YOLO("yolov8n.pt") # load a pretrained model (recommended for training)
|
| 52 |
+
|
| 53 |
+
# Train the model
|
| 54 |
+
results = model.train(data="Objects365.yaml", epochs=100, imgsz=640)
|
| 55 |
+
```
|
| 56 |
+
|
| 57 |
+
=== "CLI"
|
| 58 |
+
|
| 59 |
+
```bash
|
| 60 |
+
# Start training from a pretrained *.pt model
|
| 61 |
+
yolo detect train data=Objects365.yaml model=yolov8n.pt epochs=100 imgsz=640
|
| 62 |
+
```
|
| 63 |
+
|
| 64 |
+
## Sample Data and Annotations
|
| 65 |
+
|
| 66 |
+
The Objects365 dataset contains a diverse set of high-resolution images with objects from 365 categories, providing rich context for object detection tasks. Here are some examples of the images in the dataset:
|
| 67 |
+
|
| 68 |
+

|
| 69 |
+
|
| 70 |
+
- **Objects365**: This image demonstrates an example of object detection, where objects are annotated with bounding boxes. The dataset provides a wide range of images to facilitate the development of models for this task.
|
| 71 |
+
|
| 72 |
+
The example showcases the variety and complexity of the data in the Objects365 dataset and highlights the importance of accurate object detection for computer vision applications.
|
| 73 |
+
|
| 74 |
+
## Citations and Acknowledgments
|
| 75 |
+
|
| 76 |
+
If you use the Objects365 dataset in your research or development work, please cite the following paper:
|
| 77 |
+
|
| 78 |
+
!!! quote ""
|
| 79 |
+
|
| 80 |
+
=== "BibTeX"
|
| 81 |
+
|
| 82 |
+
```bibtex
|
| 83 |
+
@inproceedings{shao2019objects365,
|
| 84 |
+
title={Objects365: A Large-scale, High-quality Dataset for Object Detection},
|
| 85 |
+
author={Shao, Shuai and Li, Zeming and Zhang, Tianyuan and Peng, Chao and Yu, Gang and Li, Jing and Zhang, Xiangyu and Sun, Jian},
|
| 86 |
+
booktitle={Proceedings of the IEEE/CVF International Conference on Computer Vision},
|
| 87 |
+
pages={8425--8434},
|
| 88 |
+
year={2019}
|
| 89 |
+
}
|
| 90 |
+
```
|
| 91 |
+
|
| 92 |
+
We would like to acknowledge the team of researchers who created and maintain the Objects365 dataset as a valuable resource for the computer vision research community. For more information about the Objects365 dataset and its creators, visit the [Objects365 dataset website](https://www.objects365.org/).
|
| 93 |
+
|
| 94 |
+
## FAQ
|
| 95 |
+
|
| 96 |
+
### What is the Objects365 dataset used for?
|
| 97 |
+
|
| 98 |
+
The [Objects365 dataset](https://www.objects365.org/) is designed for object detection tasks in machine learning and computer vision. It provides a large-scale, high-quality dataset with 2 million annotated images and 30 million bounding boxes across 365 categories. Leveraging such a diverse dataset helps improve the performance and generalization of object detection models, making it invaluable for research and development in the field.
|
| 99 |
+
|
| 100 |
+
### How can I train a YOLOv8 model on the Objects365 dataset?
|
| 101 |
+
|
| 102 |
+
To train a YOLOv8n model using the Objects365 dataset for 100 epochs with an image size of 640, follow these instructions:
|
| 103 |
+
|
| 104 |
+
!!! example "Train Example"
|
| 105 |
+
|
| 106 |
+
=== "Python"
|
| 107 |
+
|
| 108 |
+
```python
|
| 109 |
+
from ultralytics import YOLO
|
| 110 |
+
|
| 111 |
+
# Load a model
|
| 112 |
+
model = YOLO("yolov8n.pt") # load a pretrained model (recommended for training)
|
| 113 |
+
|
| 114 |
+
# Train the model
|
| 115 |
+
results = model.train(data="Objects365.yaml", epochs=100, imgsz=640)
|
| 116 |
+
```
|
| 117 |
+
|
| 118 |
+
=== "CLI"
|
| 119 |
+
|
| 120 |
+
```bash
|
| 121 |
+
# Start training from a pretrained *.pt model
|
| 122 |
+
yolo detect train data=Objects365.yaml model=yolov8n.pt epochs=100 imgsz=640
|
| 123 |
+
```
|
| 124 |
+
|
| 125 |
+
Refer to the [Training](../../modes/train.md) page for a comprehensive list of available arguments.
|
| 126 |
+
|
| 127 |
+
### Why should I use the Objects365 dataset for my object detection projects?
|
| 128 |
+
|
| 129 |
+
The Objects365 dataset offers several advantages for object detection tasks:
|
| 130 |
+
|
| 131 |
+
1. **Diversity**: It includes 2 million images with objects in diverse scenarios, covering 365 categories.
|
| 132 |
+
2. **High-quality Annotations**: Over 30 million bounding boxes provide comprehensive ground truth data.
|
| 133 |
+
3. **Performance**: Models pre-trained on Objects365 significantly outperform those trained on datasets like ImageNet, leading to better generalization.
|
| 134 |
+
|
| 135 |
+
### Where can I find the YAML configuration file for the Objects365 dataset?
|
| 136 |
+
|
| 137 |
+
The YAML configuration file for the Objects365 dataset is available at [Objects365.yaml](https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/Objects365.yaml). This file contains essential information such as dataset paths and class labels, crucial for setting up your training environment.
|
| 138 |
+
|
| 139 |
+
### How does the dataset structure of Objects365 enhance object detection modeling?
|
| 140 |
+
|
| 141 |
+
The [Objects365 dataset](https://www.objects365.org/) is organized with 2 million high-resolution images and comprehensive annotations of over 30 million bounding boxes. This structure ensures a robust dataset for training deep learning models in object detection, offering a wide variety of objects and scenarios. Such diversity and volume help in developing models that are more accurate and capable of generalizing well to real-world applications. For more details on the dataset structure, refer to the [Dataset YAML](#dataset-yaml) section.
|
ultralytics/docs/en/datasets/detect/open-images-v7.md
ADDED
|
@@ -0,0 +1,200 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
comments: true
|
| 3 |
+
description: Explore the comprehensive Open Images V7 dataset by Google. Learn about its annotations, applications, and use YOLOv8 pretrained models for computer vision tasks.
|
| 4 |
+
keywords: Open Images V7, Google dataset, computer vision, YOLOv8 models, object detection, image segmentation, visual relationships, AI research, Ultralytics
|
| 5 |
+
---
|
| 6 |
+
|
| 7 |
+
# Open Images V7 Dataset
|
| 8 |
+
|
| 9 |
+
[Open Images V7](https://storage.googleapis.com/openimages/web/index.html) is a versatile and expansive dataset championed by Google. Aimed at propelling research in the realm of computer vision, it boasts a vast collection of images annotated with a plethora of data, including image-level labels, object bounding boxes, object segmentation masks, visual relationships, and localized narratives.
|
| 10 |
+
|
| 11 |
+
<p align="center">
|
| 12 |
+
<br>
|
| 13 |
+
<iframe loading="lazy" width="720" height="405" src="https://www.youtube.com/embed/u3pLlgzUeV8"
|
| 14 |
+
title="YouTube video player" frameborder="0"
|
| 15 |
+
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share"
|
| 16 |
+
allowfullscreen>
|
| 17 |
+
</iframe>
|
| 18 |
+
<br>
|
| 19 |
+
<strong>Watch:</strong> Object Detection using OpenImagesV7 Pretrained Model
|
| 20 |
+
</p>
|
| 21 |
+
|
| 22 |
+
## Open Images V7 Pretrained Models
|
| 23 |
+
|
| 24 |
+
| Model | size<br><sup>(pixels) | mAP<sup>val<br>50-95 | Speed<br><sup>CPU ONNX<br>(ms) | Speed<br><sup>A100 TensorRT<br>(ms) | params<br><sup>(M) | FLOPs<br><sup>(B) |
|
| 25 |
+
| ----------------------------------------------------------------------------------------- | --------------------- | -------------------- | ------------------------------ | ----------------------------------- | ------------------ | ----------------- |
|
| 26 |
+
| [YOLOv8n](https://github.com/ultralytics/assets/releases/download/v8.2.0/yolov8n-oiv7.pt) | 640 | 18.4 | 142.4 | 1.21 | 3.5 | 10.5 |
|
| 27 |
+
| [YOLOv8s](https://github.com/ultralytics/assets/releases/download/v8.2.0/yolov8s-oiv7.pt) | 640 | 27.7 | 183.1 | 1.40 | 11.4 | 29.7 |
|
| 28 |
+
| [YOLOv8m](https://github.com/ultralytics/assets/releases/download/v8.2.0/yolov8m-oiv7.pt) | 640 | 33.6 | 408.5 | 2.26 | 26.2 | 80.6 |
|
| 29 |
+
| [YOLOv8l](https://github.com/ultralytics/assets/releases/download/v8.2.0/yolov8l-oiv7.pt) | 640 | 34.9 | 596.9 | 2.43 | 44.1 | 167.4 |
|
| 30 |
+
| [YOLOv8x](https://github.com/ultralytics/assets/releases/download/v8.2.0/yolov8x-oiv7.pt) | 640 | 36.3 | 860.6 | 3.56 | 68.7 | 260.6 |
|
| 31 |
+
|
| 32 |
+

|
| 33 |
+
|
| 34 |
+
## Key Features
|
| 35 |
+
|
| 36 |
+
- Encompasses ~9M images annotated in various ways to suit multiple computer vision tasks.
|
| 37 |
+
- Houses a staggering 16M bounding boxes across 600 object classes in 1.9M images. These boxes are primarily hand-drawn by experts ensuring high precision.
|
| 38 |
+
- Visual relationship annotations totaling 3.3M are available, detailing 1,466 unique relationship triplets, object properties, and human activities.
|
| 39 |
+
- V5 introduced segmentation masks for 2.8M objects across 350 classes.
|
| 40 |
+
- V6 introduced 675k localized narratives that amalgamate voice, text, and mouse traces highlighting described objects.
|
| 41 |
+
- V7 introduced 66.4M point-level labels on 1.4M images, spanning 5,827 classes.
|
| 42 |
+
- Encompasses 61.4M image-level labels across a diverse set of 20,638 classes.
|
| 43 |
+
- Provides a unified platform for image classification, object detection, relationship detection, instance segmentation, and multimodal image descriptions.
|
| 44 |
+
|
| 45 |
+
## Dataset Structure
|
| 46 |
+
|
| 47 |
+
Open Images V7 is structured in multiple components catering to varied computer vision challenges:
|
| 48 |
+
|
| 49 |
+
- **Images**: About 9 million images, often showcasing intricate scenes with an average of 8.3 objects per image.
|
| 50 |
+
- **Bounding Boxes**: Over 16 million boxes that demarcate objects across 600 categories.
|
| 51 |
+
- **Segmentation Masks**: These detail the exact boundary of 2.8M objects across 350 classes.
|
| 52 |
+
- **Visual Relationships**: 3.3M annotations indicating object relationships, properties, and actions.
|
| 53 |
+
- **Localized Narratives**: 675k descriptions combining voice, text, and mouse traces.
|
| 54 |
+
- **Point-Level Labels**: 66.4M labels across 1.4M images, suitable for zero/few-shot semantic segmentation.
|
| 55 |
+
|
| 56 |
+
## Applications
|
| 57 |
+
|
| 58 |
+
Open Images V7 is a cornerstone for training and evaluating state-of-the-art models in various computer vision tasks. The dataset's broad scope and high-quality annotations make it indispensable for researchers and developers specializing in computer vision.
|
| 59 |
+
|
| 60 |
+
## Dataset YAML
|
| 61 |
+
|
| 62 |
+
Typically, datasets come with a YAML (Yet Another Markup Language) file that delineates the dataset's configuration. For the case of Open Images V7, a hypothetical `OpenImagesV7.yaml` might exist. For accurate paths and configurations, one should refer to the dataset's official repository or documentation.
|
| 63 |
+
|
| 64 |
+
!!! example "OpenImagesV7.yaml"
|
| 65 |
+
|
| 66 |
+
```yaml
|
| 67 |
+
--8<-- "ultralytics/cfg/datasets/open-images-v7.yaml"
|
| 68 |
+
```
|
| 69 |
+
|
| 70 |
+
## Usage
|
| 71 |
+
|
| 72 |
+
To train a YOLOv8n model on the Open Images V7 dataset for 100 epochs with an image size of 640, you can use the following code snippets. For a comprehensive list of available arguments, refer to the model [Training](../../modes/train.md) page.
|
| 73 |
+
|
| 74 |
+
!!! warning
|
| 75 |
+
|
| 76 |
+
The complete Open Images V7 dataset comprises 1,743,042 training images and 41,620 validation images, requiring approximately **561 GB of storage space** upon download.
|
| 77 |
+
|
| 78 |
+
Executing the commands provided below will trigger an automatic download of the full dataset if it's not already present locally. Before running the below example it's crucial to:
|
| 79 |
+
|
| 80 |
+
- Verify that your device has enough storage capacity.
|
| 81 |
+
- Ensure a robust and speedy internet connection.
|
| 82 |
+
|
| 83 |
+
!!! example "Train Example"
|
| 84 |
+
|
| 85 |
+
=== "Python"
|
| 86 |
+
|
| 87 |
+
```python
|
| 88 |
+
from ultralytics import YOLO
|
| 89 |
+
|
| 90 |
+
# Load a COCO-pretrained YOLOv8n model
|
| 91 |
+
model = YOLO("yolov8n.pt")
|
| 92 |
+
|
| 93 |
+
# Train the model on the Open Images V7 dataset
|
| 94 |
+
results = model.train(data="open-images-v7.yaml", epochs=100, imgsz=640)
|
| 95 |
+
```
|
| 96 |
+
|
| 97 |
+
=== "CLI"
|
| 98 |
+
|
| 99 |
+
```bash
|
| 100 |
+
# Train a COCO-pretrained YOLOv8n model on the Open Images V7 dataset
|
| 101 |
+
yolo detect train data=open-images-v7.yaml model=yolov8n.pt epochs=100 imgsz=640
|
| 102 |
+
```
|
| 103 |
+
|
| 104 |
+
## Sample Data and Annotations
|
| 105 |
+
|
| 106 |
+
Illustrations of the dataset help provide insights into its richness:
|
| 107 |
+
|
| 108 |
+

|
| 109 |
+
|
| 110 |
+
- **Open Images V7**: This image exemplifies the depth and detail of annotations available, including bounding boxes, relationships, and segmentation masks.
|
| 111 |
+
|
| 112 |
+
Researchers can gain invaluable insights into the array of computer vision challenges that the dataset addresses, from basic object detection to intricate relationship identification.
|
| 113 |
+
|
| 114 |
+
## Citations and Acknowledgments
|
| 115 |
+
|
| 116 |
+
For those employing Open Images V7 in their work, it's prudent to cite the relevant papers and acknowledge the creators:
|
| 117 |
+
|
| 118 |
+
!!! quote ""
|
| 119 |
+
|
| 120 |
+
=== "BibTeX"
|
| 121 |
+
|
| 122 |
+
```bibtex
|
| 123 |
+
@article{OpenImages,
|
| 124 |
+
author = {Alina Kuznetsova and Hassan Rom and Neil Alldrin and Jasper Uijlings and Ivan Krasin and Jordi Pont-Tuset and Shahab Kamali and Stefan Popov and Matteo Malloci and Alexander Kolesnikov and Tom Duerig and Vittorio Ferrari},
|
| 125 |
+
title = {The Open Images Dataset V4: Unified image classification, object detection, and visual relationship detection at scale},
|
| 126 |
+
year = {2020},
|
| 127 |
+
journal = {IJCV}
|
| 128 |
+
}
|
| 129 |
+
```
|
| 130 |
+
|
| 131 |
+
A heartfelt acknowledgment goes out to the Google AI team for creating and maintaining the Open Images V7 dataset. For a deep dive into the dataset and its offerings, navigate to the [official Open Images V7 website](https://storage.googleapis.com/openimages/web/index.html).
|
| 132 |
+
|
| 133 |
+
## FAQ
|
| 134 |
+
|
| 135 |
+
### What is the Open Images V7 dataset?
|
| 136 |
+
|
| 137 |
+
Open Images V7 is an extensive and versatile dataset created by Google, designed to advance research in computer vision. It includes image-level labels, object bounding boxes, object segmentation masks, visual relationships, and localized narratives, making it ideal for various computer vision tasks such as object detection, segmentation, and relationship detection.
|
| 138 |
+
|
| 139 |
+
### How do I train a YOLOv8 model on the Open Images V7 dataset?
|
| 140 |
+
|
| 141 |
+
To train a YOLOv8 model on the Open Images V7 dataset, you can use both Python and CLI commands. Here's an example of training the YOLOv8n model for 100 epochs with an image size of 640:
|
| 142 |
+
|
| 143 |
+
!!! example "Train Example"
|
| 144 |
+
|
| 145 |
+
=== "Python"
|
| 146 |
+
|
| 147 |
+
```python
|
| 148 |
+
from ultralytics import YOLO
|
| 149 |
+
|
| 150 |
+
# Load a COCO-pretrained YOLOv8n model
|
| 151 |
+
model = YOLO("yolov8n.pt")
|
| 152 |
+
|
| 153 |
+
# Train the model on the Open Images V7 dataset
|
| 154 |
+
results = model.train(data="open-images-v7.yaml", epochs=100, imgsz=640)
|
| 155 |
+
```
|
| 156 |
+
|
| 157 |
+
|
| 158 |
+
=== "CLI"
|
| 159 |
+
|
| 160 |
+
```bash
|
| 161 |
+
# Train a COCO-pretrained YOLOv8n model on the Open Images V7 dataset
|
| 162 |
+
yolo detect train data=open-images-v7.yaml model=yolov8n.pt epochs=100 imgsz=640
|
| 163 |
+
```
|
| 164 |
+
|
| 165 |
+
For more details on arguments and settings, refer to the [Training](../../modes/train.md) page.
|
| 166 |
+
|
| 167 |
+
### What are some key features of the Open Images V7 dataset?
|
| 168 |
+
|
| 169 |
+
The Open Images V7 dataset includes approximately 9 million images with various annotations:
|
| 170 |
+
|
| 171 |
+
- **Bounding Boxes**: 16 million bounding boxes across 600 object classes.
|
| 172 |
+
- **Segmentation Masks**: Masks for 2.8 million objects across 350 classes.
|
| 173 |
+
- **Visual Relationships**: 3.3 million annotations indicating relationships, properties, and actions.
|
| 174 |
+
- **Localized Narratives**: 675,000 descriptions combining voice, text, and mouse traces.
|
| 175 |
+
- **Point-Level Labels**: 66.4 million labels across 1.4 million images.
|
| 176 |
+
- **Image-Level Labels**: 61.4 million labels across 20,638 classes.
|
| 177 |
+
|
| 178 |
+
### What pretrained models are available for the Open Images V7 dataset?
|
| 179 |
+
|
| 180 |
+
Ultralytics provides several YOLOv8 pretrained models for the Open Images V7 dataset, each with different sizes and performance metrics:
|
| 181 |
+
|
| 182 |
+
| Model | size<br><sup>(pixels) | mAP<sup>val<br>50-95 | Speed<br><sup>CPU ONNX<br>(ms) | Speed<br><sup>A100 TensorRT<br>(ms) | params<br><sup>(M) | FLOPs<br><sup>(B) |
|
| 183 |
+
| ----------------------------------------------------------------------------------------- | --------------------- | -------------------- | ------------------------------ | ----------------------------------- | ------------------ | ----------------- |
|
| 184 |
+
| [YOLOv8n](https://github.com/ultralytics/assets/releases/download/v8.2.0/yolov8n-oiv7.pt) | 640 | 18.4 | 142.4 | 1.21 | 3.5 | 10.5 |
|
| 185 |
+
| [YOLOv8s](https://github.com/ultralytics/assets/releases/download/v8.2.0/yolov8s-oiv7.pt) | 640 | 27.7 | 183.1 | 1.40 | 11.4 | 29.7 |
|
| 186 |
+
| [YOLOv8m](https://github.com/ultralytics/assets/releases/download/v8.2.0/yolov8m-oiv7.pt) | 640 | 33.6 | 408.5 | 2.26 | 26.2 | 80.6 |
|
| 187 |
+
| [YOLOv8l](https://github.com/ultralytics/assets/releases/download/v8.2.0/yolov8l-oiv7.pt) | 640 | 34.9 | 596.9 | 2.43 | 44.1 | 167.4 |
|
| 188 |
+
| [YOLOv8x](https://github.com/ultralytics/assets/releases/download/v8.2.0/yolov8x-oiv7.pt) | 640 | 36.3 | 860.6 | 3.56 | 68.7 | 260.6 |
|
| 189 |
+
|
| 190 |
+
### What applications can the Open Images V7 dataset be used for?
|
| 191 |
+
|
| 192 |
+
The Open Images V7 dataset supports a variety of computer vision tasks including:
|
| 193 |
+
|
| 194 |
+
- **Image Classification**
|
| 195 |
+
- **Object Detection**
|
| 196 |
+
- **Instance Segmentation**
|
| 197 |
+
- **Visual Relationship Detection**
|
| 198 |
+
- **Multimodal Image Descriptions**
|
| 199 |
+
|
| 200 |
+
Its comprehensive annotations and broad scope make it suitable for training and evaluating advanced machine learning models, as highlighted in practical use cases detailed in our [applications](#applications) section.
|
ultralytics/docs/en/datasets/detect/roboflow-100.md
ADDED
|
@@ -0,0 +1,218 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
comments: true
|
| 3 |
+
description: Explore the Roboflow 100 dataset featuring 100 diverse datasets designed to test object detection models across various domains, from healthcare to video games.
|
| 4 |
+
keywords: Roboflow 100, Ultralytics, object detection, dataset, benchmarking, machine learning, computer vision, diverse datasets, model evaluation
|
| 5 |
+
---
|
| 6 |
+
|
| 7 |
+
# Roboflow 100 Dataset
|
| 8 |
+
|
| 9 |
+
Roboflow 100, developed by [Roboflow](https://roboflow.com/?ref=ultralytics) and sponsored by Intel, is a groundbreaking [object detection](../../tasks/detect.md) benchmark. It includes 100 diverse datasets sampled from over 90,000 public datasets. This benchmark is designed to test the adaptability of models to various domains, including healthcare, aerial imagery, and video games.
|
| 10 |
+
|
| 11 |
+
<p align="center">
|
| 12 |
+
<img width="640" src="https://github.com/ultralytics/docs/releases/download/0/roboflow-100-overview.avif" alt="Roboflow 100 Overview">
|
| 13 |
+
</p>
|
| 14 |
+
|
| 15 |
+
## Key Features
|
| 16 |
+
|
| 17 |
+
- Includes 100 datasets across seven domains: Aerial, Video games, Microscopic, Underwater, Documents, Electromagnetic, and Real World.
|
| 18 |
+
- The benchmark comprises 224,714 images across 805 classes, thanks to over 11,170 hours of labeling efforts.
|
| 19 |
+
- All images are resized to 640x640 pixels, with a focus on eliminating class ambiguity and filtering out underrepresented classes.
|
| 20 |
+
- Annotations include bounding boxes for objects, making it suitable for [training](../../modes/train.md) and evaluating object detection models.
|
| 21 |
+
|
| 22 |
+
## Dataset Structure
|
| 23 |
+
|
| 24 |
+
The Roboflow 100 dataset is organized into seven categories, each with a distinct set of datasets, images, and classes:
|
| 25 |
+
|
| 26 |
+
- **Aerial**: Consists of 7 datasets with a total of 9,683 images, covering 24 distinct classes.
|
| 27 |
+
- **Video Games**: Includes 7 datasets, featuring 11,579 images across 88 classes.
|
| 28 |
+
- **Microscopic**: Comprises 11 datasets with 13,378 images, spanning 28 classes.
|
| 29 |
+
- **Underwater**: Contains 5 datasets, encompassing 18,003 images in 39 classes.
|
| 30 |
+
- **Documents**: Consists of 8 datasets with 24,813 images, divided into 90 classes.
|
| 31 |
+
- **Electromagnetic**: Made up of 12 datasets, totaling 36,381 images in 41 classes.
|
| 32 |
+
- **Real World**: The largest category with 50 datasets, offering 110,615 images across 495 classes.
|
| 33 |
+
|
| 34 |
+
This structure enables a diverse and extensive testing ground for object detection models, reflecting real-world application scenarios.
|
| 35 |
+
|
| 36 |
+
## Benchmarking
|
| 37 |
+
|
| 38 |
+
Dataset benchmarking evaluates machine learning model performance on specific datasets using standardized metrics like accuracy, mean average precision and F1-score.
|
| 39 |
+
|
| 40 |
+
!!! tip "Benchmarking"
|
| 41 |
+
|
| 42 |
+
Benchmarking results will be stored in "ultralytics-benchmarks/evaluation.txt"
|
| 43 |
+
|
| 44 |
+
!!! example "Benchmarking example"
|
| 45 |
+
|
| 46 |
+
=== "Python"
|
| 47 |
+
|
| 48 |
+
```python
|
| 49 |
+
import os
|
| 50 |
+
import shutil
|
| 51 |
+
from pathlib import Path
|
| 52 |
+
|
| 53 |
+
from ultralytics.utils.benchmarks import RF100Benchmark
|
| 54 |
+
|
| 55 |
+
# Initialize RF100Benchmark and set API key
|
| 56 |
+
benchmark = RF100Benchmark()
|
| 57 |
+
benchmark.set_key(api_key="YOUR_ROBOFLOW_API_KEY")
|
| 58 |
+
|
| 59 |
+
# Parse dataset and define file paths
|
| 60 |
+
names, cfg_yamls = benchmark.parse_dataset()
|
| 61 |
+
val_log_file = Path("ultralytics-benchmarks") / "validation.txt"
|
| 62 |
+
eval_log_file = Path("ultralytics-benchmarks") / "evaluation.txt"
|
| 63 |
+
|
| 64 |
+
# Run benchmarks on each dataset in RF100
|
| 65 |
+
for ind, path in enumerate(cfg_yamls):
|
| 66 |
+
path = Path(path)
|
| 67 |
+
if path.exists():
|
| 68 |
+
# Fix YAML file and run training
|
| 69 |
+
benchmark.fix_yaml(str(path))
|
| 70 |
+
os.system(f"yolo detect train data={path} model=yolov8s.pt epochs=1 batch=16")
|
| 71 |
+
|
| 72 |
+
# Run validation and evaluate
|
| 73 |
+
os.system(f"yolo detect val data={path} model=runs/detect/train/weights/best.pt > {val_log_file} 2>&1")
|
| 74 |
+
benchmark.evaluate(str(path), str(val_log_file), str(eval_log_file), ind)
|
| 75 |
+
|
| 76 |
+
# Remove the 'runs' directory
|
| 77 |
+
runs_dir = Path.cwd() / "runs"
|
| 78 |
+
shutil.rmtree(runs_dir)
|
| 79 |
+
else:
|
| 80 |
+
print("YAML file path does not exist")
|
| 81 |
+
continue
|
| 82 |
+
|
| 83 |
+
print("RF100 Benchmarking completed!")
|
| 84 |
+
```
|
| 85 |
+
|
| 86 |
+
## Applications
|
| 87 |
+
|
| 88 |
+
Roboflow 100 is invaluable for various applications related to computer vision and deep learning. Researchers and engineers can use this benchmark to:
|
| 89 |
+
|
| 90 |
+
- Evaluate the performance of object detection models in a multi-domain context.
|
| 91 |
+
- Test the adaptability of models to real-world scenarios beyond common object recognition.
|
| 92 |
+
- Benchmark the capabilities of object detection models across diverse datasets, including those in healthcare, aerial imagery, and video games.
|
| 93 |
+
|
| 94 |
+
For more ideas and inspiration on real-world applications, be sure to check out [our guides on real-world projects](../../guides/index.md).
|
| 95 |
+
|
| 96 |
+
## Usage
|
| 97 |
+
|
| 98 |
+
The Roboflow 100 dataset is available on both [GitHub](https://github.com/roboflow/roboflow-100-benchmark) and [Roboflow Universe](https://universe.roboflow.com/roboflow-100?ref=ultralytics).
|
| 99 |
+
|
| 100 |
+
You can access it directly from the Roboflow 100 GitHub repository. In addition, on Roboflow Universe, you have the flexibility to download individual datasets by simply clicking the export button within each dataset.
|
| 101 |
+
|
| 102 |
+
## Sample Data and Annotations
|
| 103 |
+
|
| 104 |
+
Roboflow 100 consists of datasets with diverse images and videos captured from various angles and domains. Here's a look at examples of annotated images in the RF100 benchmark.
|
| 105 |
+
|
| 106 |
+
<p align="center">
|
| 107 |
+
<img width="640" src="https://github.com/ultralytics/docs/releases/download/0/sample-data-annotations.avif" alt="Sample Data and Annotations">
|
| 108 |
+
</p>
|
| 109 |
+
|
| 110 |
+
The diversity in the Roboflow 100 benchmark that can be seen above is a significant advancement from traditional benchmarks which often focus on optimizing a single metric within a limited domain.
|
| 111 |
+
|
| 112 |
+
## Citations and Acknowledgments
|
| 113 |
+
|
| 114 |
+
If you use the Roboflow 100 dataset in your research or development work, please cite the following paper:
|
| 115 |
+
|
| 116 |
+
!!! quote ""
|
| 117 |
+
|
| 118 |
+
=== "BibTeX"
|
| 119 |
+
|
| 120 |
+
```bibtex
|
| 121 |
+
@misc{2211.13523,
|
| 122 |
+
Author = {Floriana Ciaglia and Francesco Saverio Zuppichini and Paul Guerrie and Mark McQuade and Jacob Solawetz},
|
| 123 |
+
Title = {Roboflow 100: A Rich, Multi-Domain Object Detection Benchmark},
|
| 124 |
+
Eprint = {arXiv:2211.13523},
|
| 125 |
+
}
|
| 126 |
+
```
|
| 127 |
+
|
| 128 |
+
Our thanks go to the Roboflow team and all the contributors for their hard work in creating and sustaining the Roboflow 100 dataset.
|
| 129 |
+
|
| 130 |
+
If you are interested in exploring more datasets to enhance your object detection and machine learning projects, feel free to visit [our comprehensive dataset collection](../index.md).
|
| 131 |
+
|
| 132 |
+
## FAQ
|
| 133 |
+
|
| 134 |
+
### What is the Roboflow 100 dataset, and why is it significant for object detection?
|
| 135 |
+
|
| 136 |
+
The **Roboflow 100** dataset, developed by [Roboflow](https://roboflow.com/?ref=ultralytics) and sponsored by Intel, is a crucial [object detection](../../tasks/detect.md) benchmark. It features 100 diverse datasets from over 90,000 public datasets, covering domains such as healthcare, aerial imagery, and video games. This diversity ensures that models can adapt to various real-world scenarios, enhancing their robustness and performance.
|
| 137 |
+
|
| 138 |
+
### How can I use the Roboflow 100 dataset for benchmarking my object detection models?
|
| 139 |
+
|
| 140 |
+
To use the Roboflow 100 dataset for benchmarking, you can implement the RF100Benchmark class from the Ultralytics library. Here's a brief example:
|
| 141 |
+
|
| 142 |
+
!!! example "Benchmarking example"
|
| 143 |
+
|
| 144 |
+
=== "Python"
|
| 145 |
+
|
| 146 |
+
```python
|
| 147 |
+
import os
|
| 148 |
+
import shutil
|
| 149 |
+
from pathlib import Path
|
| 150 |
+
|
| 151 |
+
from ultralytics.utils.benchmarks import RF100Benchmark
|
| 152 |
+
|
| 153 |
+
# Initialize RF100Benchmark and set API key
|
| 154 |
+
benchmark = RF100Benchmark()
|
| 155 |
+
benchmark.set_key(api_key="YOUR_ROBOFLOW_API_KEY")
|
| 156 |
+
|
| 157 |
+
# Parse dataset and define file paths
|
| 158 |
+
names, cfg_yamls = benchmark.parse_dataset()
|
| 159 |
+
val_log_file = Path("ultralytics-benchmarks") / "validation.txt"
|
| 160 |
+
eval_log_file = Path("ultralytics-benchmarks") / "evaluation.txt"
|
| 161 |
+
|
| 162 |
+
# Run benchmarks on each dataset in RF100
|
| 163 |
+
for ind, path in enumerate(cfg_yamls):
|
| 164 |
+
path = Path(path)
|
| 165 |
+
if path.exists():
|
| 166 |
+
# Fix YAML file and run training
|
| 167 |
+
benchmark.fix_yaml(str(path))
|
| 168 |
+
os.system(f"yolo detect train data={path} model=yolov8s.pt epochs=1 batch=16")
|
| 169 |
+
|
| 170 |
+
# Run validation and evaluate
|
| 171 |
+
os.system(f"yolo detect val data={path} model=runs/detect/train/weights/best.pt > {val_log_file} 2>&1")
|
| 172 |
+
benchmark.evaluate(str(path), str(val_log_file), str(eval_log_file), ind)
|
| 173 |
+
|
| 174 |
+
# Remove 'runs' directory
|
| 175 |
+
runs_dir = Path.cwd() / "runs"
|
| 176 |
+
shutil.rmtree(runs_dir)
|
| 177 |
+
else:
|
| 178 |
+
print("YAML file path does not exist")
|
| 179 |
+
continue
|
| 180 |
+
|
| 181 |
+
print("RF100 Benchmarking completed!")
|
| 182 |
+
```
|
| 183 |
+
|
| 184 |
+
### Which domains are covered by the Roboflow 100 dataset?
|
| 185 |
+
|
| 186 |
+
The **Roboflow 100** dataset spans seven domains, each providing unique challenges and applications for object detection models:
|
| 187 |
+
|
| 188 |
+
1. **Aerial**: 7 datasets, 9,683 images, 24 classes
|
| 189 |
+
2. **Video Games**: 7 datasets, 11,579 images, 88 classes
|
| 190 |
+
3. **Microscopic**: 11 datasets, 13,378 images, 28 classes
|
| 191 |
+
4. **Underwater**: 5 datasets, 18,003 images, 39 classes
|
| 192 |
+
5. **Documents**: 8 datasets, 24,813 images, 90 classes
|
| 193 |
+
6. **Electromagnetic**: 12 datasets, 36,381 images, 41 classes
|
| 194 |
+
7. **Real World**: 50 datasets, 110,615 images, 495 classes
|
| 195 |
+
|
| 196 |
+
This setup allows for extensive and varied testing of models across different real-world applications.
|
| 197 |
+
|
| 198 |
+
### How do I access and download the Roboflow 100 dataset?
|
| 199 |
+
|
| 200 |
+
The **Roboflow 100** dataset is accessible on [GitHub](https://github.com/roboflow/roboflow-100-benchmark) and [Roboflow Universe](https://universe.roboflow.com/roboflow-100?ref=ultralytics). You can download the entire dataset from GitHub or select individual datasets on Roboflow Universe using the export button.
|
| 201 |
+
|
| 202 |
+
### What should I include when citing the Roboflow 100 dataset in my research?
|
| 203 |
+
|
| 204 |
+
When using the Roboflow 100 dataset in your research, ensure to properly cite it. Here is the recommended citation:
|
| 205 |
+
|
| 206 |
+
!!! quote ""
|
| 207 |
+
|
| 208 |
+
=== "BibTeX"
|
| 209 |
+
|
| 210 |
+
```bibtex
|
| 211 |
+
@misc{2211.13523,
|
| 212 |
+
Author = {Floriana Ciaglia and Francesco Saverio Zuppichini and Paul Guerrie and Mark McQuade and Jacob Solawetz},
|
| 213 |
+
Title = {Roboflow 100: A Rich, Multi-Domain Object Detection Benchmark},
|
| 214 |
+
Eprint = {arXiv:2211.13523},
|
| 215 |
+
}
|
| 216 |
+
```
|
| 217 |
+
|
| 218 |
+
For more details, you can refer to our [comprehensive dataset collection](../index.md).
|
ultralytics/docs/en/datasets/detect/signature.md
ADDED
|
@@ -0,0 +1,170 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
comments: true
|
| 3 |
+
description: Discover the Signature Detection Dataset for training models to identify and verify human signatures in various documents. Perfect for document verification and fraud prevention.
|
| 4 |
+
keywords: Signature Detection Dataset, document verification, fraud detection, computer vision, YOLOv8, Ultralytics, annotated signatures, training dataset
|
| 5 |
+
---
|
| 6 |
+
|
| 7 |
+
# Signature Detection Dataset
|
| 8 |
+
|
| 9 |
+
This dataset focuses on detecting human written signatures within documents. It includes a variety of document types with annotated signatures, providing valuable insights for applications in document verification and fraud detection. Essential for training computer vision algorithms, this dataset aids in identifying signatures in various document formats, supporting research and practical applications in document analysis.
|
| 10 |
+
|
| 11 |
+
## Dataset Structure
|
| 12 |
+
|
| 13 |
+
The signature detection dataset is split into three subsets:
|
| 14 |
+
|
| 15 |
+
- **Training set**: Contains 143 images, each with corresponding annotations.
|
| 16 |
+
- **Validation set**: Includes 35 images, each with paired annotations.
|
| 17 |
+
|
| 18 |
+
## Applications
|
| 19 |
+
|
| 20 |
+
This dataset can be applied in various computer vision tasks such as object detection, object tracking, and document analysis. Specifically, it can be used to train and evaluate models for identifying signatures in documents, which can have applications in document verification, fraud detection, and archival research. Additionally, it can serve as a valuable resource for educational purposes, enabling students and researchers to study and understand the characteristics and behaviors of signatures in different document types.
|
| 21 |
+
|
| 22 |
+
## Dataset YAML
|
| 23 |
+
|
| 24 |
+
A YAML (Yet Another Markup Language) file defines the dataset configuration, including paths and classes information. For the signature detection dataset, the `signature.yaml` file is located at [https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/signature.yaml](https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/signature.yaml).
|
| 25 |
+
|
| 26 |
+
!!! example "ultralytics/cfg/datasets/signature.yaml"
|
| 27 |
+
|
| 28 |
+
```yaml
|
| 29 |
+
--8<-- "ultralytics/cfg/datasets/signature.yaml"
|
| 30 |
+
```
|
| 31 |
+
|
| 32 |
+
## Usage
|
| 33 |
+
|
| 34 |
+
To train a YOLOv8n model on the signature detection dataset for 100 epochs with an image size of 640, use the provided code samples. For a comprehensive list of available parameters, refer to the model's [Training](../../modes/train.md) page.
|
| 35 |
+
|
| 36 |
+
!!! example "Train Example"
|
| 37 |
+
|
| 38 |
+
=== "Python"
|
| 39 |
+
|
| 40 |
+
```python
|
| 41 |
+
from ultralytics import YOLO
|
| 42 |
+
|
| 43 |
+
# Load a model
|
| 44 |
+
model = YOLO("yolov8n.pt") # load a pretrained model (recommended for training)
|
| 45 |
+
|
| 46 |
+
# Train the model
|
| 47 |
+
results = model.train(data="signature.yaml", epochs=100, imgsz=640)
|
| 48 |
+
```
|
| 49 |
+
|
| 50 |
+
=== "CLI"
|
| 51 |
+
|
| 52 |
+
```bash
|
| 53 |
+
# Start training from a pretrained *.pt model
|
| 54 |
+
yolo detect train data=signature.yaml model=yolov8n.pt epochs=100 imgsz=640
|
| 55 |
+
```
|
| 56 |
+
|
| 57 |
+
!!! example "Inference Example"
|
| 58 |
+
|
| 59 |
+
=== "Python"
|
| 60 |
+
|
| 61 |
+
```python
|
| 62 |
+
from ultralytics import YOLO
|
| 63 |
+
|
| 64 |
+
# Load a model
|
| 65 |
+
model = YOLO("path/to/best.pt") # load a signature-detection fine-tuned model
|
| 66 |
+
|
| 67 |
+
# Inference using the model
|
| 68 |
+
results = model.predict("https://ultralytics.com/assets/signature-s.mp4", conf=0.75)
|
| 69 |
+
```
|
| 70 |
+
|
| 71 |
+
=== "CLI"
|
| 72 |
+
|
| 73 |
+
```bash
|
| 74 |
+
# Start prediction with a finetuned *.pt model
|
| 75 |
+
yolo detect predict model='path/to/best.pt' imgsz=640 source="https://ultralytics.com/assets/signature-s.mp4" conf=0.75
|
| 76 |
+
```
|
| 77 |
+
|
| 78 |
+
## Sample Images and Annotations
|
| 79 |
+
|
| 80 |
+
The signature detection dataset comprises a wide variety of images showcasing different document types and annotated signatures. Below are examples of images from the dataset, each accompanied by its corresponding annotations.
|
| 81 |
+
|
| 82 |
+

|
| 83 |
+
|
| 84 |
+
- **Mosaiced Image**: Here, we present a training batch consisting of mosaiced dataset images. Mosaicing, a training technique, combines multiple images into one, enriching batch diversity. This method helps enhance the model's ability to generalize across different signature sizes, aspect ratios, and contexts.
|
| 85 |
+
|
| 86 |
+
This example illustrates the variety and complexity of images in the signature Detection Dataset, emphasizing the benefits of including mosaicing during the training process.
|
| 87 |
+
|
| 88 |
+
## Citations and Acknowledgments
|
| 89 |
+
|
| 90 |
+
The dataset has been released available under the [AGPL-3.0 License](https://github.com/ultralytics/ultralytics/blob/main/LICENSE).
|
| 91 |
+
|
| 92 |
+
## FAQ
|
| 93 |
+
|
| 94 |
+
### What is the Signature Detection Dataset, and how can it be used?
|
| 95 |
+
|
| 96 |
+
The Signature Detection Dataset is a collection of annotated images aimed at detecting human signatures within various document types. It can be applied in computer vision tasks such as object detection and tracking, primarily for document verification, fraud detection, and archival research. This dataset helps train models to recognize signatures in different contexts, making it valuable for both research and practical applications.
|
| 97 |
+
|
| 98 |
+
### How do I train a YOLOv8n model on the Signature Detection Dataset?
|
| 99 |
+
|
| 100 |
+
To train a YOLOv8n model on the Signature Detection Dataset, follow these steps:
|
| 101 |
+
|
| 102 |
+
1. Download the `signature.yaml` dataset configuration file from [signature.yaml](https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/signature.yaml).
|
| 103 |
+
2. Use the following Python script or CLI command to start training:
|
| 104 |
+
|
| 105 |
+
!!! example "Train Example"
|
| 106 |
+
|
| 107 |
+
=== "Python"
|
| 108 |
+
|
| 109 |
+
```python
|
| 110 |
+
from ultralytics import YOLO
|
| 111 |
+
|
| 112 |
+
# Load a pretrained model
|
| 113 |
+
model = YOLO("yolov8n.pt")
|
| 114 |
+
|
| 115 |
+
# Train the model
|
| 116 |
+
results = model.train(data="signature.yaml", epochs=100, imgsz=640)
|
| 117 |
+
```
|
| 118 |
+
|
| 119 |
+
=== "CLI"
|
| 120 |
+
|
| 121 |
+
```bash
|
| 122 |
+
yolo detect train data=signature.yaml model=yolov8n.pt epochs=100 imgsz=640
|
| 123 |
+
```
|
| 124 |
+
|
| 125 |
+
For more details, refer to the [Training](../../modes/train.md) page.
|
| 126 |
+
|
| 127 |
+
### What are the main applications of the Signature Detection Dataset?
|
| 128 |
+
|
| 129 |
+
The Signature Detection Dataset can be used for:
|
| 130 |
+
|
| 131 |
+
1. **Document Verification**: Automatically verifying the presence and authenticity of human signatures in documents.
|
| 132 |
+
2. **Fraud Detection**: Identifying forged or fraudulent signatures in legal and financial documents.
|
| 133 |
+
3. **Archival Research**: Assisting historians and archivists in the digital analysis and cataloging of historical documents.
|
| 134 |
+
4. **Education**: Supporting academic research and teaching in the fields of computer vision and machine learning.
|
| 135 |
+
|
| 136 |
+
### How can I perform inference using a model trained on the Signature Detection Dataset?
|
| 137 |
+
|
| 138 |
+
To perform inference using a model trained on the Signature Detection Dataset, follow these steps:
|
| 139 |
+
|
| 140 |
+
1. Load your fine-tuned model.
|
| 141 |
+
2. Use the below Python script or CLI command to perform inference:
|
| 142 |
+
|
| 143 |
+
!!! example "Inference Example"
|
| 144 |
+
|
| 145 |
+
=== "Python"
|
| 146 |
+
|
| 147 |
+
```python
|
| 148 |
+
from ultralytics import YOLO
|
| 149 |
+
|
| 150 |
+
# Load the fine-tuned model
|
| 151 |
+
model = YOLO("path/to/best.pt")
|
| 152 |
+
|
| 153 |
+
# Perform inference
|
| 154 |
+
results = model.predict("https://ultralytics.com/assets/signature-s.mp4", conf=0.75)
|
| 155 |
+
```
|
| 156 |
+
|
| 157 |
+
=== "CLI"
|
| 158 |
+
|
| 159 |
+
```bash
|
| 160 |
+
yolo detect predict model='path/to/best.pt' imgsz=640 source="https://ultralytics.com/assets/signature-s.mp4" conf=0.75
|
| 161 |
+
```
|
| 162 |
+
|
| 163 |
+
### What is the structure of the Signature Detection Dataset, and where can I find more information?
|
| 164 |
+
|
| 165 |
+
The Signature Detection Dataset is divided into two subsets:
|
| 166 |
+
|
| 167 |
+
- **Training Set**: Contains 143 images with annotations.
|
| 168 |
+
- **Validation Set**: Includes 35 images with annotations.
|
| 169 |
+
|
| 170 |
+
For detailed information, you can refer to the [Dataset Structure](#dataset-structure) section. Additionally, view the complete dataset configuration in the `signature.yaml` file located at [signature.yaml](https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/signature.yaml).
|
ultralytics/docs/en/datasets/detect/sku-110k.md
ADDED
|
@@ -0,0 +1,181 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
comments: true
|
| 3 |
+
description: Explore the SKU-110k dataset of densely packed retail shelf images, perfect for training and evaluating deep learning models in object detection tasks.
|
| 4 |
+
keywords: SKU-110k, dataset, object detection, retail shelf images, deep learning, computer vision, model training
|
| 5 |
+
---
|
| 6 |
+
|
| 7 |
+
# SKU-110k Dataset
|
| 8 |
+
|
| 9 |
+
The [SKU-110k](https://github.com/eg4000/SKU110K_CVPR19) dataset is a collection of densely packed retail shelf images, designed to support research in object detection tasks. Developed by Eran Goldman et al., the dataset contains over 110,000 unique store keeping unit (SKU) categories with densely packed objects, often looking similar or even identical, positioned in close proximity.
|
| 10 |
+
|
| 11 |
+
<p align="center">
|
| 12 |
+
<br>
|
| 13 |
+
<iframe loading="lazy" width="720" height="405" src="https://www.youtube.com/embed/_gRqR-miFPE"
|
| 14 |
+
title="YouTube video player" frameborder="0"
|
| 15 |
+
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share"
|
| 16 |
+
allowfullscreen>
|
| 17 |
+
</iframe>
|
| 18 |
+
<br>
|
| 19 |
+
<strong>Watch:</strong> How to Train YOLOv10 on SKU-110k Dataset using Ultralytics | Retail Dataset
|
| 20 |
+
</p>
|
| 21 |
+
|
| 22 |
+

|
| 23 |
+
|
| 24 |
+
## Key Features
|
| 25 |
+
|
| 26 |
+
- SKU-110k contains images of store shelves from around the world, featuring densely packed objects that pose challenges for state-of-the-art object detectors.
|
| 27 |
+
- The dataset includes over 110,000 unique SKU categories, providing a diverse range of object appearances.
|
| 28 |
+
- Annotations include bounding boxes for objects and SKU category labels.
|
| 29 |
+
|
| 30 |
+
## Dataset Structure
|
| 31 |
+
|
| 32 |
+
The SKU-110k dataset is organized into three main subsets:
|
| 33 |
+
|
| 34 |
+
1. **Training set**: This subset contains images and annotations used for training object detection models.
|
| 35 |
+
2. **Validation set**: This subset consists of images and annotations used for model validation during training.
|
| 36 |
+
3. **Test set**: This subset is designed for the final evaluation of trained object detection models.
|
| 37 |
+
|
| 38 |
+
## Applications
|
| 39 |
+
|
| 40 |
+
The SKU-110k dataset is widely used for training and evaluating deep learning models in object detection tasks, especially in densely packed scenes such as retail shelf displays. The dataset's diverse set of SKU categories and densely packed object arrangements make it a valuable resource for researchers and practitioners in the field of computer vision.
|
| 41 |
+
|
| 42 |
+
## Dataset YAML
|
| 43 |
+
|
| 44 |
+
A YAML (Yet Another Markup Language) file is used to define the dataset configuration. It contains information about the dataset's paths, classes, and other relevant information. For the case of the SKU-110K dataset, the `SKU-110K.yaml` file is maintained at [https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/SKU-110K.yaml](https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/SKU-110K.yaml).
|
| 45 |
+
|
| 46 |
+
!!! example "ultralytics/cfg/datasets/SKU-110K.yaml"
|
| 47 |
+
|
| 48 |
+
```yaml
|
| 49 |
+
--8<-- "ultralytics/cfg/datasets/SKU-110K.yaml"
|
| 50 |
+
```
|
| 51 |
+
|
| 52 |
+
## Usage
|
| 53 |
+
|
| 54 |
+
To train a YOLOv8n model on the SKU-110K dataset for 100 epochs with an image size of 640, you can use the following code snippets. For a comprehensive list of available arguments, refer to the model [Training](../../modes/train.md) page.
|
| 55 |
+
|
| 56 |
+
!!! example "Train Example"
|
| 57 |
+
|
| 58 |
+
=== "Python"
|
| 59 |
+
|
| 60 |
+
```python
|
| 61 |
+
from ultralytics import YOLO
|
| 62 |
+
|
| 63 |
+
# Load a model
|
| 64 |
+
model = YOLO("yolov8n.pt") # load a pretrained model (recommended for training)
|
| 65 |
+
|
| 66 |
+
# Train the model
|
| 67 |
+
results = model.train(data="SKU-110K.yaml", epochs=100, imgsz=640)
|
| 68 |
+
```
|
| 69 |
+
|
| 70 |
+
=== "CLI"
|
| 71 |
+
|
| 72 |
+
```bash
|
| 73 |
+
# Start training from a pretrained *.pt model
|
| 74 |
+
yolo detect train data=SKU-110K.yaml model=yolov8n.pt epochs=100 imgsz=640
|
| 75 |
+
```
|
| 76 |
+
|
| 77 |
+
## Sample Data and Annotations
|
| 78 |
+
|
| 79 |
+
The SKU-110k dataset contains a diverse set of retail shelf images with densely packed objects, providing rich context for object detection tasks. Here are some examples of data from the dataset, along with their corresponding annotations:
|
| 80 |
+
|
| 81 |
+

|
| 82 |
+
|
| 83 |
+
- **Densely packed retail shelf image**: This image demonstrates an example of densely packed objects in a retail shelf setting. Objects are annotated with bounding boxes and SKU category labels.
|
| 84 |
+
|
| 85 |
+
The example showcases the variety and complexity of the data in the SKU-110k dataset and highlights the importance of high-quality data for object detection tasks.
|
| 86 |
+
|
| 87 |
+
## Citations and Acknowledgments
|
| 88 |
+
|
| 89 |
+
If you use the SKU-110k dataset in your research or development work, please cite the following paper:
|
| 90 |
+
|
| 91 |
+
!!! quote ""
|
| 92 |
+
|
| 93 |
+
=== "BibTeX"
|
| 94 |
+
|
| 95 |
+
```bibtex
|
| 96 |
+
@inproceedings{goldman2019dense,
|
| 97 |
+
author = {Eran Goldman and Roei Herzig and Aviv Eisenschtat and Jacob Goldberger and Tal Hassner},
|
| 98 |
+
title = {Precise Detection in Densely Packed Scenes},
|
| 99 |
+
booktitle = {Proc. Conf. Comput. Vision Pattern Recognition (CVPR)},
|
| 100 |
+
year = {2019}
|
| 101 |
+
}
|
| 102 |
+
```
|
| 103 |
+
|
| 104 |
+
We would like to acknowledge Eran Goldman et al. for creating and maintaining the SKU-110k dataset as a valuable resource for the computer vision research community. For more information about the SKU-110k dataset and its creators, visit the [SKU-110k dataset GitHub repository](https://github.com/eg4000/SKU110K_CVPR19).
|
| 105 |
+
|
| 106 |
+
## FAQ
|
| 107 |
+
|
| 108 |
+
### What is the SKU-110k dataset and why is it important for object detection?
|
| 109 |
+
|
| 110 |
+
The SKU-110k dataset consists of densely packed retail shelf images designed to aid research in object detection tasks. Developed by Eran Goldman et al., it includes over 110,000 unique SKU categories. Its importance lies in its ability to challenge state-of-the-art object detectors with diverse object appearances and close proximity, making it an invaluable resource for researchers and practitioners in computer vision. Learn more about the dataset's structure and applications in our [SKU-110k Dataset](#sku-110k-dataset) section.
|
| 111 |
+
|
| 112 |
+
### How do I train a YOLOv8 model using the SKU-110k dataset?
|
| 113 |
+
|
| 114 |
+
Training a YOLOv8 model on the SKU-110k dataset is straightforward. Here's an example to train a YOLOv8n model for 100 epochs with an image size of 640:
|
| 115 |
+
|
| 116 |
+
!!! example "Train Example"
|
| 117 |
+
|
| 118 |
+
=== "Python"
|
| 119 |
+
|
| 120 |
+
```python
|
| 121 |
+
from ultralytics import YOLO
|
| 122 |
+
|
| 123 |
+
# Load a model
|
| 124 |
+
model = YOLO("yolov8n.pt") # load a pretrained model (recommended for training)
|
| 125 |
+
|
| 126 |
+
# Train the model
|
| 127 |
+
results = model.train(data="SKU-110K.yaml", epochs=100, imgsz=640)
|
| 128 |
+
```
|
| 129 |
+
|
| 130 |
+
|
| 131 |
+
=== "CLI"
|
| 132 |
+
|
| 133 |
+
```bash
|
| 134 |
+
# Start training from a pretrained *.pt model
|
| 135 |
+
yolo detect train data=SKU-110K.yaml model=yolov8n.pt epochs=100 imgsz=640
|
| 136 |
+
```
|
| 137 |
+
|
| 138 |
+
For a comprehensive list of available arguments, refer to the model [Training](../../modes/train.md) page.
|
| 139 |
+
|
| 140 |
+
### What are the main subsets of the SKU-110k dataset?
|
| 141 |
+
|
| 142 |
+
The SKU-110k dataset is organized into three main subsets:
|
| 143 |
+
|
| 144 |
+
1. **Training set**: Contains images and annotations used for training object detection models.
|
| 145 |
+
2. **Validation set**: Consists of images and annotations used for model validation during training.
|
| 146 |
+
3. **Test set**: Designed for the final evaluation of trained object detection models.
|
| 147 |
+
|
| 148 |
+
Refer to the [Dataset Structure](#dataset-structure) section for more details.
|
| 149 |
+
|
| 150 |
+
### How do I configure the SKU-110k dataset for training?
|
| 151 |
+
|
| 152 |
+
The SKU-110k dataset configuration is defined in a YAML file, which includes details about the dataset's paths, classes, and other relevant information. The `SKU-110K.yaml` file is maintained at [SKU-110K.yaml](https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/SKU-110K.yaml). For example, you can train a model using this configuration as shown in our [Usage](#usage) section.
|
| 153 |
+
|
| 154 |
+
### What are the key features of the SKU-110k dataset in the context of deep learning?
|
| 155 |
+
|
| 156 |
+
The SKU-110k dataset features images of store shelves from around the world, showcasing densely packed objects that pose significant challenges for object detectors:
|
| 157 |
+
|
| 158 |
+
- Over 110,000 unique SKU categories
|
| 159 |
+
- Diverse object appearances
|
| 160 |
+
- Annotations include bounding boxes and SKU category labels
|
| 161 |
+
|
| 162 |
+
These features make the SKU-110k dataset particularly valuable for training and evaluating deep learning models in object detection tasks. For more details, see the [Key Features](#key-features) section.
|
| 163 |
+
|
| 164 |
+
### How do I cite the SKU-110k dataset in my research?
|
| 165 |
+
|
| 166 |
+
If you use the SKU-110k dataset in your research or development work, please cite the following paper:
|
| 167 |
+
|
| 168 |
+
!!! quote ""
|
| 169 |
+
|
| 170 |
+
=== "BibTeX"
|
| 171 |
+
|
| 172 |
+
```bibtex
|
| 173 |
+
@inproceedings{goldman2019dense,
|
| 174 |
+
author = {Eran Goldman and Roei Herzig and Aviv Eisenschtat and Jacob Goldberger and Tal Hassner},
|
| 175 |
+
title = {Precise Detection in Densely Packed Scenes},
|
| 176 |
+
booktitle = {Proc. Conf. Comput. Vision Pattern Recognition (CVPR)},
|
| 177 |
+
year = {2019}
|
| 178 |
+
}
|
| 179 |
+
```
|
| 180 |
+
|
| 181 |
+
More information about the dataset can be found in the [Citations and Acknowledgments](#citations-and-acknowledgments) section.
|
ultralytics/docs/en/datasets/detect/visdrone.md
ADDED
|
@@ -0,0 +1,179 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
comments: true
|
| 3 |
+
description: Explore the VisDrone Dataset, a large-scale benchmark for drone-based image and video analysis with over 2.6 million annotations for objects like pedestrians and vehicles.
|
| 4 |
+
keywords: VisDrone, drone dataset, computer vision, object detection, object tracking, crowd counting, machine learning, deep learning
|
| 5 |
+
---
|
| 6 |
+
|
| 7 |
+
# VisDrone Dataset
|
| 8 |
+
|
| 9 |
+
The [VisDrone Dataset](https://github.com/VisDrone/VisDrone-Dataset) is a large-scale benchmark created by the AISKYEYE team at the Lab of Machine Learning and Data Mining, Tianjin University, China. It contains carefully annotated ground truth data for various computer vision tasks related to drone-based image and video analysis.
|
| 10 |
+
|
| 11 |
+
<p align="center">
|
| 12 |
+
<br>
|
| 13 |
+
<iframe loading="lazy" width="720" height="405" src="https://www.youtube.com/embed/28JV4rbzklM"
|
| 14 |
+
title="YouTube video player" frameborder="0"
|
| 15 |
+
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share"
|
| 16 |
+
allowfullscreen>
|
| 17 |
+
</iframe>
|
| 18 |
+
<br>
|
| 19 |
+
<strong>Watch:</strong> How to Train Ultralytics YOLO Models on the VisDrone Dataset for Drone Image Analysis
|
| 20 |
+
</p>
|
| 21 |
+
|
| 22 |
+
VisDrone is composed of 288 video clips with 261,908 frames and 10,209 static images, captured by various drone-mounted cameras. The dataset covers a wide range of aspects, including location (14 different cities across China), environment (urban and rural), objects (pedestrians, vehicles, bicycles, etc.), and density (sparse and crowded scenes). The dataset was collected using various drone platforms under different scenarios and weather and lighting conditions. These frames are manually annotated with over 2.6 million bounding boxes of targets such as pedestrians, cars, bicycles, and tricycles. Attributes like scene visibility, object class, and occlusion are also provided for better data utilization.
|
| 23 |
+
|
| 24 |
+
## Dataset Structure
|
| 25 |
+
|
| 26 |
+
The VisDrone dataset is organized into five main subsets, each focusing on a specific task:
|
| 27 |
+
|
| 28 |
+
1. **Task 1**: Object detection in images
|
| 29 |
+
2. **Task 2**: Object detection in videos
|
| 30 |
+
3. **Task 3**: Single-object tracking
|
| 31 |
+
4. **Task 4**: Multi-object tracking
|
| 32 |
+
5. **Task 5**: Crowd counting
|
| 33 |
+
|
| 34 |
+
## Applications
|
| 35 |
+
|
| 36 |
+
The VisDrone dataset is widely used for training and evaluating deep learning models in drone-based computer vision tasks such as object detection, object tracking, and crowd counting. The dataset's diverse set of sensor data, object annotations, and attributes make it a valuable resource for researchers and practitioners in the field of drone-based computer vision.
|
| 37 |
+
|
| 38 |
+
## Dataset YAML
|
| 39 |
+
|
| 40 |
+
A YAML (Yet Another Markup Language) file is used to define the dataset configuration. It contains information about the dataset's paths, classes, and other relevant information. In the case of the Visdrone dataset, the `VisDrone.yaml` file is maintained at [https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/VisDrone.yaml](https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/VisDrone.yaml).
|
| 41 |
+
|
| 42 |
+
!!! example "ultralytics/cfg/datasets/VisDrone.yaml"
|
| 43 |
+
|
| 44 |
+
```yaml
|
| 45 |
+
--8<-- "ultralytics/cfg/datasets/VisDrone.yaml"
|
| 46 |
+
```
|
| 47 |
+
|
| 48 |
+
## Usage
|
| 49 |
+
|
| 50 |
+
To train a YOLOv8n model on the VisDrone dataset for 100 epochs with an image size of 640, you can use the following code snippets. For a comprehensive list of available arguments, refer to the model [Training](../../modes/train.md) page.
|
| 51 |
+
|
| 52 |
+
!!! example "Train Example"
|
| 53 |
+
|
| 54 |
+
=== "Python"
|
| 55 |
+
|
| 56 |
+
```python
|
| 57 |
+
from ultralytics import YOLO
|
| 58 |
+
|
| 59 |
+
# Load a model
|
| 60 |
+
model = YOLO("yolov8n.pt") # load a pretrained model (recommended for training)
|
| 61 |
+
|
| 62 |
+
# Train the model
|
| 63 |
+
results = model.train(data="VisDrone.yaml", epochs=100, imgsz=640)
|
| 64 |
+
```
|
| 65 |
+
|
| 66 |
+
=== "CLI"
|
| 67 |
+
|
| 68 |
+
```bash
|
| 69 |
+
# Start training from a pretrained *.pt model
|
| 70 |
+
yolo detect train data=VisDrone.yaml model=yolov8n.pt epochs=100 imgsz=640
|
| 71 |
+
```
|
| 72 |
+
|
| 73 |
+
## Sample Data and Annotations
|
| 74 |
+
|
| 75 |
+
The VisDrone dataset contains a diverse set of images and videos captured by drone-mounted cameras. Here are some examples of data from the dataset, along with their corresponding annotations:
|
| 76 |
+
|
| 77 |
+

|
| 78 |
+
|
| 79 |
+
- **Task 1**: Object detection in images - This image demonstrates an example of object detection in images, where objects are annotated with bounding boxes. The dataset provides a wide variety of images taken from different locations, environments, and densities to facilitate the development of models for this task.
|
| 80 |
+
|
| 81 |
+
The example showcases the variety and complexity of the data in the VisDrone dataset and highlights the importance of high-quality sensor data for drone-based computer vision tasks.
|
| 82 |
+
|
| 83 |
+
## Citations and Acknowledgments
|
| 84 |
+
|
| 85 |
+
If you use the VisDrone dataset in your research or development work, please cite the following paper:
|
| 86 |
+
|
| 87 |
+
!!! quote ""
|
| 88 |
+
|
| 89 |
+
=== "BibTeX"
|
| 90 |
+
|
| 91 |
+
```bibtex
|
| 92 |
+
@ARTICLE{9573394,
|
| 93 |
+
author={Zhu, Pengfei and Wen, Longyin and Du, Dawei and Bian, Xiao and Fan, Heng and Hu, Qinghua and Ling, Haibin},
|
| 94 |
+
journal={IEEE Transactions on Pattern Analysis and Machine Intelligence},
|
| 95 |
+
title={Detection and Tracking Meet Drones Challenge},
|
| 96 |
+
year={2021},
|
| 97 |
+
volume={},
|
| 98 |
+
number={},
|
| 99 |
+
pages={1-1},
|
| 100 |
+
doi={10.1109/TPAMI.2021.3119563}}
|
| 101 |
+
```
|
| 102 |
+
|
| 103 |
+
We would like to acknowledge the AISKYEYE team at the Lab of Machine Learning and Data Mining, Tianjin University, China, for creating and maintaining the VisDrone dataset as a valuable resource for the drone-based computer vision research community. For more information about the VisDrone dataset and its creators, visit the [VisDrone Dataset GitHub repository](https://github.com/VisDrone/VisDrone-Dataset).
|
| 104 |
+
|
| 105 |
+
## FAQ
|
| 106 |
+
|
| 107 |
+
### What is the VisDrone Dataset and what are its key features?
|
| 108 |
+
|
| 109 |
+
The [VisDrone Dataset](https://github.com/VisDrone/VisDrone-Dataset) is a large-scale benchmark created by the AISKYEYE team at Tianjin University, China. It is designed for various computer vision tasks related to drone-based image and video analysis. Key features include:
|
| 110 |
+
|
| 111 |
+
- **Composition**: 288 video clips with 261,908 frames and 10,209 static images.
|
| 112 |
+
- **Annotations**: Over 2.6 million bounding boxes for objects like pedestrians, cars, bicycles, and tricycles.
|
| 113 |
+
- **Diversity**: Collected across 14 cities, in urban and rural settings, under different weather and lighting conditions.
|
| 114 |
+
- **Tasks**: Split into five main tasks—object detection in images and videos, single-object and multi-object tracking, and crowd counting.
|
| 115 |
+
|
| 116 |
+
### How can I use the VisDrone Dataset to train a YOLOv8 model with Ultralytics?
|
| 117 |
+
|
| 118 |
+
To train a YOLOv8 model on the VisDrone dataset for 100 epochs with an image size of 640, you can follow these steps:
|
| 119 |
+
|
| 120 |
+
!!! example "Train Example"
|
| 121 |
+
|
| 122 |
+
=== "Python"
|
| 123 |
+
|
| 124 |
+
```python
|
| 125 |
+
from ultralytics import YOLO
|
| 126 |
+
|
| 127 |
+
# Load a pretrained model
|
| 128 |
+
model = YOLO("yolov8n.pt")
|
| 129 |
+
|
| 130 |
+
# Train the model
|
| 131 |
+
results = model.train(data="VisDrone.yaml", epochs=100, imgsz=640)
|
| 132 |
+
```
|
| 133 |
+
|
| 134 |
+
=== "CLI"
|
| 135 |
+
|
| 136 |
+
```bash
|
| 137 |
+
# Start training from a pretrained *.pt model
|
| 138 |
+
yolo detect train data=VisDrone.yaml model=yolov8n.pt epochs=100 imgsz=640
|
| 139 |
+
```
|
| 140 |
+
|
| 141 |
+
For additional configuration options, please refer to the model [Training](../../modes/train.md) page.
|
| 142 |
+
|
| 143 |
+
### What are the main subsets of the VisDrone dataset and their applications?
|
| 144 |
+
|
| 145 |
+
The VisDrone dataset is divided into five main subsets, each tailored for a specific computer vision task:
|
| 146 |
+
|
| 147 |
+
1. **Task 1**: Object detection in images.
|
| 148 |
+
2. **Task 2**: Object detection in videos.
|
| 149 |
+
3. **Task 3**: Single-object tracking.
|
| 150 |
+
4. **Task 4**: Multi-object tracking.
|
| 151 |
+
5. **Task 5**: Crowd counting.
|
| 152 |
+
|
| 153 |
+
These subsets are widely used for training and evaluating deep learning models in drone-based applications such as surveillance, traffic monitoring, and public safety.
|
| 154 |
+
|
| 155 |
+
### Where can I find the configuration file for the VisDrone dataset in Ultralytics?
|
| 156 |
+
|
| 157 |
+
The configuration file for the VisDrone dataset, `VisDrone.yaml`, can be found in the Ultralytics repository at the following link:
|
| 158 |
+
[VisDrone.yaml](https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/VisDrone.yaml).
|
| 159 |
+
|
| 160 |
+
### How can I cite the VisDrone dataset if I use it in my research?
|
| 161 |
+
|
| 162 |
+
If you use the VisDrone dataset in your research or development work, please cite the following paper:
|
| 163 |
+
|
| 164 |
+
!!! quote ""
|
| 165 |
+
|
| 166 |
+
=== "BibTeX"
|
| 167 |
+
|
| 168 |
+
```bibtex
|
| 169 |
+
@ARTICLE{9573394,
|
| 170 |
+
author={Zhu, Pengfei and Wen, Longyin and Du, Dawei and Bian, Xiao and Fan, Heng and Hu, Qinghua and Ling, Haibin},
|
| 171 |
+
journal={IEEE Transactions on Pattern Analysis and Machine Intelligence},
|
| 172 |
+
title={Detection and Tracking Meet Drones Challenge},
|
| 173 |
+
year={2021},
|
| 174 |
+
volume={},
|
| 175 |
+
number={},
|
| 176 |
+
pages={1-1},
|
| 177 |
+
doi={10.1109/TPAMI.2021.3119563}
|
| 178 |
+
}
|
| 179 |
+
```
|
ultralytics/docs/en/datasets/detect/xview.md
ADDED
|
@@ -0,0 +1,165 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
comments: true
|
| 3 |
+
description: Explore the xView dataset, a rich resource of 1M+ object instances in high-resolution satellite imagery. Enhance detection, learning efficiency, and more.
|
| 4 |
+
keywords: xView dataset, overhead imagery, satellite images, object detection, high resolution, bounding boxes, computer vision, TensorFlow, PyTorch, dataset structure
|
| 5 |
+
---
|
| 6 |
+
|
| 7 |
+
# xView Dataset
|
| 8 |
+
|
| 9 |
+
The [xView](http://xviewdataset.org/) dataset is one of the largest publicly available datasets of overhead imagery, containing images from complex scenes around the world annotated using bounding boxes. The goal of the xView dataset is to accelerate progress in four computer vision frontiers:
|
| 10 |
+
|
| 11 |
+
1. Reduce minimum resolution for detection.
|
| 12 |
+
2. Improve learning efficiency.
|
| 13 |
+
3. Enable discovery of more object classes.
|
| 14 |
+
4. Improve detection of fine-grained classes.
|
| 15 |
+
|
| 16 |
+
xView builds on the success of challenges like Common Objects in Context (COCO) and aims to leverage computer vision to analyze the growing amount of available imagery from space in order to understand the visual world in new ways and address a range of important applications.
|
| 17 |
+
|
| 18 |
+
## Key Features
|
| 19 |
+
|
| 20 |
+
- xView contains over 1 million object instances across 60 classes.
|
| 21 |
+
- The dataset has a resolution of 0.3 meters, providing higher resolution imagery than most public satellite imagery datasets.
|
| 22 |
+
- xView features a diverse collection of small, rare, fine-grained, and multi-type objects with bounding box annotation.
|
| 23 |
+
- Comes with a pre-trained baseline model using the TensorFlow object detection API and an example for PyTorch.
|
| 24 |
+
|
| 25 |
+
## Dataset Structure
|
| 26 |
+
|
| 27 |
+
The xView dataset is composed of satellite images collected from WorldView-3 satellites at a 0.3m ground sample distance. It contains over 1 million objects across 60 classes in over 1,400 km² of imagery.
|
| 28 |
+
|
| 29 |
+
## Applications
|
| 30 |
+
|
| 31 |
+
The xView dataset is widely used for training and evaluating deep learning models for object detection in overhead imagery. The dataset's diverse set of object classes and high-resolution imagery make it a valuable resource for researchers and practitioners in the field of computer vision, especially for satellite imagery analysis.
|
| 32 |
+
|
| 33 |
+
## Dataset YAML
|
| 34 |
+
|
| 35 |
+
A YAML (Yet Another Markup Language) file is used to define the dataset configuration. It contains information about the dataset's paths, classes, and other relevant information. In the case of the xView dataset, the `xView.yaml` file is maintained at [https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/xView.yaml](https://github.com/ultralytics/ultralytics/blob/main/ultralytics/cfg/datasets/xView.yaml).
|
| 36 |
+
|
| 37 |
+
!!! example "ultralytics/cfg/datasets/xView.yaml"
|
| 38 |
+
|
| 39 |
+
```yaml
|
| 40 |
+
--8<-- "ultralytics/cfg/datasets/xView.yaml"
|
| 41 |
+
```
|
| 42 |
+
|
| 43 |
+
## Usage
|
| 44 |
+
|
| 45 |
+
To train a model on the xView dataset for 100 epochs with an image size of 640, you can use the following code snippets. For a comprehensive list of available arguments, refer to the model [Training](../../modes/train.md) page.
|
| 46 |
+
|
| 47 |
+
!!! example "Train Example"
|
| 48 |
+
|
| 49 |
+
=== "Python"
|
| 50 |
+
|
| 51 |
+
```python
|
| 52 |
+
from ultralytics import YOLO
|
| 53 |
+
|
| 54 |
+
# Load a model
|
| 55 |
+
model = YOLO("yolov8n.pt") # load a pretrained model (recommended for training)
|
| 56 |
+
|
| 57 |
+
# Train the model
|
| 58 |
+
results = model.train(data="xView.yaml", epochs=100, imgsz=640)
|
| 59 |
+
```
|
| 60 |
+
|
| 61 |
+
=== "CLI"
|
| 62 |
+
|
| 63 |
+
```bash
|
| 64 |
+
# Start training from a pretrained *.pt model
|
| 65 |
+
yolo detect train data=xView.yaml model=yolov8n.pt epochs=100 imgsz=640
|
| 66 |
+
```
|
| 67 |
+
|
| 68 |
+
## Sample Data and Annotations
|
| 69 |
+
|
| 70 |
+
The xView dataset contains high-resolution satellite images with a diverse set of objects annotated using bounding boxes. Here are some examples of data from the dataset, along with their corresponding annotations:
|
| 71 |
+
|
| 72 |
+

|
| 73 |
+
|
| 74 |
+
- **Overhead Imagery**: This image demonstrates an example of object detection in overhead imagery, where objects are annotated with bounding boxes. The dataset provides high-resolution satellite images to facilitate the development of models for this task.
|
| 75 |
+
|
| 76 |
+
The example showcases the variety and complexity of the data in the xView dataset and highlights the importance of high-quality satellite imagery for object detection tasks.
|
| 77 |
+
|
| 78 |
+
## Citations and Acknowledgments
|
| 79 |
+
|
| 80 |
+
If you use the xView dataset in your research or development work, please cite the following paper:
|
| 81 |
+
|
| 82 |
+
!!! quote ""
|
| 83 |
+
|
| 84 |
+
=== "BibTeX"
|
| 85 |
+
|
| 86 |
+
```bibtex
|
| 87 |
+
@misc{lam2018xview,
|
| 88 |
+
title={xView: Objects in Context in Overhead Imagery},
|
| 89 |
+
author={Darius Lam and Richard Kuzma and Kevin McGee and Samuel Dooley and Michael Laielli and Matthew Klaric and Yaroslav Bulatov and Brendan McCord},
|
| 90 |
+
year={2018},
|
| 91 |
+
eprint={1802.07856},
|
| 92 |
+
archivePrefix={arXiv},
|
| 93 |
+
primaryClass={cs.CV}
|
| 94 |
+
}
|
| 95 |
+
```
|
| 96 |
+
|
| 97 |
+
We would like to acknowledge the [Defense Innovation Unit](https://www.diu.mil/) (DIU) and the creators of the xView dataset for their valuable contribution to the computer vision research community. For more information about the xView dataset and its creators, visit the [xView dataset website](http://xviewdataset.org/).
|
| 98 |
+
|
| 99 |
+
## FAQ
|
| 100 |
+
|
| 101 |
+
### What is the xView dataset and how does it benefit computer vision research?
|
| 102 |
+
|
| 103 |
+
The [xView](http://xviewdataset.org/) dataset is one of the largest publicly available collections of high-resolution overhead imagery, containing over 1 million object instances across 60 classes. It is designed to enhance various facets of computer vision research such as reducing the minimum resolution for detection, improving learning efficiency, discovering more object classes, and advancing fine-grained object detection.
|
| 104 |
+
|
| 105 |
+
### How can I use Ultralytics YOLO to train a model on the xView dataset?
|
| 106 |
+
|
| 107 |
+
To train a model on the xView dataset using Ultralytics YOLO, follow these steps:
|
| 108 |
+
|
| 109 |
+
!!! example "Train Example"
|
| 110 |
+
|
| 111 |
+
=== "Python"
|
| 112 |
+
|
| 113 |
+
```python
|
| 114 |
+
from ultralytics import YOLO
|
| 115 |
+
|
| 116 |
+
# Load a model
|
| 117 |
+
model = YOLO("yolov8n.pt") # load a pretrained model (recommended for training)
|
| 118 |
+
|
| 119 |
+
# Train the model
|
| 120 |
+
results = model.train(data="xView.yaml", epochs=100, imgsz=640)
|
| 121 |
+
```
|
| 122 |
+
|
| 123 |
+
|
| 124 |
+
=== "CLI"
|
| 125 |
+
|
| 126 |
+
```bash
|
| 127 |
+
# Start training from a pretrained *.pt model
|
| 128 |
+
yolo detect train data=xView.yaml model=yolov8n.pt epochs=100 imgsz=640
|
| 129 |
+
```
|
| 130 |
+
|
| 131 |
+
For detailed arguments and settings, refer to the model [Training](../../modes/train.md) page.
|
| 132 |
+
|
| 133 |
+
### What are the key features of the xView dataset?
|
| 134 |
+
|
| 135 |
+
The xView dataset stands out due to its comprehensive set of features:
|
| 136 |
+
|
| 137 |
+
- Over 1 million object instances across 60 distinct classes.
|
| 138 |
+
- High-resolution imagery at 0.3 meters.
|
| 139 |
+
- Diverse object types including small, rare, and fine-grained objects, all annotated with bounding boxes.
|
| 140 |
+
- Availability of a pre-trained baseline model and examples in TensorFlow and PyTorch.
|
| 141 |
+
|
| 142 |
+
### What is the dataset structure of xView, and how is it annotated?
|
| 143 |
+
|
| 144 |
+
The xView dataset comprises high-resolution satellite images collected from WorldView-3 satellites at a 0.3m ground sample distance. It encompasses over 1 million objects across 60 classes in approximately 1,400 km² of imagery. Each object within the dataset is annotated with bounding boxes, making it ideal for training and evaluating deep learning models for object detection in overhead imagery. For a detailed overview, you can look at the dataset structure section [here](#dataset-structure).
|
| 145 |
+
|
| 146 |
+
### How do I cite the xView dataset in my research?
|
| 147 |
+
|
| 148 |
+
If you utilize the xView dataset in your research, please cite the following paper:
|
| 149 |
+
|
| 150 |
+
!!! quote ""
|
| 151 |
+
|
| 152 |
+
=== "BibTeX"
|
| 153 |
+
|
| 154 |
+
```bibtex
|
| 155 |
+
@misc{lam2018xview,
|
| 156 |
+
title={xView: Objects in Context in Overhead Imagery},
|
| 157 |
+
author={Darius Lam and Richard Kuzma and Kevin McGee and Samuel Dooley and Michael Laielli and Matthew Klaric and Yaroslav Bulatov and Brendan McCord},
|
| 158 |
+
year={2018},
|
| 159 |
+
eprint={1802.07856},
|
| 160 |
+
archivePrefix={arXiv},
|
| 161 |
+
primaryClass={cs.CV}
|
| 162 |
+
}
|
| 163 |
+
```
|
| 164 |
+
|
| 165 |
+
For more information about the xView dataset, visit the official [xView dataset website](http://xviewdataset.org/).
|
ultralytics/docs/en/integrations/amazon-sagemaker.md
ADDED
|
@@ -0,0 +1,256 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
comments: true
|
| 3 |
+
description: Learn step-by-step how to deploy Ultralytics' YOLOv8 on Amazon SageMaker Endpoints, from setup to testing, for powerful real-time inference with AWS services.
|
| 4 |
+
keywords: YOLOv8, Amazon SageMaker, AWS, Ultralytics, machine learning, computer vision, model deployment, AWS CloudFormation, AWS CDK, real-time inference
|
| 5 |
+
---
|
| 6 |
+
|
| 7 |
+
# A Guide to Deploying YOLOv8 on Amazon SageMaker Endpoints
|
| 8 |
+
|
| 9 |
+
Deploying advanced computer vision models like [Ultralytics' YOLOv8](https://github.com/ultralytics/ultralytics) on Amazon SageMaker Endpoints opens up a wide range of possibilities for various machine learning applications. The key to effectively using these models lies in understanding their setup, configuration, and deployment processes. YOLOv8 becomes even more powerful when integrated seamlessly with Amazon SageMaker, a robust and scalable machine learning service by AWS.
|
| 10 |
+
|
| 11 |
+
This guide will take you through the process of deploying YOLOv8 PyTorch models on Amazon SageMaker Endpoints step by step. You'll learn the essentials of preparing your AWS environment, configuring the model appropriately, and using tools like AWS CloudFormation and the AWS Cloud Development Kit (CDK) for deployment.
|
| 12 |
+
|
| 13 |
+
## Amazon SageMaker
|
| 14 |
+
|
| 15 |
+
<p align="center">
|
| 16 |
+
<img width="640" src="https://github.com/ultralytics/docs/releases/download/0/amazon-sagemaker-overview.avif" alt="Amazon SageMaker Overview">
|
| 17 |
+
</p>
|
| 18 |
+
|
| 19 |
+
[Amazon SageMaker](https://aws.amazon.com/sagemaker/) is a machine learning service from Amazon Web Services (AWS) that simplifies the process of building, training, and deploying machine learning models. It provides a broad range of tools for handling various aspects of machine learning workflows. This includes automated features for tuning models, options for training models at scale, and straightforward methods for deploying models into production. SageMaker supports popular machine learning frameworks, offering the flexibility needed for diverse projects. Its features also cover data labeling, workflow management, and performance analysis.
|
| 20 |
+
|
| 21 |
+
## Deploying YOLOv8 on Amazon SageMaker Endpoints
|
| 22 |
+
|
| 23 |
+
Deploying YOLOv8 on Amazon SageMaker lets you use its managed environment for real-time inference and take advantage of features like autoscaling. Take a look at the AWS architecture below.
|
| 24 |
+
|
| 25 |
+
<p align="center">
|
| 26 |
+
<img width="640" src="https://github.com/ultralytics/docs/releases/download/0/aws-architecture.avif" alt="AWS Architecture">
|
| 27 |
+
</p>
|
| 28 |
+
|
| 29 |
+
### Step 1: Setup Your AWS Environment
|
| 30 |
+
|
| 31 |
+
First, ensure you have the following prerequisites in place:
|
| 32 |
+
|
| 33 |
+
- An AWS Account: If you don't already have one, sign up for an AWS account.
|
| 34 |
+
|
| 35 |
+
- Configured IAM Roles: You'll need an IAM role with the necessary permissions for Amazon SageMaker, AWS CloudFormation, and Amazon S3. This role should have policies that allow it to access these services.
|
| 36 |
+
|
| 37 |
+
- AWS CLI: If not already installed, download and install the AWS Command Line Interface (CLI) and configure it with your account details. Follow [the AWS CLI instructions](https://docs.aws.amazon.com/cli/latest/userguide/getting-started-install.html) for installation.
|
| 38 |
+
|
| 39 |
+
- AWS CDK: If not already installed, install the AWS Cloud Development Kit (CDK), which will be used for scripting the deployment. Follow [the AWS CDK instructions](https://docs.aws.amazon.com/cdk/v2/guide/getting_started.html#getting_started_install) for installation.
|
| 40 |
+
|
| 41 |
+
- Adequate Service Quota: Confirm that you have sufficient quotas for two separate resources in Amazon SageMaker: one for `ml.m5.4xlarge` for endpoint usage and another for `ml.m5.4xlarge` for notebook instance usage. Each of these requires a minimum of one quota value. If your current quotas are below this requirement, it's important to request an increase for each. You can request a quota increase by following the detailed instructions in the [AWS Service Quotas documentation](https://docs.aws.amazon.com/servicequotas/latest/userguide/request-quota-increase.html#quota-console-increase).
|
| 42 |
+
|
| 43 |
+
### Step 2: Clone the YOLOv8 SageMaker Repository
|
| 44 |
+
|
| 45 |
+
The next step is to clone the specific AWS repository that contains the resources for deploying YOLOv8 on SageMaker. This repository, hosted on GitHub, includes the necessary CDK scripts and configuration files.
|
| 46 |
+
|
| 47 |
+
- Clone the GitHub Repository: Execute the following command in your terminal to clone the host-yolov8-on-sagemaker-endpoint repository:
|
| 48 |
+
|
| 49 |
+
```bash
|
| 50 |
+
git clone https://github.com/aws-samples/host-yolov8-on-sagemaker-endpoint.git
|
| 51 |
+
```
|
| 52 |
+
|
| 53 |
+
- Navigate to the Cloned Directory: Change your directory to the cloned repository:
|
| 54 |
+
|
| 55 |
+
```bash
|
| 56 |
+
cd host-yolov8-on-sagemaker-endpoint/yolov8-pytorch-cdk
|
| 57 |
+
```
|
| 58 |
+
|
| 59 |
+
### Step 3: Set Up the CDK Environment
|
| 60 |
+
|
| 61 |
+
Now that you have the necessary code, set up your environment for deploying with AWS CDK.
|
| 62 |
+
|
| 63 |
+
- Create a Python Virtual Environment: This isolates your Python environment and dependencies. Run:
|
| 64 |
+
|
| 65 |
+
```bash
|
| 66 |
+
python3 -m venv .venv
|
| 67 |
+
```
|
| 68 |
+
|
| 69 |
+
- Activate the Virtual Environment:
|
| 70 |
+
|
| 71 |
+
```bash
|
| 72 |
+
source .venv/bin/activate
|
| 73 |
+
```
|
| 74 |
+
|
| 75 |
+
- Install Dependencies: Install the required Python dependencies for the project:
|
| 76 |
+
|
| 77 |
+
```bash
|
| 78 |
+
pip3 install -r requirements.txt
|
| 79 |
+
```
|
| 80 |
+
|
| 81 |
+
- Upgrade AWS CDK Library: Ensure you have the latest version of the AWS CDK library:
|
| 82 |
+
|
| 83 |
+
```bash
|
| 84 |
+
pip install --upgrade aws-cdk-lib
|
| 85 |
+
```
|
| 86 |
+
|
| 87 |
+
### Step 4: Create the AWS CloudFormation Stack
|
| 88 |
+
|
| 89 |
+
- Synthesize the CDK Application: Generate the AWS CloudFormation template from your CDK code:
|
| 90 |
+
|
| 91 |
+
```bash
|
| 92 |
+
cdk synth
|
| 93 |
+
```
|
| 94 |
+
|
| 95 |
+
- Bootstrap the CDK Application: Prepare your AWS environment for CDK deployment:
|
| 96 |
+
|
| 97 |
+
```bash
|
| 98 |
+
cdk bootstrap
|
| 99 |
+
```
|
| 100 |
+
|
| 101 |
+
- Deploy the Stack: This will create the necessary AWS resources and deploy your model:
|
| 102 |
+
|
| 103 |
+
```bash
|
| 104 |
+
cdk deploy
|
| 105 |
+
```
|
| 106 |
+
|
| 107 |
+
### Step 5: Deploy the YOLOv8 Model
|
| 108 |
+
|
| 109 |
+
Before diving into the deployment instructions, be sure to check out the range of [YOLOv8 models offered by Ultralytics](../models/index.md). This will help you choose the most appropriate model for your project requirements.
|
| 110 |
+
|
| 111 |
+
After creating the AWS CloudFormation Stack, the next step is to deploy YOLOv8.
|
| 112 |
+
|
| 113 |
+
- Open the Notebook Instance: Go to the AWS Console and navigate to the Amazon SageMaker service. Select "Notebook Instances" from the dashboard, then locate the notebook instance that was created by your CDK deployment script. Open the notebook instance to access the Jupyter environment.
|
| 114 |
+
|
| 115 |
+
- Access and Modify inference.py: After opening the SageMaker notebook instance in Jupyter, locate the inference.py file. Edit the output_fn function in inference.py as shown below and save your changes to the script, ensuring that there are no syntax errors.
|
| 116 |
+
|
| 117 |
+
```python
|
| 118 |
+
import json
|
| 119 |
+
|
| 120 |
+
|
| 121 |
+
def output_fn(prediction_output):
|
| 122 |
+
"""Formats model outputs as JSON string, extracting attributes like boxes, masks, keypoints."""
|
| 123 |
+
print("Executing output_fn from inference.py ...")
|
| 124 |
+
infer = {}
|
| 125 |
+
for result in prediction_output:
|
| 126 |
+
if result.boxes is not None:
|
| 127 |
+
infer["boxes"] = result.boxes.numpy().data.tolist()
|
| 128 |
+
if result.masks is not None:
|
| 129 |
+
infer["masks"] = result.masks.numpy().data.tolist()
|
| 130 |
+
if result.keypoints is not None:
|
| 131 |
+
infer["keypoints"] = result.keypoints.numpy().data.tolist()
|
| 132 |
+
if result.obb is not None:
|
| 133 |
+
infer["obb"] = result.obb.numpy().data.tolist()
|
| 134 |
+
if result.probs is not None:
|
| 135 |
+
infer["probs"] = result.probs.numpy().data.tolist()
|
| 136 |
+
return json.dumps(infer)
|
| 137 |
+
```
|
| 138 |
+
|
| 139 |
+
- Deploy the Endpoint Using 1_DeployEndpoint.ipynb: In the Jupyter environment, open the 1_DeployEndpoint.ipynb notebook located in the sm-notebook directory. Follow the instructions in the notebook and run the cells to download the YOLOv8 model, package it with the updated inference code, and upload it to an Amazon S3 bucket. The notebook will guide you through creating and deploying a SageMaker endpoint for the YOLOv8 model.
|
| 140 |
+
|
| 141 |
+
### Step 6: Testing Your Deployment
|
| 142 |
+
|
| 143 |
+
Now that your YOLOv8 model is deployed, it's important to test its performance and functionality.
|
| 144 |
+
|
| 145 |
+
- Open the Test Notebook: In the same Jupyter environment, locate and open the 2_TestEndpoint.ipynb notebook, also in the sm-notebook directory.
|
| 146 |
+
|
| 147 |
+
- Run the Test Notebook: Follow the instructions within the notebook to test the deployed SageMaker endpoint. This includes sending an image to the endpoint and running inferences. Then, you'll plot the output to visualize the model's performance and accuracy, as shown below.
|
| 148 |
+
|
| 149 |
+
<p align="center">
|
| 150 |
+
<img width="640" src="https://github.com/ultralytics/docs/releases/download/0/testing-results-yolov8.avif" alt="Testing Results YOLOv8">
|
| 151 |
+
</p>
|
| 152 |
+
|
| 153 |
+
- Clean-Up Resources: The test notebook will also guide you through the process of cleaning up the endpoint and the hosted model. This is an important step to manage costs and resources effectively, especially if you do not plan to use the deployed model immediately.
|
| 154 |
+
|
| 155 |
+
### Step 7: Monitoring and Management
|
| 156 |
+
|
| 157 |
+
After testing, continuous monitoring and management of your deployed model are essential.
|
| 158 |
+
|
| 159 |
+
- Monitor with Amazon CloudWatch: Regularly check the performance and health of your SageMaker endpoint using [Amazon CloudWatch](https://aws.amazon.com/cloudwatch/).
|
| 160 |
+
|
| 161 |
+
- Manage the Endpoint: Use the SageMaker console for ongoing management of the endpoint. This includes scaling, updating, or redeploying the model as required.
|
| 162 |
+
|
| 163 |
+
By completing these steps, you will have successfully deployed and tested a YOLOv8 model on Amazon SageMaker Endpoints. This process not only equips you with practical experience in using AWS services for machine learning deployment but also lays the foundation for deploying other advanced models in the future.
|
| 164 |
+
|
| 165 |
+
## Summary
|
| 166 |
+
|
| 167 |
+
This guide took you step by step through deploying YOLOv8 on Amazon SageMaker Endpoints using AWS CloudFormation and the AWS Cloud Development Kit (CDK). The process includes cloning the necessary GitHub repository, setting up the CDK environment, deploying the model using AWS services, and testing its performance on SageMaker.
|
| 168 |
+
|
| 169 |
+
For more technical details, refer to [this article](https://aws.amazon.com/blogs/machine-learning/hosting-yolov8-pytorch-model-on-amazon-sagemaker-endpoints/) on the AWS Machine Learning Blog. You can also check out the official [Amazon SageMaker Documentation](https://docs.aws.amazon.com/sagemaker/latest/dg/realtime-endpoints.html) for more insights into various features and functionalities.
|
| 170 |
+
|
| 171 |
+
Are you interested in learning more about different YOLOv8 integrations? Visit the [Ultralytics integrations guide page](../integrations/index.md) to discover additional tools and capabilities that can enhance your machine-learning projects.
|
| 172 |
+
|
| 173 |
+
## FAQ
|
| 174 |
+
|
| 175 |
+
### How do I deploy the Ultralytics YOLOv8 model on Amazon SageMaker Endpoints?
|
| 176 |
+
|
| 177 |
+
To deploy the Ultralytics YOLOv8 model on Amazon SageMaker Endpoints, follow these steps:
|
| 178 |
+
|
| 179 |
+
1. **Set Up Your AWS Environment**: Ensure you have an AWS Account, IAM roles with necessary permissions, and the AWS CLI configured. Install AWS CDK if not already done (refer to the [AWS CDK instructions](https://docs.aws.amazon.com/cdk/v2/guide/getting_started.html#getting_started_install)).
|
| 180 |
+
2. **Clone the YOLOv8 SageMaker Repository**:
|
| 181 |
+
```bash
|
| 182 |
+
git clone https://github.com/aws-samples/host-yolov8-on-sagemaker-endpoint.git
|
| 183 |
+
cd host-yolov8-on-sagemaker-endpoint/yolov8-pytorch-cdk
|
| 184 |
+
```
|
| 185 |
+
3. **Set Up the CDK Environment**: Create a Python virtual environment, activate it, install dependencies, and upgrade AWS CDK library.
|
| 186 |
+
```bash
|
| 187 |
+
python3 -m venv .venv
|
| 188 |
+
source .venv/bin/activate
|
| 189 |
+
pip3 install -r requirements.txt
|
| 190 |
+
pip install --upgrade aws-cdk-lib
|
| 191 |
+
```
|
| 192 |
+
4. **Deploy using AWS CDK**: Synthesize and deploy the CloudFormation stack, bootstrap the environment.
|
| 193 |
+
```bash
|
| 194 |
+
cdk synth
|
| 195 |
+
cdk bootstrap
|
| 196 |
+
cdk deploy
|
| 197 |
+
```
|
| 198 |
+
|
| 199 |
+
For further details, review the [documentation section](#step-5-deploy-the-yolov8-model).
|
| 200 |
+
|
| 201 |
+
### What are the prerequisites for deploying YOLOv8 on Amazon SageMaker?
|
| 202 |
+
|
| 203 |
+
To deploy YOLOv8 on Amazon SageMaker, ensure you have the following prerequisites:
|
| 204 |
+
|
| 205 |
+
1. **AWS Account**: Active AWS account ([sign up here](https://aws.amazon.com/)).
|
| 206 |
+
2. **IAM Roles**: Configured IAM roles with permissions for SageMaker, CloudFormation, and Amazon S3.
|
| 207 |
+
3. **AWS CLI**: Installed and configured AWS Command Line Interface ([AWS CLI installation guide](https://docs.aws.amazon.com/cli/latest/userguide/getting-started-install.html)).
|
| 208 |
+
4. **AWS CDK**: Installed AWS Cloud Development Kit ([CDK setup guide](https://docs.aws.amazon.com/cdk/v2/guide/getting_started.html#getting_started_install)).
|
| 209 |
+
5. **Service Quotas**: Sufficient quotas for `ml.m5.4xlarge` instances for both endpoint and notebook usage ([request a quota increase](https://docs.aws.amazon.com/servicequotas/latest/userguide/request-quota-increase.html#quota-console-increase)).
|
| 210 |
+
|
| 211 |
+
For detailed setup, refer to [this section](#step-1-setup-your-aws-environment).
|
| 212 |
+
|
| 213 |
+
### Why should I use Ultralytics YOLOv8 on Amazon SageMaker?
|
| 214 |
+
|
| 215 |
+
Using Ultralytics YOLOv8 on Amazon SageMaker offers several advantages:
|
| 216 |
+
|
| 217 |
+
1. **Scalability and Management**: SageMaker provides a managed environment with features like autoscaling, which helps in real-time inference needs.
|
| 218 |
+
2. **Integration with AWS Services**: Seamlessly integrate with other AWS services, such as S3 for data storage, CloudFormation for infrastructure as code, and CloudWatch for monitoring.
|
| 219 |
+
3. **Ease of Deployment**: Simplified setup using AWS CDK scripts and streamlined deployment processes.
|
| 220 |
+
4. **Performance**: Leverage Amazon SageMaker's high-performance infrastructure for running large scale inference tasks efficiently.
|
| 221 |
+
|
| 222 |
+
Explore more about the advantages of using SageMaker in the [introduction section](#amazon-sagemaker).
|
| 223 |
+
|
| 224 |
+
### Can I customize the inference logic for YOLOv8 on Amazon SageMaker?
|
| 225 |
+
|
| 226 |
+
Yes, you can customize the inference logic for YOLOv8 on Amazon SageMaker:
|
| 227 |
+
|
| 228 |
+
1. **Modify `inference.py`**: Locate and customize the `output_fn` function in the `inference.py` file to tailor output formats.
|
| 229 |
+
|
| 230 |
+
```python
|
| 231 |
+
import json
|
| 232 |
+
|
| 233 |
+
|
| 234 |
+
def output_fn(prediction_output):
|
| 235 |
+
"""Formats model outputs as JSON string, extracting attributes like boxes, masks, keypoints."""
|
| 236 |
+
infer = {}
|
| 237 |
+
for result in prediction_output:
|
| 238 |
+
if result.boxes is not None:
|
| 239 |
+
infer["boxes"] = result.boxes.numpy().data.tolist()
|
| 240 |
+
# Add more processing logic if necessary
|
| 241 |
+
return json.dumps(infer)
|
| 242 |
+
```
|
| 243 |
+
|
| 244 |
+
2. **Deploy Updated Model**: Ensure you redeploy the model using Jupyter notebooks provided (`1_DeployEndpoint.ipynb`) to include these changes.
|
| 245 |
+
|
| 246 |
+
Refer to the [detailed steps](#step-5-deploy-the-yolov8-model) for deploying the modified model.
|
| 247 |
+
|
| 248 |
+
### How can I test the deployed YOLOv8 model on Amazon SageMaker?
|
| 249 |
+
|
| 250 |
+
To test the deployed YOLOv8 model on Amazon SageMaker:
|
| 251 |
+
|
| 252 |
+
1. **Open the Test Notebook**: Locate the `2_TestEndpoint.ipynb` notebook in the SageMaker Jupyter environment.
|
| 253 |
+
2. **Run the Notebook**: Follow the notebook's instructions to send an image to the endpoint, perform inference, and display results.
|
| 254 |
+
3. **Visualize Results**: Use built-in plotting functionalities to visualize performance metrics, such as bounding boxes around detected objects.
|
| 255 |
+
|
| 256 |
+
For comprehensive testing instructions, visit the [testing section](#step-6-testing-your-deployment).
|
ultralytics/docs/en/integrations/clearml.md
ADDED
|
@@ -0,0 +1,246 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
comments: true
|
| 3 |
+
description: Discover how to integrate YOLOv8 with ClearML to streamline your MLOps workflow, automate experiments, and enhance model management effortlessly.
|
| 4 |
+
keywords: YOLOv8, ClearML, MLOps, Ultralytics, machine learning, object detection, model training, automation, experiment management
|
| 5 |
+
---
|
| 6 |
+
|
| 7 |
+
# Training YOLOv8 with ClearML: Streamlining Your MLOps Workflow
|
| 8 |
+
|
| 9 |
+
MLOps bridges the gap between creating and deploying machine learning models in real-world settings. It focuses on efficient deployment, scalability, and ongoing management to ensure models perform well in practical applications.
|
| 10 |
+
|
| 11 |
+
[Ultralytics YOLOv8](https://www.ultralytics.com/) effortlessly integrates with ClearML, streamlining and enhancing your object detection model's training and management. This guide will walk you through the integration process, detailing how to set up ClearML, manage experiments, automate model management, and collaborate effectively.
|
| 12 |
+
|
| 13 |
+
## ClearML
|
| 14 |
+
|
| 15 |
+
<p align="center">
|
| 16 |
+
<img width="100%" src="https://github.com/ultralytics/docs/releases/download/0/clearml-overview.avif" alt="ClearML Overview">
|
| 17 |
+
</p>
|
| 18 |
+
|
| 19 |
+
[ClearML](https://clear.ml/) is an innovative open-source MLOps platform that is skillfully designed to automate, monitor, and orchestrate machine learning workflows. Its key features include automated logging of all training and inference data for full experiment reproducibility, an intuitive web UI for easy data visualization and analysis, advanced hyperparameter optimization algorithms, and robust model management for efficient deployment across various platforms.
|
| 20 |
+
|
| 21 |
+
## YOLOv8 Training with ClearML
|
| 22 |
+
|
| 23 |
+
You can bring automation and efficiency to your machine learning workflow by improving your training process by integrating YOLOv8 with ClearML.
|
| 24 |
+
|
| 25 |
+
## Installation
|
| 26 |
+
|
| 27 |
+
To install the required packages, run:
|
| 28 |
+
|
| 29 |
+
!!! tip "Installation"
|
| 30 |
+
|
| 31 |
+
=== "CLI"
|
| 32 |
+
|
| 33 |
+
```bash
|
| 34 |
+
# Install the required packages for YOLOv8 and ClearML
|
| 35 |
+
pip install ultralytics clearml
|
| 36 |
+
```
|
| 37 |
+
|
| 38 |
+
For detailed instructions and best practices related to the installation process, be sure to check our [YOLOv8 Installation guide](../quickstart.md). While installing the required packages for YOLOv8, if you encounter any difficulties, consult our [Common Issues guide](../guides/yolo-common-issues.md) for solutions and tips.
|
| 39 |
+
|
| 40 |
+
## Configuring ClearML
|
| 41 |
+
|
| 42 |
+
Once you have installed the necessary packages, the next step is to initialize and configure your ClearML SDK. This involves setting up your ClearML account and obtaining the necessary credentials for a seamless connection between your development environment and the ClearML server.
|
| 43 |
+
|
| 44 |
+
Begin by initializing the ClearML SDK in your environment. The 'clearml-init' command starts the setup process and prompts you for the necessary credentials.
|
| 45 |
+
|
| 46 |
+
!!! tip "Initial SDK Setup"
|
| 47 |
+
|
| 48 |
+
=== "CLI"
|
| 49 |
+
|
| 50 |
+
```bash
|
| 51 |
+
# Initialize your ClearML SDK setup process
|
| 52 |
+
clearml-init
|
| 53 |
+
```
|
| 54 |
+
|
| 55 |
+
After executing this command, visit the [ClearML Settings page](https://app.clear.ml/settings/workspace-configuration). Navigate to the top right corner and select "Settings." Go to the "Workspace" section and click on "Create new credentials." Use the credentials provided in the "Create Credentials" pop-up to complete the setup as instructed, depending on whether you are configuring ClearML in a Jupyter Notebook or a local Python environment.
|
| 56 |
+
|
| 57 |
+
## Usage
|
| 58 |
+
|
| 59 |
+
Before diving into the usage instructions, be sure to check out the range of [YOLOv8 models offered by Ultralytics](../models/index.md). This will help you choose the most appropriate model for your project requirements.
|
| 60 |
+
|
| 61 |
+
!!! example "Usage"
|
| 62 |
+
|
| 63 |
+
=== "Python"
|
| 64 |
+
|
| 65 |
+
```python
|
| 66 |
+
from clearml import Task
|
| 67 |
+
|
| 68 |
+
from ultralytics import YOLO
|
| 69 |
+
|
| 70 |
+
# Step 1: Creating a ClearML Task
|
| 71 |
+
task = Task.init(project_name="my_project", task_name="my_yolov8_task")
|
| 72 |
+
|
| 73 |
+
# Step 2: Selecting the YOLOv8 Model
|
| 74 |
+
model_variant = "yolov8n"
|
| 75 |
+
task.set_parameter("model_variant", model_variant)
|
| 76 |
+
|
| 77 |
+
# Step 3: Loading the YOLOv8 Model
|
| 78 |
+
model = YOLO(f"{model_variant}.pt")
|
| 79 |
+
|
| 80 |
+
# Step 4: Setting Up Training Arguments
|
| 81 |
+
args = dict(data="coco8.yaml", epochs=16)
|
| 82 |
+
task.connect(args)
|
| 83 |
+
|
| 84 |
+
# Step 5: Initiating Model Training
|
| 85 |
+
results = model.train(**args)
|
| 86 |
+
```
|
| 87 |
+
|
| 88 |
+
### Understanding the Code
|
| 89 |
+
|
| 90 |
+
Let's understand the steps showcased in the usage code snippet above.
|
| 91 |
+
|
| 92 |
+
**Step 1: Creating a ClearML Task**: A new task is initialized in ClearML, specifying your project and task names. This task will track and manage your model's training.
|
| 93 |
+
|
| 94 |
+
**Step 2: Selecting the YOLOv8 Model**: The `model_variant` variable is set to 'yolov8n', one of the YOLOv8 models. This variant is then logged in ClearML for tracking.
|
| 95 |
+
|
| 96 |
+
**Step 3: Loading the YOLOv8 Model**: The selected YOLOv8 model is loaded using Ultralytics' YOLO class, preparing it for training.
|
| 97 |
+
|
| 98 |
+
**Step 4: Setting Up Training Arguments**: Key training arguments like the dataset (`coco8.yaml`) and the number of epochs (`16`) are organized in a dictionary and connected to the ClearML task. This allows for tracking and potential modification via the ClearML UI. For a detailed understanding of the model training process and best practices, refer to our [YOLOv8 Model Training guide](../modes/train.md).
|
| 99 |
+
|
| 100 |
+
**Step 5: Initiating Model Training**: The model training is started with the specified arguments. The results of the training process are captured in the `results` variable.
|
| 101 |
+
|
| 102 |
+
### Understanding the Output
|
| 103 |
+
|
| 104 |
+
Upon running the usage code snippet above, you can expect the following output:
|
| 105 |
+
|
| 106 |
+
- A confirmation message indicating the creation of a new ClearML task, along with its unique ID.
|
| 107 |
+
- An informational message about the script code being stored, indicating that the code execution is being tracked by ClearML.
|
| 108 |
+
- A URL link to the ClearML results page where you can monitor the training progress and view detailed logs.
|
| 109 |
+
- Download progress for the YOLOv8 model and the specified dataset, followed by a summary of the model architecture and training configuration.
|
| 110 |
+
- Initialization messages for various training components like TensorBoard, Automatic Mixed Precision (AMP), and dataset preparation.
|
| 111 |
+
- Finally, the training process starts, with progress updates as the model trains on the specified dataset. For an in-depth understanding of the performance metrics used during training, read [our guide on performance metrics](../guides/yolo-performance-metrics.md).
|
| 112 |
+
|
| 113 |
+
### Viewing the ClearML Results Page
|
| 114 |
+
|
| 115 |
+
By clicking on the URL link to the ClearML results page in the output of the usage code snippet, you can access a comprehensive view of your model's training process.
|
| 116 |
+
|
| 117 |
+
#### Key Features of the ClearML Results Page
|
| 118 |
+
|
| 119 |
+
- **Real-Time Metrics Tracking**
|
| 120 |
+
|
| 121 |
+
- Track critical metrics like loss, accuracy, and validation scores as they occur.
|
| 122 |
+
- Provides immediate feedback for timely model performance adjustments.
|
| 123 |
+
|
| 124 |
+
- **Experiment Comparison**
|
| 125 |
+
|
| 126 |
+
- Compare different training runs side-by-side.
|
| 127 |
+
- Essential for hyperparameter tuning and identifying the most effective models.
|
| 128 |
+
|
| 129 |
+
- **Detailed Logs and Outputs**
|
| 130 |
+
|
| 131 |
+
- Access comprehensive logs, graphical representations of metrics, and console outputs.
|
| 132 |
+
- Gain a deeper understanding of model behavior and issue resolution.
|
| 133 |
+
|
| 134 |
+
- **Resource Utilization Monitoring**
|
| 135 |
+
|
| 136 |
+
- Monitor the utilization of computational resources, including CPU, GPU, and memory.
|
| 137 |
+
- Key to optimizing training efficiency and costs.
|
| 138 |
+
|
| 139 |
+
- **Model Artifacts Management**
|
| 140 |
+
|
| 141 |
+
- View, download, and share model artifacts like trained models and checkpoints.
|
| 142 |
+
- Enhances collaboration and streamlines model deployment and sharing.
|
| 143 |
+
|
| 144 |
+
For a visual walkthrough of what the ClearML Results Page looks like, watch the video below:
|
| 145 |
+
|
| 146 |
+
<p align="center">
|
| 147 |
+
<br>
|
| 148 |
+
<iframe loading="lazy" width="720" height="405" src="https://www.youtube.com/embed/iLcC7m3bCes?si=oSEAoZbrg8inCg_2"
|
| 149 |
+
title="YouTube video player" frameborder="0"
|
| 150 |
+
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share"
|
| 151 |
+
allowfullscreen>
|
| 152 |
+
</iframe>
|
| 153 |
+
<br>
|
| 154 |
+
<strong>Watch:</strong> YOLOv8 MLOps Integration using ClearML
|
| 155 |
+
</p>
|
| 156 |
+
|
| 157 |
+
### Advanced Features in ClearML
|
| 158 |
+
|
| 159 |
+
ClearML offers several advanced features to enhance your MLOps experience.
|
| 160 |
+
|
| 161 |
+
#### Remote Execution
|
| 162 |
+
|
| 163 |
+
ClearML's remote execution feature facilitates the reproduction and manipulation of experiments on different machines. It logs essential details like installed packages and uncommitted changes. When a task is enqueued, the ClearML Agent pulls it, recreates the environment, and runs the experiment, reporting back with detailed results.
|
| 164 |
+
|
| 165 |
+
Deploying a ClearML Agent is straightforward and can be done on various machines using the following command:
|
| 166 |
+
|
| 167 |
+
```bash
|
| 168 |
+
clearml-agent daemon --queue <queues_to_listen_to> [--docker]
|
| 169 |
+
```
|
| 170 |
+
|
| 171 |
+
This setup is applicable to cloud VMs, local GPUs, or laptops. ClearML Autoscalers help manage cloud workloads on platforms like AWS, GCP, and Azure, automating the deployment of agents and adjusting resources based on your resource budget.
|
| 172 |
+
|
| 173 |
+
### Cloning, Editing, and Enqueuing
|
| 174 |
+
|
| 175 |
+
ClearML's user-friendly interface allows easy cloning, editing, and enqueuing of tasks. Users can clone an existing experiment, adjust parameters or other details through the UI, and enqueue the task for execution. This streamlined process ensures that the ClearML Agent executing the task uses updated configurations, making it ideal for iterative experimentation and model fine-tuning.
|
| 176 |
+
|
| 177 |
+
<p align="center"><br>
|
| 178 |
+
<img width="100%" src="https://github.com/ultralytics/docs/releases/download/0/cloning-editing-enqueuing-clearml.avif" alt="Cloning, Editing, and Enqueuing with ClearML">
|
| 179 |
+
</p>
|
| 180 |
+
|
| 181 |
+
## Summary
|
| 182 |
+
|
| 183 |
+
This guide has led you through the process of integrating ClearML with Ultralytics' YOLOv8. Covering everything from initial setup to advanced model management, you've discovered how to leverage ClearML for efficient training, experiment tracking, and workflow optimization in your machine learning projects.
|
| 184 |
+
|
| 185 |
+
For further details on usage, visit [ClearML's official documentation](https://clear.ml/docs/latest/docs/integrations/yolov8/).
|
| 186 |
+
|
| 187 |
+
Additionally, explore more integrations and capabilities of Ultralytics by visiting the [Ultralytics integration guide page](../integrations/index.md), which is a treasure trove of resources and insights.
|
| 188 |
+
|
| 189 |
+
## FAQ
|
| 190 |
+
|
| 191 |
+
### What is the process for integrating Ultralytics YOLOv8 with ClearML?
|
| 192 |
+
|
| 193 |
+
Integrating Ultralytics YOLOv8 with ClearML involves a series of steps to streamline your MLOps workflow. First, install the necessary packages:
|
| 194 |
+
|
| 195 |
+
```bash
|
| 196 |
+
pip install ultralytics clearml
|
| 197 |
+
```
|
| 198 |
+
|
| 199 |
+
Next, initialize the ClearML SDK in your environment using:
|
| 200 |
+
|
| 201 |
+
```bash
|
| 202 |
+
clearml-init
|
| 203 |
+
```
|
| 204 |
+
|
| 205 |
+
You then configure ClearML with your credentials from the [ClearML Settings page](https://app.clear.ml/settings/workspace-configuration). Detailed instructions on the entire setup process, including model selection and training configurations, can be found in our [YOLOv8 Model Training guide](../modes/train.md).
|
| 206 |
+
|
| 207 |
+
### Why should I use ClearML with Ultralytics YOLOv8 for my machine learning projects?
|
| 208 |
+
|
| 209 |
+
Using ClearML with Ultralytics YOLOv8 enhances your machine learning projects by automating experiment tracking, streamlining workflows, and enabling robust model management. ClearML offers real-time metrics tracking, resource utilization monitoring, and a user-friendly interface for comparing experiments. These features help optimize your model's performance and make the development process more efficient. Learn more about the benefits and procedures in our [MLOps Integration guide](../modes/train.md).
|
| 210 |
+
|
| 211 |
+
### How do I troubleshoot common issues during YOLOv8 and ClearML integration?
|
| 212 |
+
|
| 213 |
+
If you encounter issues during the integration of YOLOv8 with ClearML, consult our [Common Issues guide](../guides/yolo-common-issues.md) for solutions and tips. Typical problems might involve package installation errors, credential setup, or configuration issues. This guide provides step-by-step troubleshooting instructions to resolve these common issues efficiently.
|
| 214 |
+
|
| 215 |
+
### How do I set up the ClearML task for YOLOv8 model training?
|
| 216 |
+
|
| 217 |
+
Setting up a ClearML task for YOLOv8 training involves initializing a task, selecting the model variant, loading the model, setting up training arguments, and finally, starting the model training. Here's a simplified example:
|
| 218 |
+
|
| 219 |
+
```python
|
| 220 |
+
from clearml import Task
|
| 221 |
+
|
| 222 |
+
from ultralytics import YOLO
|
| 223 |
+
|
| 224 |
+
# Step 1: Creating a ClearML Task
|
| 225 |
+
task = Task.init(project_name="my_project", task_name="my_yolov8_task")
|
| 226 |
+
|
| 227 |
+
# Step 2: Selecting the YOLOv8 Model
|
| 228 |
+
model_variant = "yolov8n"
|
| 229 |
+
task.set_parameter("model_variant", model_variant)
|
| 230 |
+
|
| 231 |
+
# Step 3: Loading the YOLOv8 Model
|
| 232 |
+
model = YOLO(f"{model_variant}.pt")
|
| 233 |
+
|
| 234 |
+
# Step 4: Setting Up Training Arguments
|
| 235 |
+
args = dict(data="coco8.yaml", epochs=16)
|
| 236 |
+
task.connect(args)
|
| 237 |
+
|
| 238 |
+
# Step 5: Initiating Model Training
|
| 239 |
+
results = model.train(**args)
|
| 240 |
+
```
|
| 241 |
+
|
| 242 |
+
Refer to our [Usage guide](#usage) for a detailed breakdown of these steps.
|
| 243 |
+
|
| 244 |
+
### Where can I view the results of my YOLOv8 training in ClearML?
|
| 245 |
+
|
| 246 |
+
After running your YOLOv8 training script with ClearML, you can view the results on the ClearML results page. The output will include a URL link to the ClearML dashboard, where you can track metrics, compare experiments, and monitor resource usage. For more details on how to view and interpret the results, check our section on [Viewing the ClearML Results Page](#viewing-the-clearml-results-page).
|
ultralytics/docs/en/integrations/comet.md
ADDED
|
@@ -0,0 +1,286 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
comments: true
|
| 3 |
+
description: Learn to simplify the logging of YOLOv8 training with Comet ML. This guide covers installation, setup, real-time insights, and custom logging.
|
| 4 |
+
keywords: YOLOv8, Comet ML, logging, machine learning, training, model checkpoints, metrics, installation, configuration, real-time insights, custom logging
|
| 5 |
+
---
|
| 6 |
+
|
| 7 |
+
# Elevating YOLOv8 Training: Simplify Your Logging Process with Comet ML
|
| 8 |
+
|
| 9 |
+
Logging key training details such as parameters, metrics, image predictions, and model checkpoints is essential in machine learning—it keeps your project transparent, your progress measurable, and your results repeatable.
|
| 10 |
+
|
| 11 |
+
[Ultralytics YOLOv8](https://www.ultralytics.com/) seamlessly integrates with Comet ML, efficiently capturing and optimizing every aspect of your YOLOv8 object detection model's training process. In this guide, we'll cover the installation process, Comet ML setup, real-time insights, custom logging, and offline usage, ensuring that your YOLOv8 training is thoroughly documented and fine-tuned for outstanding results.
|
| 12 |
+
|
| 13 |
+
## Comet ML
|
| 14 |
+
|
| 15 |
+
<p align="center">
|
| 16 |
+
<img width="640" src="https://www.comet.com/docs/v2/img/landing/home-hero.svg" alt="Comet ML Overview">
|
| 17 |
+
</p>
|
| 18 |
+
|
| 19 |
+
[Comet ML](https://www.comet.com/site/) is a platform for tracking, comparing, explaining, and optimizing machine learning models and experiments. It allows you to log metrics, parameters, media, and more during your model training and monitor your experiments through an aesthetically pleasing web interface. Comet ML helps data scientists iterate more rapidly, enhances transparency and reproducibility, and aids in the development of production models.
|
| 20 |
+
|
| 21 |
+
## Harnessing the Power of YOLOv8 and Comet ML
|
| 22 |
+
|
| 23 |
+
By combining Ultralytics YOLOv8 with Comet ML, you unlock a range of benefits. These include simplified experiment management, real-time insights for quick adjustments, flexible and tailored logging options, and the ability to log experiments offline when internet access is limited. This integration empowers you to make data-driven decisions, analyze performance metrics, and achieve exceptional results.
|
| 24 |
+
|
| 25 |
+
## Installation
|
| 26 |
+
|
| 27 |
+
To install the required packages, run:
|
| 28 |
+
|
| 29 |
+
!!! tip "Installation"
|
| 30 |
+
|
| 31 |
+
=== "CLI"
|
| 32 |
+
|
| 33 |
+
```bash
|
| 34 |
+
# Install the required packages for YOLOv8 and Comet ML
|
| 35 |
+
pip install ultralytics comet_ml torch torchvision
|
| 36 |
+
```
|
| 37 |
+
|
| 38 |
+
## Configuring Comet ML
|
| 39 |
+
|
| 40 |
+
After installing the required packages, you'll need to sign up, get a [Comet API Key](https://www.comet.com/signup), and configure it.
|
| 41 |
+
|
| 42 |
+
!!! tip "Configuring Comet ML"
|
| 43 |
+
|
| 44 |
+
=== "CLI"
|
| 45 |
+
|
| 46 |
+
```bash
|
| 47 |
+
# Set your Comet Api Key
|
| 48 |
+
export COMET_API_KEY=<Your API Key>
|
| 49 |
+
```
|
| 50 |
+
|
| 51 |
+
Then, you can initialize your Comet project. Comet will automatically detect the API key and proceed with the setup.
|
| 52 |
+
|
| 53 |
+
```python
|
| 54 |
+
import comet_ml
|
| 55 |
+
|
| 56 |
+
comet_ml.login(project_name="comet-example-yolov8-coco128")
|
| 57 |
+
```
|
| 58 |
+
|
| 59 |
+
If you are using a Google Colab notebook, the code above will prompt you to enter your API key for initialization.
|
| 60 |
+
|
| 61 |
+
## Usage
|
| 62 |
+
|
| 63 |
+
Before diving into the usage instructions, be sure to check out the range of [YOLOv8 models offered by Ultralytics](../models/index.md). This will help you choose the most appropriate model for your project requirements.
|
| 64 |
+
|
| 65 |
+
!!! example "Usage"
|
| 66 |
+
|
| 67 |
+
=== "Python"
|
| 68 |
+
|
| 69 |
+
```python
|
| 70 |
+
from ultralytics import YOLO
|
| 71 |
+
|
| 72 |
+
# Load a model
|
| 73 |
+
model = YOLO("yolov8n.pt")
|
| 74 |
+
|
| 75 |
+
# Train the model
|
| 76 |
+
results = model.train(
|
| 77 |
+
data="coco8.yaml",
|
| 78 |
+
project="comet-example-yolov8-coco128",
|
| 79 |
+
batch=32,
|
| 80 |
+
save_period=1,
|
| 81 |
+
save_json=True,
|
| 82 |
+
epochs=3,
|
| 83 |
+
)
|
| 84 |
+
```
|
| 85 |
+
|
| 86 |
+
After running the training code, Comet ML will create an experiment in your Comet workspace to track the run automatically. You will then be provided with a link to view the detailed logging of your [YOLOv8 model's training](../modes/train.md) process.
|
| 87 |
+
|
| 88 |
+
Comet automatically logs the following data with no additional configuration: metrics such as mAP and loss, hyperparameters, model checkpoints, interactive confusion matrix, and image bounding box predictions.
|
| 89 |
+
|
| 90 |
+
## Understanding Your Model's Performance with Comet ML Visualizations
|
| 91 |
+
|
| 92 |
+
Let's dive into what you'll see on the Comet ML dashboard once your YOLOv8 model begins training. The dashboard is where all the action happens, presenting a range of automatically logged information through visuals and statistics. Here's a quick tour:
|
| 93 |
+
|
| 94 |
+
**Experiment Panels**
|
| 95 |
+
|
| 96 |
+
The experiment panels section of the Comet ML dashboard organize and present the different runs and their metrics, such as segment mask loss, class loss, precision, and mean average precision.
|
| 97 |
+
|
| 98 |
+
<p align="center">
|
| 99 |
+
<img width="640" src="https://github.com/ultralytics/docs/releases/download/0/comet-ml-dashboard-overview.avif" alt="Comet ML Overview">
|
| 100 |
+
</p>
|
| 101 |
+
|
| 102 |
+
**Metrics**
|
| 103 |
+
|
| 104 |
+
In the metrics section, you have the option to examine the metrics in a tabular format as well, which is displayed in a dedicated pane as illustrated here.
|
| 105 |
+
|
| 106 |
+
<p align="center">
|
| 107 |
+
<img width="640" src="https://github.com/ultralytics/docs/releases/download/0/comet-ml-metrics-tabular.avif" alt="Comet ML Overview">
|
| 108 |
+
</p>
|
| 109 |
+
|
| 110 |
+
**Interactive Confusion Matrix**
|
| 111 |
+
|
| 112 |
+
The confusion matrix, found in the Confusion Matrix tab, provides an interactive way to assess the model's classification accuracy. It details the correct and incorrect predictions, allowing you to understand the model's strengths and weaknesses.
|
| 113 |
+
|
| 114 |
+
<p align="center">
|
| 115 |
+
<img width="640" src="https://github.com/ultralytics/docs/releases/download/0/comet-ml-interactive-confusion-matrix.avif" alt="Comet ML Overview">
|
| 116 |
+
</p>
|
| 117 |
+
|
| 118 |
+
**System Metrics**
|
| 119 |
+
|
| 120 |
+
Comet ML logs system metrics to help identify any bottlenecks in the training process. It includes metrics such as GPU utilization, GPU memory usage, CPU utilization, and RAM usage. These are essential for monitoring the efficiency of resource usage during model training.
|
| 121 |
+
|
| 122 |
+
<p align="center">
|
| 123 |
+
<img width="640" src="https://github.com/ultralytics/docs/releases/download/0/comet-ml-system-metrics.avif" alt="Comet ML Overview">
|
| 124 |
+
</p>
|
| 125 |
+
|
| 126 |
+
## Customizing Comet ML Logging
|
| 127 |
+
|
| 128 |
+
Comet ML offers the flexibility to customize its logging behavior by setting environment variables. These configurations allow you to tailor Comet ML to your specific needs and preferences. Here are some helpful customization options:
|
| 129 |
+
|
| 130 |
+
### Logging Image Predictions
|
| 131 |
+
|
| 132 |
+
You can control the number of image predictions that Comet ML logs during your experiments. By default, Comet ML logs 100 image predictions from the validation set. However, you can change this number to better suit your requirements. For example, to log 200 image predictions, use the following code:
|
| 133 |
+
|
| 134 |
+
```python
|
| 135 |
+
import os
|
| 136 |
+
|
| 137 |
+
os.environ["COMET_MAX_IMAGE_PREDICTIONS"] = "200"
|
| 138 |
+
```
|
| 139 |
+
|
| 140 |
+
### Batch Logging Interval
|
| 141 |
+
|
| 142 |
+
Comet ML allows you to specify how often batches of image predictions are logged. The `COMET_EVAL_BATCH_LOGGING_INTERVAL` environment variable controls this frequency. The default setting is 1, which logs predictions from every validation batch. You can adjust this value to log predictions at a different interval. For instance, setting it to 4 will log predictions from every fourth batch.
|
| 143 |
+
|
| 144 |
+
```python
|
| 145 |
+
import os
|
| 146 |
+
|
| 147 |
+
os.environ["COMET_EVAL_BATCH_LOGGING_INTERVAL"] = "4"
|
| 148 |
+
```
|
| 149 |
+
|
| 150 |
+
### Disabling Confusion Matrix Logging
|
| 151 |
+
|
| 152 |
+
In some cases, you may not want to log the confusion matrix from your validation set after every epoch. You can disable this feature by setting the `COMET_EVAL_LOG_CONFUSION_MATRIX` environment variable to "false." The confusion matrix will only be logged once, after the training is completed.
|
| 153 |
+
|
| 154 |
+
```python
|
| 155 |
+
import os
|
| 156 |
+
|
| 157 |
+
os.environ["COMET_EVAL_LOG_CONFUSION_MATRIX"] = "false"
|
| 158 |
+
```
|
| 159 |
+
|
| 160 |
+
### Offline Logging
|
| 161 |
+
|
| 162 |
+
If you find yourself in a situation where internet access is limited, Comet ML provides an offline logging option. You can set the `COMET_MODE` environment variable to "offline" to enable this feature. Your experiment data will be saved locally in a directory that you can later upload to Comet ML when internet connectivity is available.
|
| 163 |
+
|
| 164 |
+
```python
|
| 165 |
+
import os
|
| 166 |
+
|
| 167 |
+
os.environ["COMET_MODE"] = "offline"
|
| 168 |
+
```
|
| 169 |
+
|
| 170 |
+
## Summary
|
| 171 |
+
|
| 172 |
+
This guide has walked you through integrating Comet ML with Ultralytics' YOLOv8. From installation to customization, you've learned to streamline experiment management, gain real-time insights, and adapt logging to your project's needs.
|
| 173 |
+
|
| 174 |
+
Explore [Comet ML's official documentation](https://www.comet.com/docs/v2/integrations/third-party-tools/yolov8/) for more insights on integrating with YOLOv8.
|
| 175 |
+
|
| 176 |
+
Furthermore, if you're looking to dive deeper into the practical applications of YOLOv8, specifically for image segmentation tasks, this detailed guide on [fine-tuning YOLOv8 with Comet ML](https://www.comet.com/site/blog/fine-tuning-yolov8-for-image-segmentation-with-comet/) offers valuable insights and step-by-step instructions to enhance your model's performance.
|
| 177 |
+
|
| 178 |
+
Additionally, to explore other exciting integrations with Ultralytics, check out the [integration guide page](../integrations/index.md), which offers a wealth of resources and information.
|
| 179 |
+
|
| 180 |
+
## FAQ
|
| 181 |
+
|
| 182 |
+
### How do I integrate Comet ML with Ultralytics YOLOv8 for training?
|
| 183 |
+
|
| 184 |
+
To integrate Comet ML with Ultralytics YOLOv8, follow these steps:
|
| 185 |
+
|
| 186 |
+
1. **Install the required packages**:
|
| 187 |
+
|
| 188 |
+
```bash
|
| 189 |
+
pip install ultralytics comet_ml torch torchvision
|
| 190 |
+
```
|
| 191 |
+
|
| 192 |
+
2. **Set up your Comet API Key**:
|
| 193 |
+
|
| 194 |
+
```bash
|
| 195 |
+
export COMET_API_KEY=<Your API Key>
|
| 196 |
+
```
|
| 197 |
+
|
| 198 |
+
3. **Initialize your Comet project in your Python code**:
|
| 199 |
+
|
| 200 |
+
```python
|
| 201 |
+
import comet_ml
|
| 202 |
+
|
| 203 |
+
comet_ml.login(project_name="comet-example-yolov8-coco128")
|
| 204 |
+
```
|
| 205 |
+
|
| 206 |
+
4. **Train your YOLOv8 model and log metrics**:
|
| 207 |
+
|
| 208 |
+
```python
|
| 209 |
+
from ultralytics import YOLO
|
| 210 |
+
|
| 211 |
+
model = YOLO("yolov8n.pt")
|
| 212 |
+
results = model.train(
|
| 213 |
+
data="coco8.yaml",
|
| 214 |
+
project="comet-example-yolov8-coco128",
|
| 215 |
+
batch=32,
|
| 216 |
+
save_period=1,
|
| 217 |
+
save_json=True,
|
| 218 |
+
epochs=3,
|
| 219 |
+
)
|
| 220 |
+
```
|
| 221 |
+
|
| 222 |
+
For more detailed instructions, refer to the [Comet ML configuration section](#configuring-comet-ml).
|
| 223 |
+
|
| 224 |
+
### What are the benefits of using Comet ML with YOLOv8?
|
| 225 |
+
|
| 226 |
+
By integrating Ultralytics YOLOv8 with Comet ML, you can:
|
| 227 |
+
|
| 228 |
+
- **Monitor real-time insights**: Get instant feedback on your training results, allowing for quick adjustments.
|
| 229 |
+
- **Log extensive metrics**: Automatically capture essential metrics such as mAP, loss, hyperparameters, and model checkpoints.
|
| 230 |
+
- **Track experiments offline**: Log your training runs locally when internet access is unavailable.
|
| 231 |
+
- **Compare different training runs**: Use the interactive Comet ML dashboard to analyze and compare multiple experiments.
|
| 232 |
+
|
| 233 |
+
By leveraging these features, you can optimize your machine learning workflows for better performance and reproducibility. For more information, visit the [Comet ML integration guide](../integrations/index.md).
|
| 234 |
+
|
| 235 |
+
### How do I customize the logging behavior of Comet ML during YOLOv8 training?
|
| 236 |
+
|
| 237 |
+
Comet ML allows for extensive customization of its logging behavior using environment variables:
|
| 238 |
+
|
| 239 |
+
- **Change the number of image predictions logged**:
|
| 240 |
+
|
| 241 |
+
```python
|
| 242 |
+
import os
|
| 243 |
+
|
| 244 |
+
os.environ["COMET_MAX_IMAGE_PREDICTIONS"] = "200"
|
| 245 |
+
```
|
| 246 |
+
|
| 247 |
+
- **Adjust batch logging interval**:
|
| 248 |
+
|
| 249 |
+
```python
|
| 250 |
+
import os
|
| 251 |
+
|
| 252 |
+
os.environ["COMET_EVAL_BATCH_LOGGING_INTERVAL"] = "4"
|
| 253 |
+
```
|
| 254 |
+
|
| 255 |
+
- **Disable confusion matrix logging**:
|
| 256 |
+
|
| 257 |
+
```python
|
| 258 |
+
import os
|
| 259 |
+
|
| 260 |
+
os.environ["COMET_EVAL_LOG_CONFUSION_MATRIX"] = "false"
|
| 261 |
+
```
|
| 262 |
+
|
| 263 |
+
Refer to the [Customizing Comet ML Logging](#customizing-comet-ml-logging) section for more customization options.
|
| 264 |
+
|
| 265 |
+
### How do I view detailed metrics and visualizations of my YOLOv8 training on Comet ML?
|
| 266 |
+
|
| 267 |
+
Once your YOLOv8 model starts training, you can access a wide range of metrics and visualizations on the Comet ML dashboard. Key features include:
|
| 268 |
+
|
| 269 |
+
- **Experiment Panels**: View different runs and their metrics, including segment mask loss, class loss, and mean average precision.
|
| 270 |
+
- **Metrics**: Examine metrics in tabular format for detailed analysis.
|
| 271 |
+
- **Interactive Confusion Matrix**: Assess classification accuracy with an interactive confusion matrix.
|
| 272 |
+
- **System Metrics**: Monitor GPU and CPU utilization, memory usage, and other system metrics.
|
| 273 |
+
|
| 274 |
+
For a detailed overview of these features, visit the [Understanding Your Model's Performance with Comet ML Visualizations](#understanding-your-models-performance-with-comet-ml-visualizations) section.
|
| 275 |
+
|
| 276 |
+
### Can I use Comet ML for offline logging when training YOLOv8 models?
|
| 277 |
+
|
| 278 |
+
Yes, you can enable offline logging in Comet ML by setting the `COMET_MODE` environment variable to "offline":
|
| 279 |
+
|
| 280 |
+
```python
|
| 281 |
+
import os
|
| 282 |
+
|
| 283 |
+
os.environ["COMET_MODE"] = "offline"
|
| 284 |
+
```
|
| 285 |
+
|
| 286 |
+
This feature allows you to log your experiment data locally, which can later be uploaded to Comet ML when internet connectivity is available. This is particularly useful when working in environments with limited internet access. For more details, refer to the [Offline Logging](#offline-logging) section.
|
ultralytics/docs/en/integrations/coreml.md
ADDED
|
@@ -0,0 +1,218 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
comments: true
|
| 3 |
+
description: Learn how to export YOLOv8 models to CoreML for optimized, on-device machine learning on iOS and macOS. Follow step-by-step instructions.
|
| 4 |
+
keywords: CoreML export, YOLOv8 models, CoreML conversion, Ultralytics, iOS object detection, macOS machine learning, AI deployment, machine learning integration
|
| 5 |
+
---
|
| 6 |
+
|
| 7 |
+
# CoreML Export for YOLOv8 Models
|
| 8 |
+
|
| 9 |
+
Deploying computer vision models on Apple devices like iPhones and Macs requires a format that ensures seamless performance.
|
| 10 |
+
|
| 11 |
+
The CoreML export format allows you to optimize your [Ultralytics YOLOv8](https://github.com/ultralytics/ultralytics) models for efficient object detection in iOS and macOS applications. In this guide, we'll walk you through the steps for converting your models to the CoreML format, making it easier for your models to perform well on Apple devices.
|
| 12 |
+
|
| 13 |
+
## CoreML
|
| 14 |
+
|
| 15 |
+
<p align="center">
|
| 16 |
+
<img width="100%" src="https://github.com/ultralytics/docs/releases/download/0/coreml-overview.avif" alt="CoreML Overview">
|
| 17 |
+
</p>
|
| 18 |
+
|
| 19 |
+
[CoreML](https://developer.apple.com/documentation/coreml) is Apple's foundational machine learning framework that builds upon Accelerate, BNNS, and Metal Performance Shaders. It provides a machine-learning model format that seamlessly integrates into iOS applications and supports tasks such as image analysis, natural language processing, audio-to-text conversion, and sound analysis.
|
| 20 |
+
|
| 21 |
+
Applications can take advantage of Core ML without the need to have a network connection or API calls because the Core ML framework works using on-device computing. This means model inference can be performed locally on the user's device.
|
| 22 |
+
|
| 23 |
+
## Key Features of CoreML Models
|
| 24 |
+
|
| 25 |
+
Apple's CoreML framework offers robust features for on-device machine learning. Here are the key features that make CoreML a powerful tool for developers:
|
| 26 |
+
|
| 27 |
+
- **Comprehensive Model Support**: Converts and runs models from popular frameworks like TensorFlow, PyTorch, scikit-learn, XGBoost, and LibSVM.
|
| 28 |
+
|
| 29 |
+
<p align="center">
|
| 30 |
+
<img width="100%" src="https://github.com/ultralytics/docs/releases/download/0/coreml-supported-models.avif" alt="CoreML Supported Models">
|
| 31 |
+
</p>
|
| 32 |
+
|
| 33 |
+
- **On-device Machine Learning**: Ensures data privacy and swift processing by executing models directly on the user's device, eliminating the need for network connectivity.
|
| 34 |
+
|
| 35 |
+
- **Performance and Optimization**: Uses the device's CPU, GPU, and Neural Engine for optimal performance with minimal power and memory usage. Offers tools for model compression and optimization while maintaining accuracy.
|
| 36 |
+
|
| 37 |
+
- **Ease of Integration**: Provides a unified format for various model types and a user-friendly API for seamless integration into apps. Supports domain-specific tasks through frameworks like Vision and Natural Language.
|
| 38 |
+
|
| 39 |
+
- **Advanced Features**: Includes on-device training capabilities for personalized experiences, asynchronous predictions for interactive ML experiences, and model inspection and validation tools.
|
| 40 |
+
|
| 41 |
+
## CoreML Deployment Options
|
| 42 |
+
|
| 43 |
+
Before we look at the code for exporting YOLOv8 models to the CoreML format, let's understand where CoreML models are usually used.
|
| 44 |
+
|
| 45 |
+
CoreML offers various deployment options for machine learning models, including:
|
| 46 |
+
|
| 47 |
+
- **On-Device Deployment**: This method directly integrates CoreML models into your iOS app. It's particularly advantageous for ensuring low latency, enhanced privacy (since data remains on the device), and offline functionality. This approach, however, may be limited by the device's hardware capabilities, especially for larger and more complex models. On-device deployment can be executed in the following two ways.
|
| 48 |
+
|
| 49 |
+
- **Embedded Models**: These models are included in the app bundle and are immediately accessible. They are ideal for small models that do not require frequent updates.
|
| 50 |
+
|
| 51 |
+
- **Downloaded Models**: These models are fetched from a server as needed. This approach is suitable for larger models or those needing regular updates. It helps keep the app bundle size smaller.
|
| 52 |
+
|
| 53 |
+
- **Cloud-Based Deployment**: CoreML models are hosted on servers and accessed by the iOS app through API requests. This scalable and flexible option enables easy model updates without app revisions. It's ideal for complex models or large-scale apps requiring regular updates. However, it does require an internet connection and may pose latency and security issues.
|
| 54 |
+
|
| 55 |
+
## Exporting YOLOv8 Models to CoreML
|
| 56 |
+
|
| 57 |
+
Exporting YOLOv8 to CoreML enables optimized, on-device machine learning performance within Apple's ecosystem, offering benefits in terms of efficiency, security, and seamless integration with iOS, macOS, watchOS, and tvOS platforms.
|
| 58 |
+
|
| 59 |
+
### Installation
|
| 60 |
+
|
| 61 |
+
To install the required package, run:
|
| 62 |
+
|
| 63 |
+
!!! tip "Installation"
|
| 64 |
+
|
| 65 |
+
=== "CLI"
|
| 66 |
+
|
| 67 |
+
```bash
|
| 68 |
+
# Install the required package for YOLOv8
|
| 69 |
+
pip install ultralytics
|
| 70 |
+
```
|
| 71 |
+
|
| 72 |
+
For detailed instructions and best practices related to the installation process, check our [YOLOv8 Installation guide](../quickstart.md). While installing the required packages for YOLOv8, if you encounter any difficulties, consult our [Common Issues guide](../guides/yolo-common-issues.md) for solutions and tips.
|
| 73 |
+
|
| 74 |
+
### Usage
|
| 75 |
+
|
| 76 |
+
Before diving into the usage instructions, be sure to check out the range of [YOLOv8 models offered by Ultralytics](../models/index.md). This will help you choose the most appropriate model for your project requirements.
|
| 77 |
+
|
| 78 |
+
!!! example "Usage"
|
| 79 |
+
|
| 80 |
+
=== "Python"
|
| 81 |
+
|
| 82 |
+
```python
|
| 83 |
+
from ultralytics import YOLO
|
| 84 |
+
|
| 85 |
+
# Load the YOLOv8 model
|
| 86 |
+
model = YOLO("yolov8n.pt")
|
| 87 |
+
|
| 88 |
+
# Export the model to CoreML format
|
| 89 |
+
model.export(format="coreml") # creates 'yolov8n.mlpackage'
|
| 90 |
+
|
| 91 |
+
# Load the exported CoreML model
|
| 92 |
+
coreml_model = YOLO("yolov8n.mlpackage")
|
| 93 |
+
|
| 94 |
+
# Run inference
|
| 95 |
+
results = coreml_model("https://ultralytics.com/images/bus.jpg")
|
| 96 |
+
```
|
| 97 |
+
|
| 98 |
+
=== "CLI"
|
| 99 |
+
|
| 100 |
+
```bash
|
| 101 |
+
# Export a YOLOv8n PyTorch model to CoreML format
|
| 102 |
+
yolo export model=yolov8n.pt format=coreml # creates 'yolov8n.mlpackage''
|
| 103 |
+
|
| 104 |
+
# Run inference with the exported model
|
| 105 |
+
yolo predict model=yolov8n.mlpackage source='https://ultralytics.com/images/bus.jpg'
|
| 106 |
+
```
|
| 107 |
+
|
| 108 |
+
For more details about the export process, visit the [Ultralytics documentation page on exporting](../modes/export.md).
|
| 109 |
+
|
| 110 |
+
## Deploying Exported YOLOv8 CoreML Models
|
| 111 |
+
|
| 112 |
+
Having successfully exported your Ultralytics YOLOv8 models to CoreML, the next critical phase is deploying these models effectively. For detailed guidance on deploying CoreML models in various environments, check out these resources:
|
| 113 |
+
|
| 114 |
+
- **[CoreML Tools](https://apple.github.io/coremltools/docs-guides/)**: This guide includes instructions and examples to convert models from TensorFlow, PyTorch, and other libraries to Core ML.
|
| 115 |
+
|
| 116 |
+
- **[ML and Vision](https://developer.apple.com/videos/)**: A collection of comprehensive videos that cover various aspects of using and implementing CoreML models.
|
| 117 |
+
|
| 118 |
+
- **[Integrating a Core ML Model into Your App](https://developer.apple.com/documentation/coreml/integrating-a-core-ml-model-into-your-app)**: A comprehensive guide on integrating a CoreML model into an iOS application, detailing steps from preparing the model to implementing it in the app for various functionalities.
|
| 119 |
+
|
| 120 |
+
## Summary
|
| 121 |
+
|
| 122 |
+
In this guide, we went over how to export Ultralytics YOLOv8 models to CoreML format. By following the steps outlined in this guide, you can ensure maximum compatibility and performance when exporting YOLOv8 models to CoreML.
|
| 123 |
+
|
| 124 |
+
For further details on usage, visit the [CoreML official documentation](https://developer.apple.com/documentation/coreml).
|
| 125 |
+
|
| 126 |
+
Also, if you'd like to know more about other Ultralytics YOLOv8 integrations, visit our [integration guide page](../integrations/index.md). You'll find plenty of valuable resources and insights there.
|
| 127 |
+
|
| 128 |
+
## FAQ
|
| 129 |
+
|
| 130 |
+
### How do I export YOLOv8 models to CoreML format?
|
| 131 |
+
|
| 132 |
+
To export your [Ultralytics YOLOv8](https://github.com/ultralytics/ultralytics) models to CoreML format, you'll first need to ensure you have the `ultralytics` package installed. You can install it using:
|
| 133 |
+
|
| 134 |
+
!!! example "Installation"
|
| 135 |
+
|
| 136 |
+
=== "CLI"
|
| 137 |
+
|
| 138 |
+
```bash
|
| 139 |
+
pip install ultralytics
|
| 140 |
+
```
|
| 141 |
+
|
| 142 |
+
Next, you can export the model using the following Python or CLI commands:
|
| 143 |
+
|
| 144 |
+
!!! example "Usage"
|
| 145 |
+
|
| 146 |
+
=== "Python"
|
| 147 |
+
|
| 148 |
+
```python
|
| 149 |
+
from ultralytics import YOLO
|
| 150 |
+
|
| 151 |
+
model = YOLO("yolov8n.pt")
|
| 152 |
+
model.export(format="coreml")
|
| 153 |
+
```
|
| 154 |
+
|
| 155 |
+
=== "CLI"
|
| 156 |
+
|
| 157 |
+
```bash
|
| 158 |
+
yolo export model=yolov8n.pt format=coreml
|
| 159 |
+
```
|
| 160 |
+
|
| 161 |
+
For further details, refer to the [Exporting YOLOv8 Models to CoreML](../modes/export.md) section of our documentation.
|
| 162 |
+
|
| 163 |
+
### What are the benefits of using CoreML for deploying YOLOv8 models?
|
| 164 |
+
|
| 165 |
+
CoreML provides numerous advantages for deploying [Ultralytics YOLOv8](https://github.com/ultralytics/ultralytics) models on Apple devices:
|
| 166 |
+
|
| 167 |
+
- **On-device Processing**: Enables local model inference on devices, ensuring data privacy and minimizing latency.
|
| 168 |
+
- **Performance Optimization**: Leverages the full potential of the device's CPU, GPU, and Neural Engine, optimizing both speed and efficiency.
|
| 169 |
+
- **Ease of Integration**: Offers a seamless integration experience with Apple's ecosystems, including iOS, macOS, watchOS, and tvOS.
|
| 170 |
+
- **Versatility**: Supports a wide range of machine learning tasks such as image analysis, audio processing, and natural language processing using the CoreML framework.
|
| 171 |
+
|
| 172 |
+
For more details on integrating your CoreML model into an iOS app, check out the guide on [Integrating a Core ML Model into Your App](https://developer.apple.com/documentation/coreml/integrating-a-core-ml-model-into-your-app).
|
| 173 |
+
|
| 174 |
+
### What are the deployment options for YOLOv8 models exported to CoreML?
|
| 175 |
+
|
| 176 |
+
Once you export your YOLOv8 model to CoreML format, you have multiple deployment options:
|
| 177 |
+
|
| 178 |
+
1. **On-Device Deployment**: Directly integrate CoreML models into your app for enhanced privacy and offline functionality. This can be done as:
|
| 179 |
+
|
| 180 |
+
- **Embedded Models**: Included in the app bundle, accessible immediately.
|
| 181 |
+
- **Downloaded Models**: Fetched from a server as needed, keeping the app bundle size smaller.
|
| 182 |
+
|
| 183 |
+
2. **Cloud-Based Deployment**: Host CoreML models on servers and access them via API requests. This approach supports easier updates and can handle more complex models.
|
| 184 |
+
|
| 185 |
+
For detailed guidance on deploying CoreML models, refer to [CoreML Deployment Options](#coreml-deployment-options).
|
| 186 |
+
|
| 187 |
+
### How does CoreML ensure optimized performance for YOLOv8 models?
|
| 188 |
+
|
| 189 |
+
CoreML ensures optimized performance for [Ultralytics YOLOv8](https://github.com/ultralytics/ultralytics) models by utilizing various optimization techniques:
|
| 190 |
+
|
| 191 |
+
- **Hardware Acceleration**: Uses the device's CPU, GPU, and Neural Engine for efficient computation.
|
| 192 |
+
- **Model Compression**: Provides tools for compressing models to reduce their footprint without compromising accuracy.
|
| 193 |
+
- **Adaptive Inference**: Adjusts inference based on the device's capabilities to maintain a balance between speed and performance.
|
| 194 |
+
|
| 195 |
+
For more information on performance optimization, visit the [CoreML official documentation](https://developer.apple.com/documentation/coreml).
|
| 196 |
+
|
| 197 |
+
### Can I run inference directly with the exported CoreML model?
|
| 198 |
+
|
| 199 |
+
Yes, you can run inference directly using the exported CoreML model. Below are the commands for Python and CLI:
|
| 200 |
+
|
| 201 |
+
!!! example "Running Inference"
|
| 202 |
+
|
| 203 |
+
=== "Python"
|
| 204 |
+
|
| 205 |
+
```python
|
| 206 |
+
from ultralytics import YOLO
|
| 207 |
+
|
| 208 |
+
coreml_model = YOLO("yolov8n.mlpackage")
|
| 209 |
+
results = coreml_model("https://ultralytics.com/images/bus.jpg")
|
| 210 |
+
```
|
| 211 |
+
|
| 212 |
+
=== "CLI"
|
| 213 |
+
|
| 214 |
+
```bash
|
| 215 |
+
yolo predict model=yolov8n.mlpackage source='https://ultralytics.com/images/bus.jpg'
|
| 216 |
+
```
|
| 217 |
+
|
| 218 |
+
For additional information, refer to the [Usage section](#usage) of the CoreML export guide.
|
ultralytics/docs/en/integrations/dvc.md
ADDED
|
@@ -0,0 +1,278 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
comments: true
|
| 3 |
+
description: Unlock seamless YOLOv8 tracking with DVCLive. Discover how to log, visualize, and analyze experiments for optimized ML model performance.
|
| 4 |
+
keywords: YOLOv8, DVCLive, experiment tracking, machine learning, model training, data visualization, Git integration
|
| 5 |
+
---
|
| 6 |
+
|
| 7 |
+
# Advanced YOLOv8 Experiment Tracking with DVCLive
|
| 8 |
+
|
| 9 |
+
Experiment tracking in machine learning is critical to model development and evaluation. It involves recording and analyzing various parameters, metrics, and outcomes from numerous training runs. This process is essential for understanding model performance and making data-driven decisions to refine and optimize models.
|
| 10 |
+
|
| 11 |
+
Integrating DVCLive with [Ultralytics YOLOv8](https://www.ultralytics.com/) transforms the way experiments are tracked and managed. This integration offers a seamless solution for automatically logging key experiment details, comparing results across different runs, and visualizing data for in-depth analysis. In this guide, we'll understand how DVCLive can be used to streamline the process.
|
| 12 |
+
|
| 13 |
+
## DVCLive
|
| 14 |
+
|
| 15 |
+
<p align="center">
|
| 16 |
+
<img width="640" src="https://github.com/ultralytics/docs/releases/download/0/dvclive-overview.avif" alt="DVCLive Overview">
|
| 17 |
+
</p>
|
| 18 |
+
|
| 19 |
+
[DVCLive](https://dvc.org/doc/dvclive), developed by DVC, is an innovative open-source tool for experiment tracking in machine learning. Integrating seamlessly with Git and DVC, it automates the logging of crucial experiment data like model parameters and training metrics. Designed for simplicity, DVCLive enables effortless comparison and analysis of multiple runs, enhancing the efficiency of machine learning projects with intuitive data visualization and analysis tools.
|
| 20 |
+
|
| 21 |
+
## YOLOv8 Training with DVCLive
|
| 22 |
+
|
| 23 |
+
YOLOv8 training sessions can be effectively monitored with DVCLive. Additionally, DVC provides integral features for visualizing these experiments, including the generation of a report that enables the comparison of metric plots across all tracked experiments, offering a comprehensive view of the training process.
|
| 24 |
+
|
| 25 |
+
## Installation
|
| 26 |
+
|
| 27 |
+
To install the required packages, run:
|
| 28 |
+
|
| 29 |
+
!!! tip "Installation"
|
| 30 |
+
|
| 31 |
+
=== "CLI"
|
| 32 |
+
|
| 33 |
+
```bash
|
| 34 |
+
# Install the required packages for YOLOv8 and DVCLive
|
| 35 |
+
pip install ultralytics dvclive
|
| 36 |
+
```
|
| 37 |
+
|
| 38 |
+
For detailed instructions and best practices related to the installation process, be sure to check our [YOLOv8 Installation guide](../quickstart.md). While installing the required packages for YOLOv8, if you encounter any difficulties, consult our [Common Issues guide](../guides/yolo-common-issues.md) for solutions and tips.
|
| 39 |
+
|
| 40 |
+
## Configuring DVCLive
|
| 41 |
+
|
| 42 |
+
Once you have installed the necessary packages, the next step is to set up and configure your environment with the necessary credentials. This setup ensures a smooth integration of DVCLive into your existing workflow.
|
| 43 |
+
|
| 44 |
+
Begin by initializing a Git repository, as Git plays a crucial role in version control for both your code and DVCLive configurations.
|
| 45 |
+
|
| 46 |
+
!!! tip "Initial Environment Setup"
|
| 47 |
+
|
| 48 |
+
=== "CLI"
|
| 49 |
+
|
| 50 |
+
```bash
|
| 51 |
+
# Initialize a Git repository
|
| 52 |
+
git init -q
|
| 53 |
+
|
| 54 |
+
# Configure Git with your details
|
| 55 |
+
git config --local user.email "you@example.com"
|
| 56 |
+
git config --local user.name "Your Name"
|
| 57 |
+
|
| 58 |
+
# Initialize DVCLive in your project
|
| 59 |
+
dvc init -q
|
| 60 |
+
|
| 61 |
+
# Commit the DVCLive setup to your Git repository
|
| 62 |
+
git commit -m "DVC init"
|
| 63 |
+
```
|
| 64 |
+
|
| 65 |
+
In these commands, ensure to replace "you@example.com" with the email address associated with your Git account, and "Your Name" with your Git account username.
|
| 66 |
+
|
| 67 |
+
## Usage
|
| 68 |
+
|
| 69 |
+
Before diving into the usage instructions, be sure to check out the range of [YOLOv8 models offered by Ultralytics](../models/index.md). This will help you choose the most appropriate model for your project requirements.
|
| 70 |
+
|
| 71 |
+
### Training YOLOv8 Models with DVCLive
|
| 72 |
+
|
| 73 |
+
Start by running your YOLOv8 training sessions. You can use different model configurations and training parameters to suit your project needs. For instance:
|
| 74 |
+
|
| 75 |
+
```bash
|
| 76 |
+
# Example training commands for YOLOv8 with varying configurations
|
| 77 |
+
yolo train model=yolov8n.pt data=coco8.yaml epochs=5 imgsz=512
|
| 78 |
+
yolo train model=yolov8n.pt data=coco8.yaml epochs=5 imgsz=640
|
| 79 |
+
```
|
| 80 |
+
|
| 81 |
+
Adjust the model, data, epochs, and imgsz parameters according to your specific requirements. For a detailed understanding of the model training process and best practices, refer to our [YOLOv8 Model Training guide](../modes/train.md).
|
| 82 |
+
|
| 83 |
+
### Monitoring Experiments with DVCLive
|
| 84 |
+
|
| 85 |
+
DVCLive enhances the training process by enabling the tracking and visualization of key metrics. When installed, Ultralytics YOLOv8 automatically integrates with DVCLive for experiment tracking, which you can later analyze for performance insights. For a comprehensive understanding of the specific performance metrics used during training, be sure to explore [our detailed guide on performance metrics](../guides/yolo-performance-metrics.md).
|
| 86 |
+
|
| 87 |
+
### Analyzing Results
|
| 88 |
+
|
| 89 |
+
After your YOLOv8 training sessions are complete, you can leverage DVCLive's powerful visualization tools for in-depth analysis of the results. DVCLive's integration ensures that all training metrics are systematically logged, facilitating a comprehensive evaluation of your model's performance.
|
| 90 |
+
|
| 91 |
+
To start the analysis, you can extract the experiment data using DVC's API and process it with Pandas for easier handling and visualization:
|
| 92 |
+
|
| 93 |
+
```python
|
| 94 |
+
import dvc.api
|
| 95 |
+
import pandas as pd
|
| 96 |
+
|
| 97 |
+
# Define the columns of interest
|
| 98 |
+
columns = ["Experiment", "epochs", "imgsz", "model", "metrics.mAP50-95(B)"]
|
| 99 |
+
|
| 100 |
+
# Retrieve experiment data
|
| 101 |
+
df = pd.DataFrame(dvc.api.exp_show(), columns=columns)
|
| 102 |
+
|
| 103 |
+
# Clean the data
|
| 104 |
+
df.dropna(inplace=True)
|
| 105 |
+
df.reset_index(drop=True, inplace=True)
|
| 106 |
+
|
| 107 |
+
# Display the DataFrame
|
| 108 |
+
print(df)
|
| 109 |
+
```
|
| 110 |
+
|
| 111 |
+
The output of the code snippet above provides a clear tabular view of the different experiments conducted with YOLOv8 models. Each row represents a different training run, detailing the experiment's name, the number of epochs, image size (imgsz), the specific model used, and the mAP50-95(B) metric. This metric is crucial for evaluating the model's accuracy, with higher values indicating better performance.
|
| 112 |
+
|
| 113 |
+
#### Visualizing Results with Plotly
|
| 114 |
+
|
| 115 |
+
For a more interactive and visual analysis of your experiment results, you can use Plotly's parallel coordinates plot. This type of plot is particularly useful for understanding the relationships and trade-offs between different parameters and metrics.
|
| 116 |
+
|
| 117 |
+
```python
|
| 118 |
+
from plotly.express import parallel_coordinates
|
| 119 |
+
|
| 120 |
+
# Create a parallel coordinates plot
|
| 121 |
+
fig = parallel_coordinates(df, columns, color="metrics.mAP50-95(B)")
|
| 122 |
+
|
| 123 |
+
# Display the plot
|
| 124 |
+
fig.show()
|
| 125 |
+
```
|
| 126 |
+
|
| 127 |
+
The output of the code snippet above generates a plot that will visually represent the relationships between epochs, image size, model type, and their corresponding mAP50-95(B) scores, enabling you to spot trends and patterns in your experiment data.
|
| 128 |
+
|
| 129 |
+
#### Generating Comparative Visualizations with DVC
|
| 130 |
+
|
| 131 |
+
DVC provides a useful command to generate comparative plots for your experiments. This can be especially helpful to compare the performance of different models over various training runs.
|
| 132 |
+
|
| 133 |
+
```bash
|
| 134 |
+
# Generate DVC comparative plots
|
| 135 |
+
dvc plots diff $(dvc exp list --names-only)
|
| 136 |
+
```
|
| 137 |
+
|
| 138 |
+
After executing this command, DVC generates plots comparing the metrics across different experiments, which are saved as HTML files. Below is an example image illustrating typical plots generated by this process. The image showcases various graphs, including those representing mAP, recall, precision, loss values, and more, providing a visual overview of key performance metrics:
|
| 139 |
+
|
| 140 |
+
<p align="center">
|
| 141 |
+
<img width="640" src="https://github.com/ultralytics/docs/releases/download/0/dvclive-comparative-plots.avif" alt="DVCLive Plots">
|
| 142 |
+
</p>
|
| 143 |
+
|
| 144 |
+
### Displaying DVC Plots
|
| 145 |
+
|
| 146 |
+
If you are using a Jupyter Notebook and you want to display the generated DVC plots, you can use the IPython display functionality.
|
| 147 |
+
|
| 148 |
+
```python
|
| 149 |
+
from IPython.display import HTML
|
| 150 |
+
|
| 151 |
+
# Display the DVC plots as HTML
|
| 152 |
+
HTML(filename="./dvc_plots/index.html")
|
| 153 |
+
```
|
| 154 |
+
|
| 155 |
+
This code will render the HTML file containing the DVC plots directly in your Jupyter Notebook, providing an easy and convenient way to analyze the visualized experiment data.
|
| 156 |
+
|
| 157 |
+
### Making Data-Driven Decisions
|
| 158 |
+
|
| 159 |
+
Use the insights gained from these visualizations to make informed decisions about model optimizations, hyperparameter tuning, and other modifications to enhance your model's performance.
|
| 160 |
+
|
| 161 |
+
### Iterating on Experiments
|
| 162 |
+
|
| 163 |
+
Based on your analysis, iterate on your experiments. Adjust model configurations, training parameters, or even the data inputs, and repeat the training and analysis process. This iterative approach is key to refining your model for the best possible performance.
|
| 164 |
+
|
| 165 |
+
## Summary
|
| 166 |
+
|
| 167 |
+
This guide has led you through the process of integrating DVCLive with Ultralytics' YOLOv8. You have learned how to harness the power of DVCLive for detailed experiment monitoring, effective visualization, and insightful analysis in your machine learning endeavors.
|
| 168 |
+
|
| 169 |
+
For further details on usage, visit [DVCLive's official documentation](https://dvc.org/doc/dvclive/ml-frameworks/yolo).
|
| 170 |
+
|
| 171 |
+
Additionally, explore more integrations and capabilities of Ultralytics by visiting the [Ultralytics integration guide page](../integrations/index.md), which is a collection of great resources and insights.
|
| 172 |
+
|
| 173 |
+
## FAQ
|
| 174 |
+
|
| 175 |
+
### How do I integrate DVCLive with Ultralytics YOLOv8 for experiment tracking?
|
| 176 |
+
|
| 177 |
+
Integrating DVCLive with Ultralytics YOLOv8 is straightforward. Start by installing the necessary packages:
|
| 178 |
+
|
| 179 |
+
!!! example "Installation"
|
| 180 |
+
|
| 181 |
+
=== "CLI"
|
| 182 |
+
|
| 183 |
+
```bash
|
| 184 |
+
pip install ultralytics dvclive
|
| 185 |
+
```
|
| 186 |
+
|
| 187 |
+
Next, initialize a Git repository and configure DVCLive in your project:
|
| 188 |
+
|
| 189 |
+
!!! example "Initial Environment Setup"
|
| 190 |
+
|
| 191 |
+
=== "CLI"
|
| 192 |
+
|
| 193 |
+
```bash
|
| 194 |
+
git init -q
|
| 195 |
+
git config --local user.email "you@example.com"
|
| 196 |
+
git config --local user.name "Your Name"
|
| 197 |
+
dvc init -q
|
| 198 |
+
git commit -m "DVC init"
|
| 199 |
+
```
|
| 200 |
+
|
| 201 |
+
Follow our [YOLOv8 Installation guide](../quickstart.md) for detailed setup instructions.
|
| 202 |
+
|
| 203 |
+
### Why should I use DVCLive for tracking YOLOv8 experiments?
|
| 204 |
+
|
| 205 |
+
Using DVCLive with YOLOv8 provides several advantages, such as:
|
| 206 |
+
|
| 207 |
+
- **Automated Logging**: DVCLive automatically records key experiment details like model parameters and metrics.
|
| 208 |
+
- **Easy Comparison**: Facilitates comparison of results across different runs.
|
| 209 |
+
- **Visualization Tools**: Leverages DVCLive's robust data visualization capabilities for in-depth analysis.
|
| 210 |
+
|
| 211 |
+
For further details, refer to our guide on [YOLOv8 Model Training](../modes/train.md) and [YOLO Performance Metrics](../guides/yolo-performance-metrics.md) to maximize your experiment tracking efficiency.
|
| 212 |
+
|
| 213 |
+
### How can DVCLive improve my results analysis for YOLOv8 training sessions?
|
| 214 |
+
|
| 215 |
+
After completing your YOLOv8 training sessions, DVCLive helps in visualizing and analyzing the results effectively. Example code for loading and displaying experiment data:
|
| 216 |
+
|
| 217 |
+
```python
|
| 218 |
+
import dvc.api
|
| 219 |
+
import pandas as pd
|
| 220 |
+
|
| 221 |
+
# Define columns of interest
|
| 222 |
+
columns = ["Experiment", "epochs", "imgsz", "model", "metrics.mAP50-95(B)"]
|
| 223 |
+
|
| 224 |
+
# Retrieve experiment data
|
| 225 |
+
df = pd.DataFrame(dvc.api.exp_show(), columns=columns)
|
| 226 |
+
|
| 227 |
+
# Clean data
|
| 228 |
+
df.dropna(inplace=True)
|
| 229 |
+
df.reset_index(drop=True, inplace=True)
|
| 230 |
+
|
| 231 |
+
# Display DataFrame
|
| 232 |
+
print(df)
|
| 233 |
+
```
|
| 234 |
+
|
| 235 |
+
To visualize results interactively, use Plotly's parallel coordinates plot:
|
| 236 |
+
|
| 237 |
+
```python
|
| 238 |
+
from plotly.express import parallel_coordinates
|
| 239 |
+
|
| 240 |
+
fig = parallel_coordinates(df, columns, color="metrics.mAP50-95(B)")
|
| 241 |
+
fig.show()
|
| 242 |
+
```
|
| 243 |
+
|
| 244 |
+
Refer to our guide on [YOLOv8 Training with DVCLive](#yolov8-training-with-dvclive) for more examples and best practices.
|
| 245 |
+
|
| 246 |
+
### What are the steps to configure my environment for DVCLive and YOLOv8 integration?
|
| 247 |
+
|
| 248 |
+
To configure your environment for a smooth integration of DVCLive and YOLOv8, follow these steps:
|
| 249 |
+
|
| 250 |
+
1. **Install Required Packages**: Use `pip install ultralytics dvclive`.
|
| 251 |
+
2. **Initialize Git Repository**: Run `git init -q`.
|
| 252 |
+
3. **Setup DVCLive**: Execute `dvc init -q`.
|
| 253 |
+
4. **Commit to Git**: Use `git commit -m "DVC init"`.
|
| 254 |
+
|
| 255 |
+
These steps ensure proper version control and setup for experiment tracking. For in-depth configuration details, visit our [Configuration guide](../quickstart.md).
|
| 256 |
+
|
| 257 |
+
### How do I visualize YOLOv8 experiment results using DVCLive?
|
| 258 |
+
|
| 259 |
+
DVCLive offers powerful tools to visualize the results of YOLOv8 experiments. Here's how you can generate comparative plots:
|
| 260 |
+
|
| 261 |
+
!!! example "Generate Comparative Plots"
|
| 262 |
+
|
| 263 |
+
=== "CLI"
|
| 264 |
+
|
| 265 |
+
```bash
|
| 266 |
+
dvc plots diff $(dvc exp list --names-only)
|
| 267 |
+
```
|
| 268 |
+
|
| 269 |
+
To display these plots in a Jupyter Notebook, use:
|
| 270 |
+
|
| 271 |
+
```python
|
| 272 |
+
from IPython.display import HTML
|
| 273 |
+
|
| 274 |
+
# Display plots as HTML
|
| 275 |
+
HTML(filename="./dvc_plots/index.html")
|
| 276 |
+
```
|
| 277 |
+
|
| 278 |
+
These visualizations help identify trends and optimize model performance. Check our detailed guides on [YOLOv8 Experiment Analysis](#analyzing-results) for comprehensive steps and examples.
|