Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DM-34770: Compute PSF FWHM at the centroid of the footprint #87

Merged
merged 1 commit into from
May 18, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
10 changes: 4 additions & 6 deletions python/lsst/meas/deblender/sourceDeblendTask.py
Original file line number Diff line number Diff line change
Expand Up @@ -275,10 +275,8 @@ def run(self, exposure, sources):
assert sources.getSchema() == self.schema
self.deblend(exposure, sources, psf)

def _getPsfFwhm(self, psf, bbox):
# It should be easier to get a PSF's fwhm;
# https://dev.lsstcorp.org/trac/ticket/3030
return psf.computeShape().getDeterminantRadius() * 2.35
def _getPsfFwhm(self, psf, position):
return psf.computeShape(position).getDeterminantRadius() * 2.35

@timeMethod
def deblend(self, exposure, srcs, psf):
Expand Down Expand Up @@ -363,8 +361,8 @@ def deblend(self, exposure, srcs, psf):
continue

nparents += 1
bb = fp.getBBox()
psf_fwhm = self._getPsfFwhm(psf, bb)
center = fp.getCentroid()
psf_fwhm = self._getPsfFwhm(psf, center)

self.log.trace('Parent %i: deblending %i peaks', int(src.getId()), len(pks))

Expand Down