centernet-pytorch
centernet-pytorch copied to clipboard
使用提供的 centernet_resnet50_voc.pth 无法得到 77% mAP
你好,我使用提供的 centernet_resnet50_voc.pth [在VOC2007测试集上只能得到67%的mAP(数据集下载和测试过程均按照readme操作),请问这个是否是得到 77% mAP模型?
pytorch 版本 1.71
nms = True
nms = True
谢谢回复, 代码没有修改过,centernet.py里的nms确实是True,模型也是链接的‘centernet_resnet50_voc.pth’。
那太奇怪了,我再试一下,我并没有修改过,你的测试集确认正确吗
那太奇怪了,我再试一下,我并没有修改过,你的测试集确认正确吗
测试集是VOC2007 test,并且全部用于测试,总共是4952个文件。运行你的yolov4-mobilenet,可以得到readme里的mAP。
yolov4-mobilenet?这个不是centernet的库吗 yolov4-mobilenet默认是mobilenet0.25本就这么低啊。人家参数就几十万。。
你问的是keras版本么
yolov4-mobilenet?这个不是centernet的库吗 yolov4-mobilenet默认是mobilenet0.25本就这么低啊。人家参数就几十万。。
我的意思是用的相同的测试集在yolov4-mobilenet项目上能得到相应readme的结果,说明测试集是没问题的。
这个centernet项目里只能得到0.67 mAP,readme里的是0.77.
都是pytorch版本
ok,我试试。
我试了一下,还是77% 关闭nms是62%,是不是版本不同会影响性能啊。我不太懂。。。
我试了一下,还是77% 关闭nms是62%,是不是版本不同会影响性能啊。我不太懂。。。
刚找了旧的GPU,试了下pytorch 1.60, 1.2.0,还有30系显卡上的1.70,都是一样0.67(nms为false 是0.44)的结果。。。请问你是把VOC2007_test里的所有sample都用于测试吗,总共4952个sample。(voc2centernet.py里trainval_percent=0, train_percent=1生成的)
`72.91% = aeroplane AP || score_threhold=0.5 : F1=0.63 ; Recall=46.67% ; Precision=96.38%
75.09% = bicycle AP || score_threhold=0.5 : F1=0.60 ; Recall=43.62% ; Precision=97.35%
63.98% = bird AP || score_threhold=0.5 : F1=0.59 ; Recall=44.23% ; Precision=87.12%
57.96% = boat AP || score_threhold=0.5 : F1=0.46 ; Recall=30.80% ; Precision=90.00%
48.31% = bottle AP || score_threhold=0.5 : F1=0.37 ; Recall=23.03% ; Precision=90.76%
76.97% = bus AP || score_threhold=0.5 : F1=0.70 ; Recall=56.34% ; Precision=90.91%
81.13% = car AP || score_threhold=0.5 : F1=0.66 ; Recall=50.12% ; Precision=97.25%
77.69% = cat AP || score_threhold=0.5 : F1=0.72 ; Recall=61.73% ; Precision=87.70%
49.49% = chair AP || score_threhold=0.5 : F1=0.26 ; Recall=15.08% ; Precision=91.94%
76.38% = cow AP || score_threhold=0.5 : F1=0.54 ; Recall=38.11% ; Precision=93.00%
61.19% = diningtable AP || score_threhold=0.5 : F1=0.38 ; Recall=23.79% ; Precision=90.74%
71.62% = dog AP || score_threhold=0.5 : F1=0.59 ; Recall=43.56% ; Precision=93.42%
82.00% = horse AP || score_threhold=0.5 : F1=0.70 ; Recall=55.17% ; Precision=96.48%
74.64% = motorbike AP || score_threhold=0.5 : F1=0.63 ; Recall=48.00% ; Precision=91.76%
76.86% = person AP || score_threhold=0.5 : F1=0.55 ; Recall=38.60% ; Precision=98.09%
30.12% = pottedplant AP || score_threhold=0.5 : F1=0.07 ; Recall=3.75% ; Precision=94.74%
70.23% = sheep AP || score_threhold=0.5 : F1=0.59 ; Recall=43.80% ; Precision=89.08%
63.93% = sofa AP || score_threhold=0.5 : F1=0.51 ; Recall=35.98% ; Precision=86.87%
78.31% = train AP || score_threhold=0.5 : F1=0.72 ; Recall=58.87% ; Precision=92.74%
70.03% = tvmonitor AP || score_threhold=0.5 : F1=0.54 ; Recall=37.66% ; Precision=96.67%
mAP = 67.94%`
我赌五毛钱,是不是你的权值是老权值,你什么时候下载的。 我这里尝试了很多遍确实是77,或者你留个邮箱,我把我的库直接整个发给你。
你百度网盘的权值和github的代码重下试试,以前的权值是用rgb图片训练的,后来的权值是用bgr图片训练的
问题找到了,原来我把resnet50 的backbone换成了pytorch官方的,导致一部分layer的weight无法载入。😂
感谢一直耐心的回复,也很欣赏这种细致的风格。已经star了
好的加油兄弟
问题找到了,原来我把resnet50 的backbone换成了pytorch官方的,导致一部分layer的weight无法载入。
感谢一直耐心的回复,也很欣赏这种细致的风格。已经star了
你好,我能看一下你“原来我把resnet50 的backbone换成了pytorch官方的,导致一部分layer的weight无法载入。joy” 的错误代码吗? 邮箱:[email protected] 谢谢
问题找到了,原来我把resnet50 的backbone换成了pytorch官方的,导致一部分layer的weight无法载入。 感谢一直耐心的回复,也很欣赏这种细致的风格。已经star了
你好,我能看一下你“原来我把resnet50 的backbone换成了pytorch官方的,导致一部分layer的weight无法载入。joy” 的错误代码吗? 邮箱:[email protected] 谢谢
并不会报错,部分weight无法的载入是我的推测,注释部分是载入官方resnet
def resnet50(pretrain = True):
model = ResNet(Bottleneck, [3, 4, 6, 3])
if pretrain:
state_dict = load_state_dict_from_url(model_urls['resnet50'])
model.load_state_dict(state_dict)
features = list([model.conv1, model.bn1, model.relu, model.maxpool, model.layer1, model.layer2, model.layer3, model.layer4])
features = nn.Sequential(*features)
# official resnet50
# from torchvision import models
# model = models.resnet50(pretrained=pretrain)
# features = nn.Sequential(*list(model.children())[: -2])
问题找到了,原来我把resnet50 的backbone换成了pytorch官方的,导致一部分layer的weight无法载入。 感谢一直耐心的回复,也很欣赏这种细致的风格。已经star了
你好,我能看一下你“原来我把resnet50 的backbone换成了pytorch官方的,导致一部分layer的weight无法载入。joy” 的错误代码吗? 邮箱:[email protected] 谢谢
并不会报错,部分weight无法的载入是我的推测,注释部分是载入官方resnet
def resnet50(pretrain = True): model = ResNet(Bottleneck, [3, 4, 6, 3]) if pretrain: state_dict = load_state_dict_from_url(model_urls['resnet50']) model.load_state_dict(state_dict) features = list([model.conv1, model.bn1, model.relu, model.maxpool, model.layer1, model.layer2, model.layer3, model.layer4]) features = nn.Sequential(*features) # official resnet50 # from torchvision import models # model = models.resnet50(pretrained=pretrain) # features = nn.Sequential(*list(model.children())[: -2])
好嘞
0 0 NP