AssertionError: File not found: data\hyps\hyp.scratch.yaml

D:\programfiles\miniconda\envs\py38torch_gpu\python.exe G:/spd-yolov5/SPD-Conv-main/YOLOv5-SPD/train.py --data ../air-filter/data.yaml --cfg models/space_depth_s.yaml --batch-size 32
train: weights=yolov5s.pt, cfg=models/space_depth_s.yaml, data=../air-filter/data.yaml, hyp=data\hyps\hyp.scratch.yaml, epochs=100, batch_size=32, imgsz=640, rect=False, resume=False, nosave=False, noval=False, noautoanchor=False, evolve=None, bucket=, cache=None, image_weights=False, device=, multi_scale=False, single_cls=False, adam=False, sync_bn=False, workers=0, project=runs\train, name=exp, exist_ok=False, quad=False, linear_lr=False, label_smoothing=0.0, patience=100, freeze=0, save_period=-1, local_rank=-1, entity=None, upload_dataset=False, bbox_interval=-1, artifact_alias=latest
github: skipping check (not a git repository), for updates see https://github.com/ultralytics/yolov5
requirements: tqdm>=4.64.0 not found and is required by YOLOv5, attempting auto-update...
WARNING: Ignoring invalid distribution -pencv-contrib-python (d:\programfiles\miniconda\envs\py38torch_gpu\lib\site-packages)
ERROR: Invalid requirement: "'tqdm"
WARNING: Ignoring invalid distribution -pencv-contrib-python (d:\programfiles\miniconda\envs\py38torch_gpu\lib\site-packages)
WARNING: Ignoring invalid distribution -pencv-contrib-python (d:\programfiles\miniconda\envs\py38torch_gpu\lib\site-packages)
WARNING: Ignoring invalid distribution -pencv-contrib-python (d:\programfiles\miniconda\envs\py38torch_gpu\lib\site-packages)
requirements: Command 'pip install 'tqdm>=4.64.0'' returned non-zero exit status 1.
requirements: tqdm>=4.64.0 not found and is required by YOLOv5, attempting auto-update...
WARNING: Ignoring invalid distribution -pencv-contrib-python (d:\programfiles\miniconda\envs\py38torch_gpu\lib\site-packages)
ERROR: Invalid requirement: "'tqdm"
WARNING: Ignoring invalid distribution -pencv-contrib-python (d:\programfiles\miniconda\envs\py38torch_gpu\lib\site-packages)
WARNING: Ignoring invalid distribution -pencv-contrib-python (d:\programfiles\miniconda\envs\py38torch_gpu\lib\site-packages)
WARNING: Ignoring invalid distribution -pencv-contrib-python (d:\programfiles\miniconda\envs\py38torch_gpu\lib\site-packages)

requirements: Command 'pip install 'tqdm>=4.64.0'' returned non-zero exit status 1.
file found
file found
file found

Traceback (most recent call last):
  File "G:/spd-yolov5/SPD-Conv-main/YOLOv5-SPD/train.py", line 632, in
    main(opt)
  File "G:/spd-yolov5/SPD-Conv-main/YOLOv5-SPD/train.py", line 505, in main
    check_file(opt.data), check_yaml(opt.cfg), check_yaml(opt.hyp), str(opt.weights), str(opt.project)  # checks
  File "G:\spd-yolov5\SPD-Conv-main\YOLOv5-SPD\utils\general.py", line 306, in check_yaml
    return check_file(file, suffix)
  File "G:\spd-yolov5\SPD-Conv-main\YOLOv5-SPD\utils\general.py", line 327, in check_file
    assert len(files), f'File not found: {file}'  # assert file was found

AssertionError: File not found: data\hyps\hyp.scratch.yaml

 requirements: Command 'pip install 'tqdm>=4.64.0'' returned non-zero exit status 1.

 file found
file found
file found

在train.py文件同级目录下,缺少相应的requirements.txt文件,需要补充相应requirements.txt文件

 AssertionError: File not found: data\hyps\hyp.scratch.yaml

在对应的文件夹下,缺少相应的文件,可以重新命名一个或者直接在train.py文件中修改

AssertionError: File not found: data\hyps\hyp.scratch.yaml_第1张图片

 AssertionError: File not found: data\hyps\hyp.scratch.yaml_第2张图片

 

你可能感兴趣的:(pytorch,计算机视觉,python,windows)