getting e notation values when stacking into a numpy array in python

95 Views Asked by At

I am stacking point clouds into one array using np.stack but when i see the result the values are shown in e notation. if i only stack x and y then the values are not shown in e notation only if i add the z column its shown in e notation

for stacking two values

import laspy
import numpy as np

las = laspy.read("f:\\lidar\\pointcloud.laz")

arr = np.stack([las.x, las.y], axis=0).transpose((1, 0))
arr

array([[ 368230.825, 5807507.866],
       [ 368231.821, 5807508.151],
       [ 368232.935, 5807508.114],
       ...,
       [ 368496.193, 5807742.345],
       [ 368495.747, 5807741.916],
       [ 368495.412, 5807742.06 ]])

values when stacking with z values.

import laspy
import numpy as np

las = laspy.read("f:\\lidar\\pointcloud.laz")

arr = np.stack([las.x, las.y,las.z], axis=0).transpose((1, 0))
arr

array([[3.68230825e+05, 5.80750787e+06, 3.10790000e+01],
       [3.68231821e+05, 5.80750815e+06, 3.11140000e+01],
       [3.68232935e+05, 5.80750811e+06, 3.11320000e+01],
       ...,
       [3.68496193e+05, 5.80774234e+06, 3.33270000e+01],
       [3.68495747e+05, 5.80774192e+06, 3.29020000e+01],
       [3.68495412e+05, 5.80774206e+06, 3.13750000e+01]])
0

There are 0 best solutions below