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-37196: Update fields to reflect new APDB schema #690

Merged
merged 1 commit into from
Jun 5, 2023
Merged
Show file tree
Hide file tree
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
4 changes: 2 additions & 2 deletions python/lsst/afw/image/_exposureSummaryStats.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ class ExposureSummaryStats(Storable):
ra: float = float('nan')
"""Bounding box center Right Ascension (degrees)."""

decl: float = float('nan')
dec: float = float('nan')
"""Bounding box center Declination (degrees)."""

zenithDistance: float = float('nan')
Expand Down Expand Up @@ -207,7 +207,7 @@ def update_schema(cls, schema: Schema) -> None:
"ra", type="D", doc="Right Ascension of bounding box center (degrees)"
)
schema.addField(
"decl", type="D", doc="Declination of bounding box center (degrees)"
"dec", type="D", doc="Declination of bounding box center (degrees)"
)
schema.addField(
"zenithDistance",
Expand Down
4 changes: 2 additions & 2 deletions tests/test_exposure.py
Original file line number Diff line number Diff line change
Expand Up @@ -1127,14 +1127,14 @@ def testExposureSummaryExtraComponents(self):
"""Test that we can read an exposure summary with extra components.
"""
testDict = {'ra': 0.0,
'decl': 0.0,
'dec': 0.0,
'nonsense': 1.0}
bytes = yaml.dump(testDict, encoding='utf-8')
with self.assertWarns(FutureWarning):
summaryStats = lsst.afw.image.ExposureSummaryStats._read(bytes)

self.assertEqual(summaryStats.ra, testDict['ra'])
self.assertEqual(summaryStats.decl, testDict['decl'])
self.assertEqual(summaryStats.dec, testDict['dec'])

def testExposureSummarySchema(self):
"""Test that we can make a schema for an exposure summary and populate
Expand Down