opera-adt / DSWX-SAR

Dynamic Surface Water Extent from Synthetic Aperture Radar
Apache License 2.0
9 stars 6 forks source link

Block processing for bimodality test #56

Closed oberonia78 closed 6 months ago

oberonia78 commented 6 months ago

This PR introduces the block processing for the refine_with_bimodality.py.

While testing some cases where the bright water pixels are dominant, the memory usage is higher than our expectations. In order to reduce memory usage, this PR modifies the remove_false_water_bimodality_parallel and fill_gap_water_bimodality_parallel by adding the block processing. As seen in the figure, the memory usages are significantly decreased remaining the identical result.

Previous

Screenshot 2024-01-07 at 12 34 51 AM

Current

Screenshot 2024-01-07 at 12 35 16 AM
oberonia78 commented 6 months ago

I'm not sure if you @LiangJYu @seongsujeong have the time to review this PR. We discovered an issue where the process was terminated during the "bimodality test," but we're unsure of the exact problem. My guess is that it might be related to memory usage exceeding the available memory, possibly due to too many bright water pixels. I believe it's essential to address this before the Gamma delivery, so your input on this PR would be greatly appreciated.

oberonia78 commented 6 months ago

@LiangJYu Just finished the modifications. Thanks for the quick review:)