forked from Climate-Vision/ClimateVision
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathconfig.yaml
More file actions
206 lines (190 loc) · 5.93 KB
/
Copy pathconfig.yaml
File metadata and controls
206 lines (190 loc) · 5.93 KB
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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
# ClimateVision Configuration
# Multi-Climate Analysis Platform
# ===== Analysis Types Configuration =====
# Each analysis type can be enabled/disabled and configured independently
analysis_types:
# Deforestation Detection
deforestation:
enabled: true
display_name: "Deforestation Detection"
description: "Monitor forest coverage and detect deforestation events"
model:
architecture: "unet"
weights: "models/unet_deforestation.pth"
in_channels: 4
num_classes: 2
bands: ["B04", "B03", "B02", "B08"] # Red, Green, Blue, NIR
classes: ["non_forest", "forest"]
thresholds:
alert_forest_loss: 5.0 # Alert if >5% forest loss
critical_forest_loss: 15.0 # Critical if >15% loss
min_forest_coverage: 20.0 # Alert if coverage drops below 20%
metrics:
- "forest_percentage"
- "forest_pixels"
- "ndvi_stats"
- "carbon_estimation"
# Arctic Ice Melting
ice_melting:
enabled: true
display_name: "Arctic Ice Melting"
description: "Monitor sea ice extent and melting patterns in polar regions"
model:
architecture: "unet"
weights: "models/unet_ice.pth"
in_channels: 4
num_classes: 3
bands: ["B02", "B03", "B04", "B11"] # Blue, Green, Red, SWIR
classes: ["open_water", "sea_ice", "land"]
thresholds:
alert_ice_loss: 10.0 # Alert if >10% ice loss
critical_ice_loss: 25.0 # Critical if >25% loss
min_ice_concentration: 15.0 # Alert if concentration below 15%
rapid_melt_rate: 5.0 # km²/day threshold
metrics:
- "ice_percentage"
- "ice_extent_km2"
- "melt_rate"
- "ndsi_stats"
# Specific regions for Arctic monitoring
default_regions:
arctic_ocean: [-180, 66.5, 180, 90]
greenland: [-73, 60, -12, 84]
antarctica: [-180, -90, 180, -60]
# Flood Detection
flooding:
enabled: true
display_name: "Flood Detection"
description: "Detect and monitor flooding events and affected areas"
model:
architecture: "unet"
weights: "models/unet_flood.pth"
in_channels: 3
num_classes: 3
bands: ["B03", "B08", "B11"] # Green, NIR, SWIR
classes: ["dry_land", "permanent_water", "flooded"]
thresholds:
alert_flood_area: 5.0 # Alert if >5% area flooded
critical_flood_area: 20.0 # Critical if >20% flooded
rapid_expansion_rate: 10.0 # % increase per day
metrics:
- "flooded_percentage"
- "flooded_area_km2"
- "mndwi_stats"
# Drought Monitoring
drought:
enabled: false # Not yet implemented
display_name: "Drought Monitoring"
description: "Monitor vegetation stress and drought conditions"
model:
architecture: "unet"
weights: "models/unet_drought.pth"
in_channels: 4
num_classes: 4
bands: ["B04", "B08", "B11", "B12"] # Red, NIR, SWIR-1, SWIR-2
classes: ["normal", "mild_stress", "moderate_stress", "severe_drought"]
thresholds:
alert_drought_index: 0.3
critical_drought_index: 0.6
metrics:
- "drought_severity_index"
- "vegetation_health_index"
- "soil_moisture_proxy"
# Wildfire Detection
wildfire:
enabled: false # Not yet implemented
display_name: "Wildfire Detection"
description: "Detect active fires and burned areas"
model:
architecture: "unet"
weights: "models/unet_wildfire.pth"
in_channels: 4
num_classes: 3
bands: ["B04", "B08", "B11", "B12"] # Red, NIR, SWIR-1, SWIR-2
classes: ["unburned", "burned", "active_fire"]
thresholds:
fire_radiative_power: 10.0 # MW
burned_area_alert: 1.0 # km²
metrics:
- "burned_area_km2"
- "fire_intensity"
- "nbr_stats" # Normalized Burn Ratio
# ===== Default Model Configuration =====
model:
architecture: "unet"
in_channels: 4 # RGB + NIR
num_classes: 2 # forest / non-forest
use_uncertainty: false
dropout_rate: 0.5
# ===== Training Configuration =====
training:
batch_size: 8
num_epochs: 50
learning_rate: 0.0001
optimizer: "adam"
loss_function: "combined" # focal, dice, or combined
focal_weight: 0.5
checkpoint_interval: 5
early_stopping_patience: 10
# ===== Data Configuration =====
data:
image_size: [256, 256]
bands: ["Red", "Green", "Blue", "NIR"]
normalization: "minmax" # minmax or standardize
augmentation: true
train_split: 0.8
val_split: 0.1
test_split: 0.1
# ===== Satellite Data Sources =====
satellite:
sentinel2:
bands: ["B04", "B03", "B02", "B08"] # Red, Green, Blue, NIR
all_bands: ["B01", "B02", "B03", "B04", "B05", "B06", "B07", "B08", "B8A", "B09", "B10", "B11", "B12"]
resolution: 10 # meters
cloud_coverage_max: 20 # percentage
revisit_time: 5 # days
landsat8:
bands: ["B4", "B3", "B2", "B5"]
resolution: 30 # meters
revisit_time: 16 # days
modis:
bands: ["1", "2", "3", "4", "5", "6", "7"]
resolution: 250 # meters (bands 1-2), 500m (3-7)
revisit_time: 1 # days
use_for: ["ice_melting", "wildfire"] # Best for large-scale monitoring
# ===== Inference Configuration =====
inference:
batch_size: 4
threshold: 0.5
tile_size: [256, 256]
overlap: 32
device: "cuda" # cuda or cpu
num_workers: 4
# ===== MLOps Configuration =====
mlops:
experiment_tracking: "mlflow" # mlflow, wandb, or none
model_registry: "mlflow"
logging_interval: 10 # log every N batches
# ===== Paths =====
paths:
data_dir: "data/"
models_dir: "models/"
logs_dir: "logs/"
outputs_dir: "outputs/"
# ===== API Configuration =====
api:
host: "0.0.0.0"
port: 8000
workers: 4
timeout: 60
max_file_size: 100 # MB
cors_origins:
- "http://localhost:5173"
- "http://localhost:3000"
# ===== Organization (NGO) Configuration =====
organizations:
enable_registration: true
require_email_verification: false
default_alert_channels: ["email"]
max_subscriptions_per_org: 10
api_rate_limit: 100 # requests per minute