I am extracting imdividual lidar samples from a larger lidar scene of a cropland for biomass regression purposes. The difficulty lies in extracting the files accounting for the azomuth (18°E) that the sowing lines present. At the moment I am doing as follows:

1) pdal translate scene.las scene.txt

2) read txt. into pandas lib.

3) establish boundaries of clipping box (numpy and pandas).

4) filter out all points not belonging to the wanted sample (pandas).

5) extract individual lidar sample using: pdal translate lidar_sample.las lidar_sample.txt

The problem lies on step 4, where I am currently filtering out using orthonormal X,Y thresholds, but I would like to account for the orientation (18°E) of the field sowing lines, therefore to filter out points which currently lie at the corners of my clipping box.

I guess that applying a rotation to all points included in the pandas df, then filtering, and then returning the rotation would work, but I haven't solved yet how to work that out in pandas.

Is there an easier way?

p.s.: the clipping can not be done using a kml file, or manually, since are hundreds of samples. It has to be automated.

More Jaime Caballer Revenga's questions See All
Similar questions and discussions