Welcome to RDK S100(P) Board repository
10.Model training - conversion
Model Training and Conversion
After completing the dataset annotation tutorial content, we can use the main board to start training the model.
This tutorial only introduces CLI model training and conversion. You can refer to the official website for Python case modifications.
1. Model Training
Use CLI commands to directly train the model: Copy the yolo26n.pt file to the directory where the configuration file is located, then open a terminal in the configuration file directory:
xxxxxxxxxxcd /home/jetson/ultralytics/ultralytics/data/yahboom_data/orange_data/
xxxxxxxxxxyolo detect train data=orange.yaml model=/home/jetson/ultralytics/yolo26n.pt epochs=100 imgsz=640
data: Dataset configuration file
model: Pre-trained model file
epochs: Number of training epochs
imgsz: Specify input image size


2. Model Conversion
The final model will be generated in the runs folder: Generally select the best.pt file for use
xxxxxxxxxx/home/jetson/ultralytics/ultralytics/data/yahboom_data/orange_data/runs/detect/train2/weights
Convert pt model to engine model:
xxxxxxxxxxcd /home/jetson/ultralytics/ultralytics/data/yahboom_data/orange_data/runs/detect/train2/weights
xxxxxxxxxxyolo export model=best.pt format=engine
