Description
I crash into this error while executing
python test.py --trained_model=craft_mlt_25k.pth --refiner_model=craft_refiner_CTW1500.pth --test_folder=myfolder --refine
Traceback (most recent call last):
File "C:\code\CRAFT-pytorch\test.py", line 165, in
bboxes, polys, score_text = test_net(net, image, args.text_threshold, args.link_threshold, args.low_text, args.cuda, args.poly, refine_net)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\code\CRAFT-pytorch\test.py", line 106, in test_net
polys = craft_utils.adjustResultCoordinates(polys, ratio_w, ratio_h)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\code\CRAFT-pytorch\craft_utils.py", line 251, in adjustResultCoordinates
polys = np.array(polys)
^^^^^^^^^^^^^^^
ValueError: setting an array element with a sequence. The requested array has an inhomogeneous shape after 1 dimensions. The detected shape was (5,) + inhomogeneous part.