Closed wiesehahn closed 2 weeks ago
Fixed.
Some explainations: your pipeline is reader_las() + write_vpc()
(even if you omitted reader_las()
). reader_las()
always reads the header and reads the point cloud if necessary. If necessary is determined by the other stages and write_vpc()
is labelled internally such as the point cloud is not necessary so the file is not read in this pipleine. However set_crs()
was incorrectly flagged and consequently reader_las()
read the point cloud in the pipeline reader_las() + set_crs() + write_vpc()
because set_crs()
stated that the points were required
When assigning a CRS via
set_crs()
and thenwrite_vpc()
I get quite long computation times although the documentation states thatAnd hence I expected pipelines to be more or less equally fast with or without this stage.
(see initial mention in https://github.com/r-lidar/lasR/discussions/32)
I tested this on multiple files and it occurs on data of multiple different campaigns (although not with testdata).
Processing time seems to be dependent on file size, is this expected (I guess just the header is read and thus I would not expect big differences)?
It does not occur on testdata
E.g. for a file with no CRS assigned (136MB)
another file with no CRS assigned (774MB)
and for the same file when setting CRS before and writing to file
file with CRS assigned (410MB)
file with CRS assigned (575MB)
same file as above but with
summarise
instead ofwrite_vpc
in the pipeline the time difference is smaller (its faster withset_crs
)