detectron2_backbone icon indicating copy to clipboard operation
detectron2_backbone copied to clipboard

Question mAP and FPS

Open wenjun90 opened this issue 4 years ago • 3 comments

Dir sxhxliang,

Could I ask you the mAP and FPS you obtain with detectron_efficientNet on COCO dataset?

Thank you

wenjun90 avatar May 06 '20 08:05 wenjun90

build_fcos_efficientnet_fpn_backbone
epoch:6 batchsize:8 gpus:4 coco results:

AP AP50 AP75 APs APm APl
29.017 45.281 30.911 16.333 31.203 38.439

sxhxliang avatar May 06 '20 11:05 sxhxliang

Could you share me FPS ou prediction time, please? Thank you so much.

wenjun90 avatar May 06 '20 11:05 wenjun90

sorry, I have no time to do this, it is easy to measure the speed and you can test the model yourself.

def compute_speed(model, input_size, device, iteration):
    print('input_size', input_size)
    torch.cuda.set_device(device)
    torch.backends.cudnn.benchmark = True

    model.eval()
    model = model.cuda()

    input = torch.randn(*input_size).cuda()

    for _ in range(10):
        model(input)

    print('=========Speed Testing=========')
    torch.cuda.synchronize()
    torch.cuda.synchronize()
    t_start = time.time()
    for _ in range(iteration):
        model(input)
    torch.cuda.synchronize()
    torch.cuda.synchronize()
    elapsed_time = time.time() - t_start
    print(
        'Elapsed time: [%.2f s / %d iter]' % (elapsed_time, iteration))
    print('Speed Time: %.2f ms / iter    FPS: %.2f' % (
        elapsed_time / iteration * 1000, iteration / elapsed_time))

sxhxliang avatar May 14 '20 23:05 sxhxliang