Geoprocessing
Geoprocessing tools including:
- merge
- intersect
- union
- erase
- clip (!!!can work with raster)
- smc_difference
- dissolve
- buffer
Every tools can work with vector data.
This case study will show you Intersect tools and Clip tools
load package
import geopandas as gpd
from Godream.geobox import intersect
from Godream.plotimg import overlay_map
Intersect
Using intersect function
# input path
paths=[First_path,secound_path]
out_path="D:\DGEO\data\intersect_out.geojson"
# output path
intersect(paths, out_path)
Output intersect
#display intersect result on interative map
result_files = [First_path, secound_path, out_path]
overlay_map(result_files)
Clip Raster by Vector
input_path='D:\DGEO\data\S2_image3.tif' # raster
clip_path = 'D:\DGEO\data\Rectan.geojson' # vector
output_path= 'D:\DGEO\data\Raster_clip.tif'
# display input file on interative map
filev = [clip_path]
filer = [input_path]
overlay_map(filev,filer)