Add tool scripts #1

Merged
florent merged 7 commits from develop into master 2024-11-10 15:43:36 +01:00
Showing only changes of commit b00ebafd1b - Show all commits

View File

@ -64,6 +64,14 @@ def load_las(fname):
feature_data.append(att) feature_data.append(att)
feature_dtype.append((spec.name, att.dtype)) feature_dtype.append((spec.name, att.dtype))
# XXX: Workaround missing num_returns in header
try:
att = infile.num_returns
feature_data.append(att)
feature_dtype.append(('num_returns', att.dtype))
except Exception:
pass
log.debug('Create feature recarray') log.debug('Create feature recarray')
feature = np.core.records.fromarrays(feature_data, dtype=feature_dtype) feature = np.core.records.fromarrays(feature_data, dtype=feature_dtype)
del feature_data, feature_dtype del feature_data, feature_dtype