Update utils.py
The binary mode of fromstring is deprecated, as it behaves surprisingly on unicode inputs. Use frombuffer instead
@@ -172,6 +172,6 @@ def sorted_boxes(dt_boxes):
def base64_to_cv2(b64str):
data = base64.b64decode(b64str.encode('utf8'))
- data = np.fromstring(data, np.uint8)
+ data = np.frombuffer(data, np.uint8)
data = cv2.imdecode(data, cv2.IMREAD_COLOR)
return data
