Quantcast
Channel: User JRR - Stack Overflow
Browsing index pages (50 articles)

Answer by JRR for lidR lascatalog processing engine transformation outputs...

sf does not have st_transform for LAS objects from the lidR package. The lidRversion inherits its own functionst_transformand because of some inheritance rules it must be call thoughtsf::st_transform....

View Article


Comment by JRR on lidR lascatalog processing engine transformation outputs...

sf does not have st_transform for LAS objects from the lidR package. The lidR inherit its own function st_transform and because of some inheritance rules it must be call thought sf::st_transform. The...

View Article


Comment by JRR on Unable to read chunk in lidR catalog_apply

terra also defines is.empty. Maybe there is a clash in namespace. Did you try lidR::is.empty()?

View Article

Answer by JRR for assigning the coordinate system to my las catalog and my...

EPSG:4326 is a longitude/latitude CRS. Your point cloud is in a projected CRS. The error comes from the terra package when trying to build a raster in long/lat with invalid projected coordinated

View Article

Answer by JRR for How to remove duplicate las points with same XYZ but...

Copy the code of lidR::filter_duplicated() and use fromLastdup_xyz <- duplicated(las@data, by = c("X", "Y", "Z"), fromLast=TRUE)las = las[!dup_xyz]

View Article


Comment by JRR on Are there any risks to accessing internal functions with ::...

> but I don't think CRAN will be sympathetic to that special case This case it actually allowed by CRAN and it is the only case

View Article

Answer by JRR for Attempting to Calculate Leaf Area Index in lidR package...

throws error that Duplicate elements are found and at least one metric was not a number out<-log(nveg+1/(nground+1))*cos((ScanAngle*pi/180)/0.5) return(list(LAI=out))Here, clearly LAI is not a...

View Article

Comment by JRR on Segmenting lidar .laz file into four quadrants using lidR...

Your question has been close for no good reason in my opinion. Your question looks legit. Please come to the gis section gis.stackexchange.com/questions/tagged/lidr and please do not share screenshoot...

View Article


Answer by JRR for Lack of precision when using the lidr package's...

The mistake you made was to compute the local maxima from the point cloud and then use these maxima as seed on a raster that was modified with a focal function. The local maxima of the raster no longer...

View Article


Comment by JRR on Lack of precision when using the lidr package's...

Share your data otherwise there is no way to help you

View Article

Disable OpenMP for code coverage of an R package on Github actions

I have an R package with C++ code and I'm using GitHub actions to run unit tests and code coverage with covr. Everything is working.However, code coverage does not work with parallelized blocks of C++...

View Article

Answer by JRR for Disable OpenMP for code coverage of an R package on Github...

I found a third option. I'm running the coverage on macOS instead of Linux because it has no native support of OpenMP.

View Article

Answer by JRR for Calculating Point-Based EigenVectors from a LAS file in Lidr R

Use C++The documentation of point_metrics explicitly mention to use C++ code in this case. It gives you an example you can copy and paste changing only the output variableRcpp::sourceCpp(code =...

View Article


Answer by JRR for building R packages to use ASAN

This the document I wrote for myself and that I used myself.Download and decrompress R source codeInstall the compiler clang. apt-get install clang should do the jobOpen config.site and add the...

View Article

Answer by JRR for Why am I having issues plotting LAS with...

Use lidR::plot(las,size=5,pal=grDevices::terrain.colors, axis=TRUE)

View Article


Answer by JRR for Trouble reading LAZ lidar files in R download from NOAA DAV

lidR uses LASlib/LASzip from LAStools to read and write LAS and LAZ files. Your files are corrupted. Story ends here. You must find non-corrupted files, or you must try to reproduce with LAStools...

View Article

How to make QTextCursor::WordUnderCursor include more characters or larger words

I'm trying to show a tooltip when the cursor is over a keyword in a text editor using:QTextCursor cursor = cursorForPosition(pos);cursor.select(QTextCursor::WordUnderCursor);This works well but the...

View Article


gcc-8 -Wstringop-truncation what is the good practice?

GCC 8 added a -Wstringop-truncation warning. From https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82944 :The -Wstringop-truncation warning added in GCC 8.0 via r254630 for bug 81117 is specifically...

View Article

Answer by JRR for Is there an R function for finding if a .LAZ file is...

Something like that (did not test)library(lidR)library(sf)ctg = readLAScatalog("/path/to/folder")extent = st_read("/path/to/folder/filname.shp")ctg2 = catalog_intersect(ctg, extent)ctg2$filename

View Article

Answer by JRR for Error: Invalid function provided as algorithm while using...

ForestTools::mcws is a function from the package ForestTools and is not designed to be compatible with lidR. lidR cannot accept any function as input and the developers must respect some convention to...

View Article
Browsing index pages (50 articles)


Latest Images