Skip to content

Commit

Permalink
complete overhaul for major release
Browse files Browse the repository at this point in the history
  • Loading branch information
maany committed Nov 21, 2024
1 parent e33d234 commit c949a13
Show file tree
Hide file tree
Showing 14 changed files with 1,415 additions and 454 deletions.
131 changes: 131 additions & 0 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,131 @@
{
"configurations": [
{
"name": "Disaster Tracking",
"type": "debugpy",
"request": "launch",
"program": "${workspaceFolder}/sentinel_scraper.py",
"console": "integratedTerminal",
"args": [
"--case-study-name=disaster",
"--tracer-id=potato",
"--job-id=2",
"--start_date=2024-09-15T09:00",
"--end_date=2024-09-15T12:00",
"--interval=60",
"--long_left=-156.708984",
"--lat_up=20.759645",
"--long_right=-156.299744",
"--lat_down=20.955027",
"--log-level=INFO",
"--kp_auth_token=test123", "--kp_host=localhost", "--kp_port=8000", "--kp_scheme=http",
"--sentinel_client_id=e2397fbb-0fb6-4742-9cba-c142ad44f617", "--sentinel_client_secret=DD6XKTPeDz4juiLWtItNGPofztG9frc3",
"--evalscript_bands_path=https://gist.githubusercontent.com/Rahul-7131/b02d5614401ba654904ff509039def15/raw/3867e78b12bf7d7dff44810c548ed20797b367ea/wildfire_evalscript.js",
"--evalscript_truecolor_path=https://gist.githubusercontent.com/Rahul-7131/b02d5614401ba654904ff509039def15/raw/3867e78b12bf7d7dff44810c548ed20797b367ea/truecolor_wildfire.js",
]
},
{
"name": "Climate Monitoring",
"type": "debugpy",
"request": "launch",
"program": "${workspaceFolder}/sentinel_scraper.py",
"console": "integratedTerminal",
"args": [
"--case-study-name=climate",
"--tracer-id=potato",
"--job-id=4",
"--start_date=2024-09-15T09:00",
"--end_date=2024-09-15T12:00",
"--interval=60",
"--long_left=-156.708984",
"--datasets-evalscripts={\"SENTINEL5P\": [\"climate-bands\", \"climate-mask\"], \"SENTINEL2-L1C\": [\"true-color\"]}",
"--lat_up=20.759645",
"--long_right=-156.299744",
"--lat_down=20.955027",
"--log-level=INFO",
"--kp_auth_token=test123", "--kp_host=localhost", "--kp_port=8000", "--kp_scheme=http",
"--sentinel_client_id=e2397fbb-0fb6-4742-9cba-c142ad44f617", "--sentinel_client_secret=DD6XKTPeDz4juiLWtItNGPofztG9frc3",
]
},
{
"name": "Climate Augmentation",
"type": "debugpy",
"request": "launch",
"program": "${workspaceFolder}/climate_augmentation.py",
"console": "integratedTerminal",
"args": [
"--case-study-name=climate",
"--tracer-id=potato",
"--job-id=4",
"--long_left=-156.708984",
"--datasets-evalscripts={\"SENTINEL5P\": [\"climate-bands\", \"climate-mask\"], \"SENTINEL2-L1C\": [\"true-color\"]}",
"--lat_up=20.759645",
"--long_right=-156.299744",
"--lat_down=20.955027",
"--log-level=INFO",
"--kp_auth_token=test123", "--kp_host=localhost", "--kp_port=8000", "--kp_scheme=http",
]
},
{
"name": "Sentinel-5P Scraping",
"type": "debugpy",
"request": "launch",
"program": "${workspaceFolder}/sentinel_scraper.py",
"console": "integratedTerminal",
"args": [
"--case-study-name=sentinel-5p",
"--tracer-id=potato",
"--job-id=3",
"--start_date=2024-09-15T09:00",
"--end_date=2024-09-15T12:00",
"--interval=60",
"--long_left=-156.708984",
"--datasets-evalscripts={\"SENTINEL5P\": [\"climate-bands\", \"climate-mask\"], \"SENTINEL2-L1C\": [\"true-color\"]}",
"--lat_up=20.759645",
"--long_right=-156.299744",
"--lat_down=20.955027",
"--log-level=INFO",
"--kp_auth_token=test123", "--kp_host=localhost", "--kp_port=8000", "--kp_scheme=http",
"--sentinel_client_id=e2397fbb-0fb6-4742-9cba-c142ad44f617", "--sentinel_client_secret=DD6XKTPeDz4juiLWtItNGPofztG9frc3",
]
},
{
"name": "Sentinel-5P Augmentation",
"type": "debugpy",
"request": "launch",
"program": "${workspaceFolder}/climate_augmentation.py",
"console": "integratedTerminal",
"args": [
"--case-study-name=sentinel-5p",
"--tracer-id=potato",
"--job-id=3",
"--long_left=-156.708984",
"--datasets-evalscripts={\"SENTINEL5P\": [\"climate-bands\", \"climate-mask\"], \"SENTINEL2-L1C\": [\"true-color\"]}",
"--lat_up=20.759645",
"--long_right=-156.299744",
"--lat_down=20.955027",
"--log-level=INFO",
"--kp_auth_token=test123", "--kp_host=localhost", "--kp_port=8000", "--kp_scheme=http",
]
},
{
"name": "Sentinel-5P Time Travel",
"type": "debugpy",
"request": "launch",
"program": "${workspaceFolder}/sentinel_5p_time_travel.py",
"console": "integratedTerminal",
"args": [
"--tracer-id=potato",
"--job-id=3",
"--long_left=-156.708984",
"--datasets-evalscripts={\"SENTINEL5P\": [\"climate-bands\", \"climate-mask\"], \"SENTINEL2-L1C\": [\"true-color\"]}",
"--lat_up=20.759645",
"--long_right=-156.299744",
"--lat_down=20.955027",
"--log-level=INFO",
"--kp_auth_token=test123", "--kp_host=localhost", "--kp_port=8000", "--kp_scheme=http",
]
},

]
}
64 changes: 64 additions & 0 deletions app/config.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
from sentinelhub import DataCollection
SUPPORTED_DATASET_EVALSCRIPTS = {
"SENTINEL2-L1C": {
"sentinel_sdk_obj": DataCollection.SENTINEL2_L1C,
"supported_evalscripts": [
{
"name": "true-color",
"path": "https://gist.githubusercontent.com/Rahul-7131/b02d5614401ba654904ff509039def15/raw/3867e78b12bf7d7dff44810c548ed20797b367ea/truecolor_wildfire.js",
"scaling_factor": 1.5,
"clip_range": {
"min": 0,
"max": 1
},
"description": "A Sentinel-2 image highlighting areas of interest based on water, vegetation, and spectral thresholds in true color. Bands: B04, B03, B02, B08, B11, B12"
}
]
},
"SENTINEL5P": {
"sentinel_sdk_obj": DataCollection.SENTINEL5P,
"supported_evalscripts": [
{
"name": "climate-bands",
"path": "https://gist.githubusercontent.com/Rahul-7131/b02d5614401ba654904ff509039def15/raw/5c8894fe017e42c594a2fb755d10d57602049ec5/climate_evalscript.js",
"scaling_factor": 1.5,
"clip_range": {
"min": 0,
"max": 1
},
"description": "Carbon monoxide (CO) concentrations using a color ramp from low (blue) to high (red) and processes the image into a grid to determine dominant CO concentrations per grid cell."
},
{
"name": "climate-mask",
"path": "https://gist.githubusercontent.com/Rahul-7131/b02d5614401ba654904ff509039def15/raw/5c8894fe017e42c594a2fb755d10d57602049ec5/climate_evalscript.js",
"scaling_factor": 255,
"clip_range": {
"min": 0,
"max": 1
},
"description": "A mask of the carbon monoxide (CO) concentrations in the image. The mask is created by thresholding the CO concentrations in the image."
},
{
"name": "fire-bands",
"path": "https://gist.githubusercontent.com/Rahul-7131/b02d5614401ba654904ff509039def15/raw/3867e78b12bf7d7dff44810c548ed20797b367ea/wildfire_evalscript.js",
"scaling_factor": 1.5,
"clip_range": {
"min": 0,
"max": 1
},
"description": "Sentinel-2 image focussed on detection of wildfires, highlighting areas of interest based on vegetation (NDVI), water content (NDWI), and spectral thresholds in enhanced true color"
},
{
"name": "fire-mask",
"path": "https://gist.githubusercontent.com/Rahul-7131/b02d5614401ba654904ff509039def15/raw/5c8894fe017e42c594a2fb755d10d57602049ec5/climate_evalscript.js",
"scaling_factor": 255,
"clip_range": {
"min": 0,
"max": 1
},
"description": "A mask of the wildfire areas in the image. The mask is created by thresholding the NDVI and NDWI values in the image."
},
]
},
# Add more datasets as needed
}
Loading

0 comments on commit c949a13

Please sign in to comment.