Closed wiesehahn closed 2 months ago
Yes everything is working as expected here. Stages are applied to the processed files.
write_las()
writes new LAZ files from the processed files as expectedwrite_lax()
spatially indexes the processed files and should be the first stage. If it is not the first stage? Well I should have handled the case internally. I'll check. In your case the spatial indexing is not useful here this is why you do not have any warning I guess.write_vpc()
writes a VPC of the processed files. When I created write_vpc()
the use case I was thinking of was only exec(write_vpc(), on = f)
So I'm pretty happy that the pipeline is working fine because you are combining all the tricky stages. But I understand it is not what you are expecting.
Your split pipelines are correct and should do what you are expecting.
Now I guess we could design something smarter like:
pipeline = set_crs(25832) + write_las(ofile =paste0(tempdir(), "/*.laz"), add_index = TRUE, create_vpc = TRUE)
I have a folder with las files which are missing the correct CRS, a spatial index and are uncompressed. So I was wondering if there would be an efficient way to bring the data in a better shape.
For this I tried the following pipeline:
What I wanted was that a compressed version of files is created, which include a spatial index and that these files are referenced in a VPC. Although I expected this might not work as intended due to the internal order the stages are run.
What the pipeline did is to create a spatial index (lax) as an extra file next to the las files , write compressed laz files (without embedded index) and write a vpc which references the las files.
I guess this is an edge case and everything works as expected from lasR side, just reporting it for the case this is not true.
Probably I should split this in something like the following?!