Creating and applying binary mask (railroad). #530
epehlivanli
started this conversation in
General
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
1 - I converted velocity.h5 (velocity as dataset) to GeoTiff to visualize in QGIS.
H5 to GeoTiff Best.pdf
2- In QGIS, there is a plug-in called QuickOSM. to import buildings/railroads/highways with a keys. You can search railways with a key of rail and the location (ex. Broward, Florida).

2- I clipped imported railway vector file by the boundaries of raster and cleaned it. Since it is a vector file, the entire vertices needs to be selected and merged (Edit -> Edit Geometry -> Edit Selected Features). Then we need to buffer lines to save as shapefile (.geojson, .shp etc.)


3- I used Geotiff raster and buffered vector file to create boolean binary mask as .tiff file. Both vector and raster files should be on same crs. (mask.tiff)
Creating binary mask.pdf
4- I used mask.py as shown below and created geo_velocity_tmp.h5, then used view.py to view it with masked geocoded maskTempCoherence file (geo_maskTempCoh.h5);
mask.py geo_velocity.h5 -m mask.tif -o geo_velocity_tmp.h5
view.py geo_velocity_tmp.h5 velocity -m geo_maskTempCoh.h5
Beta Was this translation helpful? Give feedback.
All reactions