init
This commit is contained in:
commit
1096059bf3
1
.gitignore
vendored
Normal file
1
.gitignore
vendored
Normal file
@ -0,0 +1 @@
|
||||
runs
|
11
1.py
Normal file
11
1.py
Normal file
@ -0,0 +1,11 @@
|
||||
from ultralytics import YOLO
|
||||
|
||||
# Load a pre-trained YOLOv10n model
|
||||
model = YOLO("./yolov10x.pt")
|
||||
model.train(data="./dataset.yaml", epochs=3)
|
||||
|
||||
# Perform object detection on an image
|
||||
results = model("./1.jpg")
|
||||
|
||||
# Display the results
|
||||
results[0].show()
|
5
dataset.yaml
Normal file
5
dataset.yaml
Normal file
@ -0,0 +1,5 @@
|
||||
train: F:/PythonLib/yolo/demo2/dataset/train/images
|
||||
val: F:/PythonLib/yolo/demo2/dataset/val/images
|
||||
|
||||
nc: 1 # number of classes
|
||||
names: ['cabbage'] # class names
|
BIN
dataset/train/images/1.jpg
Normal file
BIN
dataset/train/images/1.jpg
Normal file
Binary file not shown.
After Width: | Height: | Size: 107 KiB |
BIN
dataset/train/labels.cache
Normal file
BIN
dataset/train/labels.cache
Normal file
Binary file not shown.
1
dataset/train/labels/1.txt
Normal file
1
dataset/train/labels/1.txt
Normal file
@ -0,0 +1 @@
|
||||
0 0.483689 0.523293 0.680901 0.762967
|
BIN
dataset/val/images/1.jpg
Normal file
BIN
dataset/val/images/1.jpg
Normal file
Binary file not shown.
After Width: | Height: | Size: 107 KiB |
BIN
dataset/val/labels.cache
Normal file
BIN
dataset/val/labels.cache
Normal file
Binary file not shown.
1
dataset/val/labels/1.txt
Normal file
1
dataset/val/labels/1.txt
Normal file
@ -0,0 +1 @@
|
||||
0 0.483689 0.523293 0.680901 0.762967
|
BIN
yolov10x.pt
Normal file
BIN
yolov10x.pt
Normal file
Binary file not shown.
Loading…
x
Reference in New Issue
Block a user