Differences in CModel fits between old SDSS deblender and new scarlet

In [1]:
import numpy as np
import matplotlib.pyplot as plt
import os
import pandas as pd
from lsst.daf.persistence import Butler
from lsst.afw.image import Image, MultibandImage, MultibandExposure
from lsst.afw.detection import MultibandFootprint
from lsst.geom import SpherePoint, degrees, radians
from showMultibandImage import showRGB
from makeCutout import cutout_HST
from astropy.visualization import AsinhStretch, ImageNormalize

Load demo data from a tiny (0.5kx0.5k) patch

In [2]:
path = "/datasets/hsc/repo/rerun/private/yusra/deblender-sprint"
subdir = "w_2019_18_05k"
butlerBase = Butler(os.path.join(path, subdir))
scarletMeasTypes = {'noSym': '_noSym_demo'} # 'sym': '' (too many failed)
butlersScarlet = {key: Butler(os.path.join(path, "scarlet", subdir + suffix)) for key, suffix in scarletMeasTypes.items()}
In [3]:
skymap = butlerBase.get("deepCoadd_skyMap")
tract = 9813
patch = (17, 17)
patchname = ','.join([str(idx) for idx in patch])
dataId = {"tract": 9813, "patch": patchname}
filters = "grizy"
namesFilters = ["HSC-" + f.upper() for f in filters]
In [4]:
coadds = [butlerBase.get("deepCoadd_calexp_sub", dataId, filter=f,
                     bbox=skymap[tract][patch[0], patch[1]].getOuterBBox()) for f in namesFilters]
coadds = MultibandExposure.fromExposures(filters, coadds)
In [5]:
fig, axes = plt.subplots(2, 1, figsize=(16, 32))
axes[0].set_title('HSC-[gri]')
showRGB(coadds[:"z"].image, ax=axes[0])
axes[1].set_title('HSC-[izy]')
showRGB(coadds["i":].image, ax=axes[1])