Fusing layers...
/home/ubuntu/anaconda3/envs/zsd-yolo/lib/python3.8/site-packages/torch/nn/functional.py:718: UserWarning: Named tensors and all their associated APIs are an experimental feature and subject to change. Please do not use them for anything important until they are released as stable. (Triggered internally at /pytorch/c10/core/TensorImpl.h:1156.)
return torch.max_pool2d(input, kernel_size, stride, padding, dilation, ceil_mode)
Model Summary: 478 layers, 90637726 parameters, 0 gradients, 228.1 GFLOPS
torch.Size([15, 512])
<class 'utils.datasets.LoadZSD'>
Removing images without annotations.
100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 10098/10098 [00:41<00:00, 241.93it/s]
Originally: 10098 train images. Found only 10098 label files.
100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 10098/10098 [00:01<00:00, 6223.93it/s]
100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 10098/10098 [00:12<00:00, 817.40it/s]
Class Images Labels P R mAP@.5 mAP@.5:.95: 100%|██████████████████████████████████████████████████████████████████████████████████████████| 505/505 [02:16<00:00, 3.71it/s]
val_names 10098 16339 0.131 0.425 0.183 0.107
hhhhhhhhhhhhhhhhhhhhhhhh
Speed: 7.0/1.5/8.6 ms inference/NMS/total per 640x640 image at batch-size 20
Recall for val_names: tensor([0.51568, 0.48178, 0.44293], device='cuda:0')
Evaluating pycocotools mAP... saving runs/test/exp/yolov5x_coco_65_15_zsd_self_predictions.json...
pycocotools unable to run: numpy.ndarray size changed, may indicate binary incompatibility. Expected 96 from C header, got 80 from PyObject
Results saved to runs/test/exp
[0.18276172723315653, 0.3208762923724822, 0.020294901101528616, 0.3624528265889396, 0.5403336046124867, 0.10132492329700706, 0.2940092284983078, 0.3952027655732882, 0.15107024279042788, 0.1186500077538415, 0.0786284506438716, 0.12871514430628675, 0.03301976264141266, 0.0111
Hi author, how do I get the results of recall and why do I get lower results using
_python3 test.py --weights weights/model_checkpoints/yolov5x_coco_65_15_zsd_self.pt --data data/coco/coco_zsd_2014_test_65_15.yaml --img 640 --save-json --zsd --annot-folder labels2014_zsd_self_test_l_6515 --obj-conf-thresh 0.1 --batch-size 20 --iou-thres 0.4 --conf-thres 0.001 --max-det 15 --verbose --exist-ok --plot-conf 0.1
than the data in the paper?The test results are as follows, (zsd-yolo) ubuntu@ylhh:/media/ubuntu/dataset/ZSD-YOLO$ python3 test.py --weights weights/model_checkpoints/yolov5x_coco_65_15_zsd_self.pt --data data/coco/coco_zsd_2014_test_65_15.yaml --img 640 --save-json --zsd --annot-folder labels2014_zsd_self_test_l_65_15 --obj-conf-thresh 0.1 --batch-size 20 --iou-thres 0.4 --conf-thres 0.001 --max-det 15 --verbose --exist-ok --plot-conf 0.1 Namespace(agnostic_nms=False, annot_folder='labels2014_zsd_self_test_l_65_15', augment=False, batch_size=20, conf_thres=0.001, data='data/coco/coco_zsd_2014_test_65_15.yaml', device='', eval_by_splits=False, eval_splits=[], exist_ok=True, favor=None, hyp=None, img_size=640, iou_thres=0.4, max_det=15, name='exp', nms_then_zsd=False, no_zsd_post=False, obj_conf_thresh=0.1, plot_conf=0.1, project='runs/test', save_conf=False, save_hybrid=False, save_json=True, save_txt=False, single_cls=False, task='val', text_embedding_path=None, verbose=True, visualization_demo=False, weights=['weights/model_checkpoints/yolov5x_coco_65_15_zsd_self.pt'], zsd=True) 20 YOLOv5 🚀 4057e6c torch 1.9.0+cu111 CUDA:0 (GeForce RTX 3090, 24267.0MB)
Fusing layers... /home/ubuntu/anaconda3/envs/zsd-yolo/lib/python3.8/site-packages/torch/nn/functional.py:718: UserWarning: Named tensors and all their associated APIs are an experimental feature and subject to change. Please do not use them for anything important until they are released as stable. (Triggered internally at /pytorch/c10/core/TensorImpl.h:1156.) return torch.max_pool2d(input, kernel_size, stride, padding, dilation, ceil_mode) Model Summary: 478 layers, 90637726 parameters, 0 gradients, 228.1 GFLOPS torch.Size([15, 512]) <class 'utils.datasets.LoadZSD'> Removing images without annotations. 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 10098/10098 [00:41<00:00, 241.93it/s] Originally: 10098 train images. Found only 10098 label files. 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 10098/10098 [00:01<00:00, 6223.93it/s] 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 10098/10098 [00:12<00:00, 817.40it/s] Class Images Labels P R mAP@.5 mAP@.5:.95: 100%|██████████████████████████████████████████████████████████████████████████████████████████| 505/505 [02:16<00:00, 3.71it/s] val_names 10098 16339 0.131 0.425 0.183 0.107 hhhhhhhhhhhhhhhhhhhhhhhh
Speed: 7.0/1.5/8.6 ms inference/NMS/total per 640x640 image at batch-size 20 Recall for val_names: tensor([0.51568, 0.48178, 0.44293], device='cuda:0')
Evaluating pycocotools mAP... saving runs/test/exp/yolov5x_coco_65_15_zsd_self_predictions.json... pycocotools unable to run: numpy.ndarray size changed, may indicate binary incompatibility. Expected 96 from C header, got 80 from PyObject Results saved to runs/test/exp [0.18276172723315653, 0.3208762923724822, 0.020294901101528616, 0.3624528265889396, 0.5403336046124867, 0.10132492329700706, 0.2940092284983078, 0.3952027655732882, 0.15107024279042788, 0.1186500077538415, 0.0786284506438716, 0.12871514430628675, 0.03301976264141266, 0.0111