Skip to content
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions real_data/hot-oam/68077a72c46a9912474701ef.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# Humanitarian OpenStreetMap Team Open Aerial Map (HOT-OAM)

Highlights:

- Internal mask mask

## Data creation

From

```
https://oin-hotosm-temp.s3.us-east-1.amazonaws.com/68077a72c46a9912474701ee/0/68077a72c46a9912474701ef.tif
```

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

```
Binary file added real_data/hot-oam/68077a72c46a9912474701ef.tif
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

Binary file not shown.
56 changes: 56 additions & 0 deletions real_data/hot-oam/68077a72c46a9912474701ef_info.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
```
Driver: GTiff
File: real_data/hot-oam/68077a72c46a9912474701ef.tif
COG: True
Compression: JPEG
ColorSpace: YCbCr

Profile
Width: 999
Height: 1000
Bands: 3
Tiled: True
Dtype: uint8
NoData: None
Alpha Band: False
Internal Mask: True
Interleave: PIXEL
ColorMap: False
ColorInterp: ('red', 'green', 'blue')
Scales: (1.0, 1.0, 1.0)
Offsets: (0.0, 0.0, 0.0)

Geo
Crs: EPSG:32613
Origin: (246690.03449931872, 4310030.042218)
Resolution: (0.04999742109334269, -0.050000000000180796)
BoundingBox: (246690.03449931872, 4309980.042218, 246739.98192299096, 4310030.042218)
MinZoom: 18
MaxZoom: 21

Image Metadata
AREA_OR_POINT: Area

Image Structure
SOURCE_COLOR_SPACE: YCbCr
COMPRESSION: YCbCr JPEG
INTERLEAVE: PIXEL
JPEG_QUALITY: 75
JPEGTABLESMODE: 1

Band 1
ColorInterp: red

Band 2
ColorInterp: green

Band 3
ColorInterp: blue

IFD
Id Size BlockSize Decimation
0 999x1000 512x512 0

COG Validation info
- The file is greater than 512xH or 512xW, it is recommended to include internal overviews (warning)
```