Skip to content

Binary & Prob Geotiff#87

Merged
michaelkiper merged 4 commits into
devfrom
binary-geotiff
Aug 22, 2025
Merged

Binary & Prob Geotiff#87
michaelkiper merged 4 commits into
devfrom
binary-geotiff

Conversation

@michaelkiper

@michaelkiper michaelkiper commented Aug 7, 2025

Copy link
Copy Markdown
Collaborator

Overview

This PR is to allow for the creation of a binary cloud mask in addition to a probability mask, so that way 2 separate calls aren't needed.

Related Tickets

resolves #86

Testing

  1. Go to the EMIT cluster
  2. Run the below command
]$ srun --partition gpuq -N 1 -c 63 --mem=0 --pty spectf-cloud deploy-pt --device 0 --proba ./out.tiff /store/emit/ops/data/acquisitions/20240101/emit20240101t021655/l1b/emit20240101t021655_o00102_s001_l1b_obs_b0106_v01.hdr /store/emit/ops/data/acquisitions/20240101/emit20240101t021655/l1b/emit20240101t021655_o00102_s001_l1b_rdn_b0106_v01.hdr
  1. View the output tif files and see that their contents are as expected

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Pull Request Overview

This PR refactors GeoTIFF generation functionality to allow creating both binary and probability cloud masks in a single operation, eliminating the need for separate function calls. The change consolidates duplicate code and improves the user experience by generating both mask types when probability output is requested.

Key Changes:

  • Created a centralized make_geotiff function that can generate both binary and probability masks
  • Refactored deployment modules to use the new consolidated function
  • Updated help text to reflect that probability option now generates both mask types

Reviewed Changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

File Description
spectf_cloud/deploy/gen_geotiff.py New module containing consolidated GeoTIFF generation logic with support for dual mask creation
spectf_cloud/deploy/deploy_trt.py Refactored to use centralized GeoTIFF function and removed duplicate code
spectf_cloud/deploy/deploy_pt.py Refactored to use centralized GeoTIFF function and updated help text

Comment thread spectf_cloud/deploy/gen_geotiff.py Outdated
Comment thread spectf_cloud/deploy/gen_geotiff.py Outdated

@jakehlee jakehlee left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Great idea consolidating the GeoTIFF export to a single function, I left some minor comments. Thanks!

Comment thread spectf_cloud/deploy/gen_geotiff.py
Comment thread spectf_cloud/deploy/gen_geotiff.py Outdated
Comment thread spectf_cloud/deploy/gen_geotiff.py
@michaelkiper michaelkiper merged commit 2b02eed into dev Aug 22, 2025
2 checks passed
@michaelkiper michaelkiper deleted the binary-geotiff branch August 22, 2025 19:06
jakehlee added a commit that referenced this pull request Sep 10, 2025
Merging based on approval of #87 for release
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.

3 participants