예제 #1
0
def nms(dets, thresh):
    if dets.shape[0] == 0:
        return []

    try:
        if GPU and GPUID is not None:
            return gpu_nms(dets, thresh, device_id=GPUID)
    except:
        return cython_nms(dets, thresh)
예제 #2
0
def nms(dets, thresh):
    if dets.shape[0] == 0:
        return []

    if gpu_nms is not None and GPUID is not None:
        return gpu_nms(dets, thresh, device_id=GPUID)

    elif cython_nms is not None:
        return cython_nms(dets, thresh)
    else:
        return python_nms(dets, thresh, method='Union')
예제 #3
0
def nms(dets, thresh):  #为了debug.改成python_nums,确实发现了使用gpu的nms 有bug!!!!!!!!!!
    return python_nms(dets, thresh, method='Union')
    if dets.shape[0] == 0:
        return []

    if gpu_nms is not None and GPUID is not None:
        return gpu_nms(dets, thresh, device_id=GPUID)

    elif cython_nms is not None:
        return cython_nms(dets, thresh)
    else:
        return python_nms(dets, thresh, method='Union')