Open wkearn opened 2 hours ago
Hello, I tried to solve the issue.
This is what I did:
Implemented the reproject2utm method in the GridObject class to transform the DEM into a projected coordinate system using rasterio's warp.reproject function. This new method allows users to reproject their DEMs to UTM coordinates, which is essential for many analysis functions that assume projected coordinate systems.
You can review changes in this commit: https://github.com/lattaai12/TopoToolbox-pytopotoolbox-82/commit/cded88f9163aa732deaaa7613fc61fab300d439d.
[!CAUTION] Disclaimer: The commit was created by Latta AI and you should never copy paste this code before you check the correctness of generated code. Solution might not be complete, you should use this code as an inspiration only.
This issue was tried to solve for free by Latta AI - https://latta.ai/ourmission
If you no longer want Latta AI to attempt solving issues on your repository, you can block this account.
MATLAB topotoolbox provides the
reproject2utm
function, which transforms the suppliedGRIDobj
into a projected coordinate system. Many of our analysis functions assume projected coordinate systems, and it would be nice to have this functionality available.We should be able to use
rasterio
'swarp.reproject
function , assuming we maintain enough of the rasterio metadata in theGridObject
-- I think we only need thetransform
andcrs
, which we do have access to.