cxcsds / ciao-contrib

Extra scripts and code to enhance the capabilities of CIAO.
GNU General Public License v3.0
8 stars 6 forks source link

merge_too_small failes to merge mapIDs with 0 counts #849

Closed kglotfelty closed 7 months ago

kglotfelty commented 8 months ago

The error is related to how the tool checks if a mapID is present in input file. This works for what was the original method=area option, but for method=counts this means that mapIDs with 0 counts are not merged with other mapIDs to meet the minimum requirement.

https://github.com/cxcsds/ciao-contrib/blob/a83799bb9b9bf5d223c95ae18f764950d17c1386/bin/merge_too_small#L85

https://github.com/cxcsds/ciao-contrib/blob/a83799bb9b9bf5d223c95ae18f764950d17c1386/bin/merge_too_small#L105

Fix is kinda easy, but initial testing is running far too slow so may need to rework logic to avoid some duplication of effort.