-
Notifications
You must be signed in to change notification settings - Fork 3
/
integrated_prioritisation.txt
38 lines (19 loc) · 1.66 KB
/
integrated_prioritisation.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
# steps used to combine output layers from each section into the integrated prioritisation layer
# setting a mask to first constrain to AOI and then to exclude transformed areas (i.e. include natural and degraded)
r.mask --overwrite vector=aoi
r.mask --overwrite raster=lc_status@PERMANENT maskcats=1 2
# ecological infrastructure (from Charlie)
r.external --overwrite input="/data/WBR_SEMP/cumulative-ecological-infrastructure.tif" output="ecological_infrastructure"
# climate resilience (from Seabilwe)
r.external --overwrite input="/data/WBR_SEMP/climate_change_resilience.tif" output="climate"
# biodiversity priorities (from Gavin)
v.in.ogr --overwrite -o input="PG:host=localhost user=gavin dbname=wbr" layer="polys_total" output="biopoly" min_area=0.0001 type="" snap=-1 #it suggests using snap=0.0001
v.to.rast --overwrite input="biopoly@PERMANENT" layer="1" type="point,line,area" output="biodiversity" use="attr" attribute_column="score" value=1 memory=300
# social resource dependency (from Admire)
r.external --overwrite input="/data/WBR_SEMP/integrated_social_demand_index_on_intact_habitats.tif" output="social"
# import AOI for mask
v.external input="PG:host=localhost user=gavin dbname=wbr" layer="aoi_wbr" output="aoi"
# overall integrated prioritisation
r.mapcalc expression="composite = climate@PERMANENT + ecological_infrastructure@PERMANENT + social@PERMANENT + biodiversity@PERMANENT" --overwrite
#Charlie's layer had nulls so used this to zero them on the fly
r.mapcalc --overwrite "composite = round(climate@PERMANENT + if(isnull(ecological_infrastructure@PERMANENT),0,ecological_infrastructure@PERMANENT) + social@PERMANENT + biodiversity@PERMANENT)"