> data=/home/wuwei/dataset/args.yaml \
> model=yolov8n.pt \
> epochs=100 \
> imgsz=640 \
Traceback (most recent call last):
File "/home/wuwei/anaconda3/envs/yolov8_new/bin/yolo", line 8, in <module>
sys.exit(entrypoint())
File "/home/wuwei/anaconda3/envs/yolov8_new/lib/python3.10/site-packages/ultralytics/cfg/__init__.py", line 907, in entrypoint
check_dict_alignment(full_args_dict, {a: ""})
File "/home/wuwei/anaconda3/envs/yolov8_new/lib/python3.10/site-packages/ultralytics/cfg/__init__.py", line 498, in check_dict_alignment
raise SyntaxError(string + CLI_HELP_MSG) from e
SyntaxError: ' ' is not a valid YOLO argument.
Arguments received: ['yolo', 'detect', 'train', 'data=/home/wuwei/dataset/args.yaml', 'model=yolov8n.pt', 'epochs=100', 'imgsz=640', ' ']. Ultralytics 'yolo' commands use the following syntax:
yolo TASK MODE ARGS
Where TASK (optional) is one of ['obb', 'pose', 'detect', 'segment', 'classify']
MODE (required) is one of ['val', 'export', 'train', 'track', 'benchmark', 'predict']
ARGS (optional) are any number of custom 'arg=value' pairs like 'imgsz=320' that override defaults.
See all ARGS at https://docs.ultralytics.com/usage/cfg or with 'yolo cfg'
1. Train a detection model for 10 epochs with an initial learning_rate of 0.01
yolo train data=coco8.yaml model=yolo11n.pt epochs=10 lr0=0.01
2. Predict a YouTube video using a pretrained segmentation model at image size 320:
yolo predict model=yolo11n-seg.pt source='https://youtu.be/LNwODJXcvt4' imgsz=320
3. Val a pretrained detection model at batch-size 1 and image size 640:
yolo val model=yolo11n.pt data=coco8.yaml batch=1 imgsz=640
4. Export a YOLO11n classification model to ONNX format at image size 224 by 128 (no TASK required)
yolo export model=yolo11n-cls.pt format=onnx imgsz=224,128
5. Ultralytics solutions usage
yolo solutions count or in ['crop', 'blur', 'workout', 'heatmap', 'isegment', 'visioneye', 'speed', 'queue', 'analytics', 'inference', 'trackzone'] source="path/to/video.mp4"
6. Run special commands:
yolo help
yolo checks
yolo version
yolo settings
yolo copy-cfg
yolo cfg
yolo solutions help
Docs: https://docs.ultralytics.com
Solutions: https://docs.ultralytics.com/solutions/
Community: https://community.ultralytics.com
GitHub: https://github.com/ultralytics/ultralytics
最新发布