我有一个 numpy 数组,filtered__rows
,由 LAS 数据组成[x, y, z, intensity, classification]
。我创建了一个cKDTree
点并找到最近的邻居,query_ball_point
,这是该点及其邻居的索引列表。
有没有办法过滤filtered__rows
创建一个仅包含索引位于返回列表中的点的数组query_ball_point
?
看起来你只需要一个基本的整数数组索引 https://numpy.org/doc/stable/reference/arrays.indexing.html#purely-integer-array-indexing:
filter_indices = [1,3,5]
np.array([11,13,155,22,0xff,32,56,88])[filter_indices]
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)