Commit
·
8b84a69
1
Parent(s):
a3be692
updates
Browse files- script.py +2 -4
- training_config.yaml +1 -1
script.py
CHANGED
@@ -27,7 +27,7 @@ def export_to_yolo_format(
|
|
27 |
samples,
|
28 |
classes,
|
29 |
label_field="ground_truth",
|
30 |
-
export_dir="
|
31 |
splits=["train", "val"]
|
32 |
):
|
33 |
"""
|
@@ -77,7 +77,7 @@ def train_model(training_dataset, training_config):
|
|
77 |
model = YOLO("yolov10m.pt")
|
78 |
|
79 |
results = model.train(
|
80 |
-
data="
|
81 |
**training_config['train_params']
|
82 |
)
|
83 |
|
@@ -86,7 +86,5 @@ def train_model(training_dataset, training_config):
|
|
86 |
|
87 |
return best_model
|
88 |
|
89 |
-
|
90 |
-
|
91 |
if __name__=="__main__":
|
92 |
run()
|
|
|
27 |
samples,
|
28 |
classes,
|
29 |
label_field="ground_truth",
|
30 |
+
export_dir=".",
|
31 |
splits=["train", "val"]
|
32 |
):
|
33 |
"""
|
|
|
77 |
model = YOLO("yolov10m.pt")
|
78 |
|
79 |
results = model.train(
|
80 |
+
data="dataset.yaml",
|
81 |
**training_config['train_params']
|
82 |
)
|
83 |
|
|
|
86 |
|
87 |
return best_model
|
88 |
|
|
|
|
|
89 |
if __name__=="__main__":
|
90 |
run()
|
training_config.yaml
CHANGED
@@ -4,7 +4,7 @@ val_split: 0.1
|
|
4 |
|
5 |
# Training parameters
|
6 |
train_params:
|
7 |
-
epochs:
|
8 |
batch: 16
|
9 |
imgsz: 640
|
10 |
lr0: 0.01
|
|
|
4 |
|
5 |
# Training parameters
|
6 |
train_params:
|
7 |
+
epochs: 1
|
8 |
batch: 16
|
9 |
imgsz: 640
|
10 |
lr0: 0.01
|