Boost.Python.ArgumentError: Python argument types in rectangle.__init__(rectangle, numpy.int32, int, int, int) did not match C++ signature: __init__(struct _object * __ptr64, long left, long top, long right, long bottom) __init__(struct _object * __ptr64)
一路定位
1 2 3 4 5 6 7 8
def _css_to_rect(css): """ Convert a tuple in (top, right, bottom, left) order to a dlib `rect` object
:param css: plain tuple representation of the rect in (top, right, bottom, left) order :return: a dlib `rect` object """ return dlib.rectangle(css[3], css[0], css[1], css[2])