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

srcflux complicated optimized regions #876

Closed kglotfelty closed 2 months ago

kglotfelty commented 6 months ago

With the new regions=optimized option, the regions can become very complicated. They are pass around in string form (since CXCRegion object's can't be pickled) and need to be written to file.

The current method

https://github.com/cxcsds/ciao-contrib/blob/de8e6c146c2741d023ecd205ad63595fcae483f7/bin/srcflux#L438-L440

will fail when the region string becomes very long. As the TODO says, need to replace dmmakereg with CXCRegion to .write() to file.