Skip to content

Commit

Permalink
Remove references to HtmIndex20 and ap_HTMIndex (DM-32046)
Browse files Browse the repository at this point in the history
Pixelization is now done internally by Apdb.
  • Loading branch information
andy-slac committed Oct 12, 2021
1 parent a715d53 commit f62bdcb
Show file tree
Hide file tree
Showing 6 changed files with 1 addition and 19 deletions.
5 changes: 0 additions & 5 deletions data/DiaSource.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,6 @@ funcs:
midPointTai:
functor: Column
args: midPointTai
pixelId:
functor: HtmIndex20
args:
- coord_ra
- coord_dec
bboxSize:
functor: Column
args: bboxSize
Expand Down
8 changes: 0 additions & 8 deletions python/lsst/ap/association/diaPipe.py
Original file line number Diff line number Diff line change
Expand Up @@ -249,7 +249,6 @@ def setDefaults(self):
"data",
"apdb-ap-pipe-schema-extra.yaml")
self.diaCalculation.plugins = ["ap_meanPosition",
"ap_HTMIndex",
"ap_nDiaSources",
"ap_diaObjectFlag",
"ap_meanFlux",
Expand All @@ -266,13 +265,6 @@ def setDefaults(self):
"ap_meanTotFlux",
"ap_sigmaTotFlux"]

def validate(self):
pexConfig.Config.validate(self)
# TODO: this plugin is not useful, pixelization is handled by Apdb
if "ap_HTMIndex" not in self.diaCalculation.plugins:
raise ValueError("DiaPipe requires the ap_HTMIndex plugin "
"be enabled for proper insertion into the Apdb.")


class DiaPipelineTask(pipeBase.PipelineTask):
"""Task for loading, associating and storing Difference Image Analysis
Expand Down
2 changes: 1 addition & 1 deletion python/lsst/ap/association/loadDiaCatalogs.py
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ def loadDiaObjects(self, region, apdb):
@pipeBase.timeMethod
def loadDiaSources(self, diaObjects, region, dateTime, apdb):
"""Load DiaSources from the Apdb based on their diaObjectId or
pixelId location.
location.
Variable used to load sources is set in config.
Expand Down
1 change: 0 additions & 1 deletion python/lsst/ap/association/transformDiaSourceCatalog.py
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,6 @@ def run(self,
diaSourceDf["midPointTai"] = diffIm.getInfo().getVisitInfo().getDate().get(system=DateTime.MJD)
diaSourceDf["diaObjectId"] = 0
diaSourceDf["ssObjectId"] = 0
diaSourceDf["pixelId"] = 0
if self.config.doPackFlags:
# either bitpack the flags
self.bitPackFlags(diaSourceDf)
Expand Down
3 changes: 0 additions & 3 deletions tests/data/testDiaSource.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,6 @@ funcs:
midPointTai:
functor: Column
args: midPointTai
pixelId:
functor: Column
args: pixelId
bboxSize:
functor: Column
args: bboxSize
Expand Down
1 change: 0 additions & 1 deletion tests/test_transformDiaSourceCatalog.py
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,6 @@ def test_run(self):
self.assertEqual(src["filterName"], self.filterName)
self.assertEqual(src["midPointTai"],
self.date.get(system=dafBase.DateTime.MJD))
self.assertEqual(src["pixelId"], 0)
self.assertEqual(src["diaObjectId"], 0)

def test_run_dia_source_wrong_flags(self):
Expand Down

0 comments on commit f62bdcb

Please sign in to comment.