beast
beast copied to clipboard
create_background_density_map no longer works with photutils >=1.2.0, due to depracation of slices method
beast.tools.create_background_density_map no longer works, due to changes in photutils since v1.2.0. When adding background (as per Standard Workflow docs) using:
python -m beast.tools.create_background_density_map background \
-catfile phot_catalog.fits --npix 15 -reference image.fits
I get a crash that boils down to:
File "/home/cclark/soft/anaconda3/envs/beast-prod/lib/python3.7/site-packages/beast/tools/create_background_density_map.py", line 435, in measure_backgrounds
data_slices = list(ap_mask.bbox.slices)
AttributeError: 'BoundingBox' object has no attribute 'slices'
ap_mask
is a photutils ApertureMask
object, and looking at their documentation, the ApertureMask
no longer has a method slices
, as it was deprecated in Feb 2021 (v1.1.0) and removed in Sep 2021 (v1.2.0). There is a new method, get_overlap_slices
; but it wants different inputs and produces different outputs