Skip to content

Commit

Permalink
Merge pull request #1416 from spacetelescope/test
Browse files Browse the repository at this point in the history
Test Deployment for v1.2.1
  • Loading branch information
mfixstsci authored Dec 20, 2023
2 parents 996bda5 + 3c27420 commit 4ce9c29
Show file tree
Hide file tree
Showing 15 changed files with 647 additions and 76 deletions.
13 changes: 13 additions & 0 deletions CHANGES.rst
Original file line number Diff line number Diff line change
@@ -1,5 +1,18 @@
## What's Changed

1.2.1 (2023-12-20)
==================

Web Application
~~~~~~~~~~~~~~~
- Visit Filter on query and archive thumbnails pages by @BradleySappington in https://github.com/spacetelescope/jwql/pull/1412

Project & API Documentation
~~~~~~~~~~~~~~~~~~~~~~~~~~~
- NIRCam Claw Monitor by @bsunnquist in https://github.com/spacetelescope/jwql/pull/1152
- Stop storing absolute paths in the database by @york-stsci in https://github.com/spacetelescope/jwql/pull/1394


1.2.0 (2023-11-21)
==================

Expand Down
7 changes: 5 additions & 2 deletions jwql/database/database_interface.py
Original file line number Diff line number Diff line change
Expand Up @@ -509,14 +509,16 @@ class : obj
NIRSpecCosmicRayStats = monitor_orm_factory('nirspec_cosmic_ray_stats')
NIRSpecTAQueryHistory = monitor_orm_factory('nirspec_ta_query_history')
NIRSpecTAStats = monitor_orm_factory('nirspec_ta_stats')
NIRCamClawQueryHistory = monitor_orm_factory('nircam_claw_query_history')
NIRCamClawStats = monitor_orm_factory('nircam_claw_stats')

INSTRUMENT_TABLES = {
'nircam': [NIRCamDarkQueryHistory, NIRCamDarkPixelStats, NIRCamDarkDarkCurrent,
NIRCamBiasQueryHistory, NIRCamBiasStats, NIRCamBadPixelQueryHistory,
NIRCamBadPixelStats, NIRCamReadnoiseQueryHistory, NIRCamReadnoiseStats,
NIRCamAnomaly, NIRCamCosmicRayQueryHistory, NIRCamCosmicRayStats,
NIRCamEDBDailyStats, NIRCamEDBBlockStats, NIRCamEDBTimeIntervalStats,
NIRCamEDBEveryChangeStats],
NIRCamEDBEveryChangeStats, NIRCamClawQueryHistory, NIRCamClawStats],
'niriss': [NIRISSDarkQueryHistory, NIRISSDarkPixelStats, NIRISSDarkDarkCurrent,
NIRISSBiasQueryHistory, NIRISSBiasStats, NIRISSBadPixelQueryHistory,
NIRISSBadPixelStats, NIRISSReadnoiseQueryHistory, NIRISSReadnoiseStats,
Expand Down Expand Up @@ -570,7 +572,8 @@ class : obj
MIRIEDBBlockStats, MIRIEDBTimeIntervalStats, MIRIEDBEveryChangeStats,
NIRSpecEDBDailyStats, NIRSpecEDBBlockStats, NIRSpecEDBTimeIntervalStats,
NIRSpecEDBEveryChangeStats, FGSEDBDailyStats, FGSEDBBlockStats,
FGSEDBTimeIntervalStats, FGSEDBEveryChangeStats]}
FGSEDBTimeIntervalStats, FGSEDBEveryChangeStats],
'claw': [NIRCamClawQueryHistory, NIRCamClawStats], }

if __name__ == '__main__':
base.metadata.create_all(engine)
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
INSTRUMENT, string
START_TIME_MJD, float
END_TIME_MJD, float
RUN_MONITOR, bool
ENTRY_DATE, datetime
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
FILENAME, string
PROPOSAL, string
OBS, string
DETECTOR, string
FILTER, string
PUPIL, string
EXPSTART, string
EXPSTART_MJD, float
EFFEXPTM, float
RA, float
DEC, float
PA_V3, float
MEAN, float
MEDIAN, float
STDDEV, float
FRAC_MASKED, float
SKYFLAT_FILENAME, string
ENTRY_DATE, datetime
13 changes: 8 additions & 5 deletions jwql/instrument_monitors/common_monitors/readnoise_monitor.py
Original file line number Diff line number Diff line change
Expand Up @@ -413,7 +413,7 @@ def process(self, file_list):
processed_file = file.replace("uncal", "refpix")
if not os.path.isfile(processed_file):
files_to_calibrate.append(file)

# Run the files through the necessary pipeline steps
outputs = run_parallel_pipeline(files_to_calibrate, "uncal", "refpix", self.instrument)

Expand All @@ -422,7 +422,7 @@ def process(self, file_list):

# Get relevant header information for this file
self.get_metadata(filename)

if filename in outputs:
processed_file = outputs[filename]
else:
Expand Down Expand Up @@ -498,20 +498,23 @@ def process(self, file_list):
# Construct new entry for this file for the readnoise database table.
# Can't insert values with numpy.float32 datatypes into database
# so need to change the datatypes of these values.
readnoise_db_entry = {'uncal_filename': filename,
#
# Store files as file name only (file path will be built at retrieval based
# on runtime configuration)
readnoise_db_entry = {'uncal_filename': os.path.basename(filename),
'aperture': self.aperture,
'detector': self.detector,
'subarray': self.subarray,
'read_pattern': self.read_pattern,
'nints': self.nints,
'ngroups': self.ngroups,
'expstart': self.expstart,
'readnoise_filename': readnoise_outfile,
'readnoise_filename': os.path.basename(readnoise_outfile),
'full_image_mean': float(full_image_mean),
'full_image_stddev': float(full_image_stddev),
'full_image_n': full_image_n.astype(float),
'full_image_bin_centers': full_image_bin_centers.astype(float),
'readnoise_diff_image': readnoise_diff_png,
'readnoise_diff_image': os.path.basename(readnoise_diff_png),
'diff_image_mean': float(diff_image_mean),
'diff_image_stddev': float(diff_image_stddev),
'diff_image_n': diff_image_n.astype(float),
Expand Down
Loading

0 comments on commit 4ce9c29

Please sign in to comment.