Skip to content

Commit

Permalink
RAD-171: Add statistics field to TVAC and FPS schemas (spacetelescope…
Browse files Browse the repository at this point in the history
…#423)

* Initial save.

* Corrected unit tag types.

* Updated Changelog.
  • Loading branch information
PaulHuwe authored May 14, 2024
1 parent cf1ab33 commit c9d7381
Show file tree
Hide file tree
Showing 4 changed files with 202 additions and 0 deletions.
2 changes: 2 additions & 0 deletions CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@

- Separated TVAC and FPS schemas into their own suite of files. [#414]

- Added statistics schemas to both FPS and TVAC. [#423]

- Removed filepath_level_pnt5 from TVAC/FPS database. [#422]

- Removed the db entries for filename_l1a and filename_pnt5 in TVAC and FPS schemas. [#421]
Expand Down
10 changes: 10 additions & 0 deletions src/rad/resources/manifests/datamodels-1.0.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -329,6 +329,11 @@ tags:
title: FPS Guidestar information
description: |-
FPS Guidestar information
- tag_uri: asdf://stsci.edu/datamodels/roman/tags/fps/statistics-1.0.0
schema_uri: asdf://stsci.edu/datamodels/roman/schemas/fps/statistics-1.0.0
title: FPS Summary Statistics
description: |-
FPS Summary Statistics
- tag_uri: asdf://stsci.edu/datamodels/roman/tags/fps/ref_file-1.0.0
schema_uri: asdf://stsci.edu/datamodels/roman/schemas/fps/ref_file-1.0.0
title: FPS Calibration reference file names.
Expand Down Expand Up @@ -406,6 +411,11 @@ tags:
title: TVAC Guidestar information
description: |-
TVAC Guidestar information
- tag_uri: asdf://stsci.edu/datamodels/roman/tags/tvac/statistics-1.0.0
schema_uri: asdf://stsci.edu/datamodels/roman/schemas/tvac/statistics-1.0.0
title: TVAC Summary Statistics
description: |-
TVAC Summary Statistics
- tag_uri: asdf://stsci.edu/datamodels/roman/tags/tvac/ref_file-1.0.0
schema_uri: asdf://stsci.edu/datamodels/roman/schemas/tvac/ref_file-1.0.0
title: TVAC Calibration reference file names.
Expand Down
95 changes: 95 additions & 0 deletions src/rad/resources/schemas/fps/statistics-1.0.0.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,95 @@
%YAML 1.1
---
$schema: asdf://stsci.edu/datamodels/roman/schemas/rad_schema-1.0.0
id: asdf://stsci.edu/datamodels/roman/schemas/fps/statistics-1.0.0


title: |
FPS Summary Statistics
type: object
properties:
mean_counts_per_sec:
title: Mean number of counts per second
description: |
Mean number of counts per second of the data cube
anyOf:
- tag: tag:stsci.edu:asdf/unit/quantity-1.*
properties:
datatype:
enum: ["float64"]
unit:
tag: tag:astropy.org:astropy/units/unit-1.*
enum: ["DN / s"]
- type: "null"
sdf:
special_processing: VALUE_REQUIRED
source:
origin: TBD
archive_catalog:
datatype: float
destination: [WFICommon.mean_counts_per_sec]
median_counts_per_sec:
title: Median number of counts per second
description: |
Median number of counts per second of the data cube
anyOf:
- tag: tag:stsci.edu:asdf/unit/quantity-1.*
properties:
datatype:
enum: ["float64"]
unit:
tag: tag:astropy.org:astropy/units/unit-1.*
enum: ["DN / s"]
- type: "null"
sdf:
special_processing: VALUE_REQUIRED
source:
origin: TBD
archive_catalog:
datatype: float
destination: [WFICommon.median_counts_per_sec]
max_counts:
title: Maximum number of counts
description: |
Maximum number of counts in the data cube
anyOf:
- tag: tag:stsci.edu:asdf/unit/quantity-1.*
properties:
datatype:
enum: ["int32"]
unit:
tag: tag:astropy.org:astropy/units/unit-1.*
enum: ["DN"]
- type: "null"
sdf:
special_processing: VALUE_REQUIRED
source:
origin: TBD
archive_catalog:
datatype: int
destination: [WFICommon.max_counts]
min_counts:
title: Minimum number of counts
description: |
Minimum number of counts in the data cube
anyOf:
- tag: tag:stsci.edu:asdf/unit/quantity-1.*
properties:
datatype:
enum: ["int32"]
unit:
tag: tag:astropy.org:astropy/units/unit-1.*
enum: ["DN"]
- type: "null"
sdf:
special_processing: VALUE_REQUIRED
source:
origin: TBD
archive_catalog:
datatype: int
destination: [WFICommon.min_counts]
propertyOrder: [mean_counts_per_sec, median_counts_per_sec, max_counts, min_counts]
flowStyle: block
required: [mean_counts_per_sec, median_counts_per_sec, max_counts, min_counts]
...
95 changes: 95 additions & 0 deletions src/rad/resources/schemas/tvac/statistics-1.0.0.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,95 @@
%YAML 1.1
---
$schema: asdf://stsci.edu/datamodels/roman/schemas/rad_schema-1.0.0
id: asdf://stsci.edu/datamodels/roman/schemas/tvac/statistics-1.0.0


title: |
TVAC Summary Statistics
type: object
properties:
mean_counts_per_sec:
title: Mean number of counts per second
description: |
Mean number of counts per second of the data cube
anyOf:
- tag: tag:stsci.edu:asdf/unit/quantity-1.*
properties:
datatype:
enum: ["float64"]
unit:
tag: tag:astropy.org:astropy/units/unit-1.*
enum: ["DN / s"]
- type: "null"
sdf:
special_processing: VALUE_REQUIRED
source:
origin: TBD
archive_catalog:
datatype: float
destination: [WFICommon.mean_counts_per_sec]
median_counts_per_sec:
title: Median number of counts per second
description: |
Median number of counts per second of the data cube
anyOf:
- tag: tag:stsci.edu:asdf/unit/quantity-1.*
properties:
datatype:
enum: ["float64"]
unit:
tag: tag:astropy.org:astropy/units/unit-1.*
enum: ["DN / s"]
- type: "null"
sdf:
special_processing: VALUE_REQUIRED
source:
origin: TBD
archive_catalog:
datatype: float
destination: [WFICommon.median_counts_per_sec]
max_counts:
title: Maximum number of counts
description: |
Maximum number of counts in the data cube
anyOf:
- tag: tag:stsci.edu:asdf/unit/quantity-1.*
properties:
datatype:
enum: ["int32"]
unit:
tag: tag:astropy.org:astropy/units/unit-1.*
enum: ["DN"]
- type: "null"
sdf:
special_processing: VALUE_REQUIRED
source:
origin: TBD
archive_catalog:
datatype: int
destination: [WFICommon.max_counts]
min_counts:
title: Minimum number of counts
description: |
Minimum number of counts in the data cube
anyOf:
- tag: tag:stsci.edu:asdf/unit/quantity-1.*
properties:
datatype:
enum: ["int32"]
unit:
tag: tag:astropy.org:astropy/units/unit-1.*
enum: ["DN"]
- type: "null"
sdf:
special_processing: VALUE_REQUIRED
source:
origin: TBD
archive_catalog:
datatype: int
destination: [WFICommon.min_counts]
propertyOrder: [mean_counts_per_sec, median_counts_per_sec, max_counts, min_counts]
flowStyle: block
required: [mean_counts_per_sec, median_counts_per_sec, max_counts, min_counts]
...

0 comments on commit c9d7381

Please sign in to comment.