Skip to content

feat: add hot-oam internal mask file#25

Merged
gadomski merged 4 commits intomainfrom
hot-oam
Feb 5, 2026
Merged

feat: add hot-oam internal mask file#25
gadomski merged 4 commits intomainfrom
hot-oam

Conversation

@gadomski
Copy link
Contributor

@gadomski gadomski commented Feb 5, 2026

No description provided.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What do you think is the maximum file size we should permit in this repo? The entire repo will be cloned every time a downstream repo runs tests. So far I've been trying to have file sizes in the range of up to 250kb

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

250kb seems reasonable to me, I can do a crop on the source image to get it below that size.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

$ ls -alsh real_data/hot-oam/68077a72c46a9912474701ef*
  8 -rw-r--r--@ 1 gadomski  staff   2.1K Feb  5 07:44 real_data/hot-oam/68077a72c46a9912474701ef_info.md
  8 -rw-r--r--@ 1 gadomski  staff   479B Feb  5 07:46 real_data/hot-oam/68077a72c46a9912474701ef.md
456 -rw-r--r--@ 1 gadomski  staff   171K Feb  5 07:46 real_data/hot-oam/68077a72c46a9912474701ef.tif

@gadomski gadomski requested a review from kylebarron February 5, 2026 14:47
Cropped with:

```shell
pixi run rio clip "https://oin-hotosm-temp.s3.us-east-1.amazonaws.com/68077a72c46a9912474701ee/0/68077a72c46a9912474701ef.tif" real_data/hot-oam/68077a72c46a9912474701ef.tif --bounds "246690 4309980 246740 4310030"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wow that's nice; I didn't know rio clip was a thing 😅 although I guess you need to know the true bounds?

chatgpt had suggested srcwin:

```bash
pixi run gdal_translate \
-srcwin 0 0 128 128 \
-of COG \
-co COMPRESS=JPEG \
-co BLOCKSIZE=64 \
/vsicurl/https://maxar-opendata.s3.amazonaws.com/events/yellowstone-flooding22/ard/12/120000020112/2022-06-18/10300100D51B8C00-visual.tif \
maxar_opendata_yellowstone_visual.tif
```

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

rio clip keeps all other aspects of the input dataset the same I assume?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess one benefit of using gdal_translate with -of COG is that it auto-generates overviews

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, srcwin works in pixel domain, clip is projected bounds. rio clip has a -f to set COG if you want #gdalinatrenchccoat

@gadomski gadomski requested a review from kylebarron February 5, 2026 15:20
@gadomski gadomski merged commit 43dc532 into main Feb 5, 2026
1 check passed
@gadomski gadomski deleted the hot-oam branch February 5, 2026 16:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants