Sfm-python icon indicating copy to clipboard operation
Sfm-python copied to clipboard

运行报错

Open yolic66 opened this issue 1 year ago • 4 comments

Traceback (most recent call last): File "c:\Users\74773\Desktop\Sfm-python-master\Sfm-python-master\revise_v2.py", line 329, in main() File "c:\Users\74773\Desktop\Sfm-python-master\Sfm-python-master\revise_v2.py", line 286, in main key_points_for_all, descriptor_for_all, colors_for_all = extract_features(img_names) ^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "c:\Users\74773\Desktop\Sfm-python-master\Sfm-python-master\revise_v2.py", line 46, in extract_features return np.array(key_points_for_all), np.array(descriptor_for_all), np.array(colors_for_all) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ValueError: setting an array element with a sequence. The requested array has an inhomogeneous shape after 1 dimensions. The detected shape was (14,) + inhomogeneous part.

yolic66 avatar Nov 29 '23 09:11 yolic66

因为SIFT检测出来的两个图像特征数量不一样,导致最后转为numpy数组的时候,每个list中的两个元素长度不一样

Arrogant-Q avatar Apr 06 '24 06:04 Arrogant-Q

请问怎样解决呢

ddjiayou avatar Apr 19 '24 13:04 ddjiayou

我遇到了一模一样的问题,请问目前有什么解决方法吗?

zhaosiyuan1098 avatar May 04 '24 15:05 zhaosiyuan1098

将numpy库降级成1.23.0版本可解决该问题

pyre001 avatar Jun 19 '24 01:06 pyre001