dkist-processing-common 13.0.3rc2__tar.gz → 13.0.3rc3__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/PKG-INFO +1 -1
- dkist_processing_common-13.0.3rc3/changelog/322.misc.rst +1 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tasks/quality_metrics.py +21 -33
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_interservice_bus.py +24 -5
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_interservice_bus_mixin.py +16 -2
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_quality.py +27 -27
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common.egg-info/PKG-INFO +1 -1
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common.egg-info/SOURCES.txt +1 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/.gitignore +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/.pre-commit-config.yaml +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/.readthedocs.yml +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/.snyk +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/CHANGELOG.rst +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/README.rst +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/bitbucket-pipelines.yml +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/changelog/.gitempty +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/changelog/326.feature.rst +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/__init__.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/_util/__init__.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/_util/constants.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/_util/graphql.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/_util/scratch.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/_util/tags.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/codecs/__init__.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/codecs/array.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/codecs/asdf.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/codecs/basemodel.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/codecs/bytes.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/codecs/fits.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/codecs/iobase.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/codecs/json.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/codecs/path.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/codecs/quality.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/codecs/str.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/config.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/fonts/Lato-Regular.ttf +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/fonts/__init__.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/manual.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/models/__init__.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/models/constants.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/models/dkist_location.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/models/extras.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/models/fits_access.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/models/flower_pot.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/models/fried_parameter.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/models/graphql.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/models/input_dataset.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/models/message.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/models/message_queue_binding.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/models/metric_code.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/models/parameters.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/models/quality.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/models/tags.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/models/task_name.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/models/telemetry.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/models/wavelength.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/parsers/__init__.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/parsers/average_bud.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/parsers/cs_step.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/parsers/dsps_repeat.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/parsers/experiment_id_bud.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/parsers/id_bud.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/parsers/l0_fits_access.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/parsers/l1_fits_access.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/parsers/lookup_bud.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/parsers/near_bud.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/parsers/observing_program_id_bud.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/parsers/proposal_id_bud.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/parsers/quality.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/parsers/retarder.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/parsers/single_value_single_key_flower.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/parsers/task.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/parsers/time.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/parsers/unique_bud.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/parsers/wavelength.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tasks/__init__.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tasks/assemble_movie.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tasks/base.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tasks/l1_output_data.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tasks/mixin/__init__.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tasks/mixin/globus.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tasks/mixin/interservice_bus.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tasks/mixin/metadata_store.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tasks/mixin/object_store.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tasks/mixin/quality/__init__.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tasks/mixin/quality/_base.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tasks/mixin/quality/_metrics.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tasks/output_data_base.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tasks/parse_l0_input_data.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tasks/teardown.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tasks/transfer_input_data.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tasks/trial_catalog.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tasks/trial_output_data.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tasks/write_extra.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tasks/write_l1.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tasks/write_l1_base.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/__init__.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/conftest.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/mock_metadata_store.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_assemble_movie.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_assemble_quality.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_base.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_codecs.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_constants.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_construct_dataset_extras.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_cs_step.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_dkist_location.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_fits_access.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_flower_pot.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_fried_parameter.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_input_dataset.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_manual_processing.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_output_data_base.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_parameters.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_parse_l0_input_data.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_publish_catalog_messages.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_quality_mixin.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_scratch.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_stems.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_submit_dataset_metadata.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_tags.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_task_name.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_task_parsing.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_teardown.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_transfer_input_data.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_transfer_l1_output_data.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_trial_catalog.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_trial_output_data.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_workflow_task_base.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common/tests/test_write_l1.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common.egg-info/dependency_links.txt +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common.egg-info/requires.txt +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/dkist_processing_common.egg-info/top_level.txt +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/docs/Makefile +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/docs/changelog.rst +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/docs/conf.py +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/docs/index.rst +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/docs/landing_page.rst +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/docs/make.bat +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/docs/requirements.txt +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/licenses/LICENSE.rst +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/pyproject.toml +0 -0
- {dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/setup.cfg +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
Make isb username and password configurable for local unit tests.
|
|
@@ -439,36 +439,22 @@ class QualityL1Metrics(WorkflowTaskBase, QualityMixin):
|
|
|
439
439
|
fits_access_class=L1QualityFitsAccess,
|
|
440
440
|
)
|
|
441
441
|
|
|
442
|
-
#
|
|
443
|
-
|
|
444
|
-
(
|
|
445
|
-
(
|
|
446
|
-
# DATE-BEG
|
|
447
|
-
datetime.fromisoformat(frame.time_obs),
|
|
448
|
-
# LIGHTLVL
|
|
449
|
-
frame.light_level,
|
|
450
|
-
# DSHEALTH
|
|
451
|
-
frame.health_status,
|
|
452
|
-
# ATMOS_R0
|
|
453
|
-
frame.fried_parameter,
|
|
454
|
-
# AO_LOCK
|
|
455
|
-
frame.ao_status,
|
|
456
|
-
# OOBSHIFT
|
|
457
|
-
frame.num_out_of_bounds_ao_values,
|
|
458
|
-
)
|
|
459
|
-
for frame in frames
|
|
460
|
-
),
|
|
461
|
-
# DATE-BEG
|
|
462
|
-
key=lambda row: row[0],
|
|
463
|
-
)
|
|
442
|
+
# sort by datetime
|
|
443
|
+
sorted_frames = sorted(frames, key=lambda f: datetime.fromisoformat(f.time_obs))
|
|
464
444
|
|
|
465
445
|
return L1QualityData(
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
446
|
+
# DATE-BEG
|
|
447
|
+
datetimes=tuple(datetime.fromisoformat(f.time_obs) for f in sorted_frames),
|
|
448
|
+
# LIGHTLVL
|
|
449
|
+
light_level_values=tuple(f.light_level for f in sorted_frames),
|
|
450
|
+
# DSHEALTH
|
|
451
|
+
health_status_values=tuple(f.health_status for f in sorted_frames),
|
|
452
|
+
# ATMOS_R0
|
|
453
|
+
fried_parameter_values=tuple(f.fried_parameter for f in sorted_frames),
|
|
454
|
+
# AO_LOCK
|
|
455
|
+
ao_lock_values=tuple(f.ao_status for f in sorted_frames),
|
|
456
|
+
# OOBSHIFT
|
|
457
|
+
ao_oob_values=tuple(f.num_out_of_bounds_ao_values for f in sorted_frames),
|
|
472
458
|
)
|
|
473
459
|
|
|
474
460
|
def compute_and_write_l1_quality_metrics(self, l1_quality_data: L1QualityData) -> None:
|
|
@@ -575,19 +561,21 @@ class QualityL1Metrics(WorkflowTaskBase, QualityMixin):
|
|
|
575
561
|
rows.extend(tuple(z) for z in zip(statuses, counts))
|
|
576
562
|
table_data = TableData(rows=tuple(rows))
|
|
577
563
|
|
|
564
|
+
warnings = None
|
|
565
|
+
if any(s in statuses for s in ["bad", "ill", "unknown"]):
|
|
566
|
+
warnings = [
|
|
567
|
+
"Data sourced from components with a health status of 'ill', 'bad', or 'unknown'."
|
|
568
|
+
]
|
|
569
|
+
|
|
578
570
|
metric = QualityMetric(
|
|
579
571
|
name="Data Source Health",
|
|
580
572
|
description="This metric contains the worst health status of the data source during "
|
|
581
573
|
"data acquisition. One reading is taken per L1 frame.",
|
|
582
574
|
metric_code=MetricCode.health_status,
|
|
583
575
|
table_data=[table_data],
|
|
576
|
+
warnings=warnings,
|
|
584
577
|
)
|
|
585
578
|
|
|
586
|
-
if any(s in statuses for s in ["bad", "ill", "unknown"]):
|
|
587
|
-
metric.warnings = [
|
|
588
|
-
"Data sourced from components with a health status of 'ill', 'bad', or 'unknown'."
|
|
589
|
-
]
|
|
590
|
-
|
|
591
579
|
self.write(metric, tags=Tag.quality("GENERIC"), encoder=basemodel_encoder)
|
|
592
580
|
|
|
593
581
|
def compute_and_write_light_level(self, l1_quality_data: L1QualityData) -> None:
|
|
@@ -4,8 +4,9 @@ from typing import Type
|
|
|
4
4
|
from uuid import uuid4
|
|
5
5
|
|
|
6
6
|
import pytest
|
|
7
|
+
from pika import ConnectionParameters
|
|
8
|
+
from pika.credentials import PlainCredentials
|
|
7
9
|
from pydantic import BaseModel
|
|
8
|
-
from pydantic import Field
|
|
9
10
|
from talus import Binding
|
|
10
11
|
from talus import ConsumeMessageBase
|
|
11
12
|
from talus import DurableConsumer
|
|
@@ -15,6 +16,8 @@ from talus import MessageBodyBase
|
|
|
15
16
|
from talus import PublishMessageBase
|
|
16
17
|
from talus import Queue
|
|
17
18
|
|
|
19
|
+
from dkist_processing_common.config import common_configurations
|
|
20
|
+
|
|
18
21
|
|
|
19
22
|
@pytest.fixture
|
|
20
23
|
def sample_message_body():
|
|
@@ -59,19 +62,35 @@ def consume_message(sample_message):
|
|
|
59
62
|
|
|
60
63
|
|
|
61
64
|
@pytest.fixture
|
|
62
|
-
def
|
|
65
|
+
def connection_parameters() -> ConnectionParameters:
|
|
66
|
+
isb_username = common_configurations.isb_username
|
|
67
|
+
isb_password = common_configurations.isb_password
|
|
68
|
+
connection_parameters = ConnectionParameters(
|
|
69
|
+
credentials=PlainCredentials(isb_username, isb_password)
|
|
70
|
+
)
|
|
71
|
+
return connection_parameters
|
|
72
|
+
|
|
73
|
+
|
|
74
|
+
@pytest.fixture
|
|
75
|
+
def producer(sample_message, publish_message, connection_parameters):
|
|
63
76
|
exchange = sample_message.exchange
|
|
64
77
|
binding = Binding(queue=sample_message.queue, message=publish_message)
|
|
65
|
-
with DurableProducer(
|
|
78
|
+
with DurableProducer(
|
|
79
|
+
queue_bindings=binding,
|
|
80
|
+
publish_exchange=exchange,
|
|
81
|
+
connection_parameters=connection_parameters,
|
|
82
|
+
) as p:
|
|
66
83
|
yield p
|
|
67
84
|
p.channel.queue_delete(queue=sample_message.queue.name)
|
|
68
85
|
p.channel.exchange_delete(exchange=sample_message.exchange.name)
|
|
69
86
|
|
|
70
87
|
|
|
71
88
|
@pytest.fixture
|
|
72
|
-
def consumer(sample_message):
|
|
89
|
+
def consumer(sample_message, connection_parameters):
|
|
73
90
|
queue = sample_message.queue
|
|
74
|
-
with DurableConsumer(
|
|
91
|
+
with DurableConsumer(
|
|
92
|
+
consume_queue=queue, prefetch_count=100, connection_parameters=connection_parameters
|
|
93
|
+
) as c:
|
|
75
94
|
yield c
|
|
76
95
|
c.channel.queue_delete(queue=sample_message.queue.name)
|
|
77
96
|
c.channel.exchange_delete(exchange=sample_message.exchange.name)
|
|
@@ -5,6 +5,8 @@ from typing import Dict
|
|
|
5
5
|
from typing import Type
|
|
6
6
|
|
|
7
7
|
import pytest
|
|
8
|
+
from pika import ConnectionParameters
|
|
9
|
+
from pika.credentials import PlainCredentials
|
|
8
10
|
from pydantic import BaseModel
|
|
9
11
|
from talus import ConsumeMessageBase
|
|
10
12
|
from talus import DurableConsumer
|
|
@@ -77,9 +79,21 @@ def consume_message(task_message):
|
|
|
77
79
|
|
|
78
80
|
|
|
79
81
|
@pytest.fixture
|
|
80
|
-
def
|
|
82
|
+
def connection_parameters() -> ConnectionParameters:
|
|
83
|
+
isb_username = common_configurations.isb_username
|
|
84
|
+
isb_password = common_configurations.isb_password
|
|
85
|
+
connection_parameters = ConnectionParameters(
|
|
86
|
+
credentials=PlainCredentials(isb_username, isb_password)
|
|
87
|
+
)
|
|
88
|
+
return connection_parameters
|
|
89
|
+
|
|
90
|
+
|
|
91
|
+
@pytest.fixture
|
|
92
|
+
def consumer(task_message, connection_parameters):
|
|
81
93
|
queue = task_message.queue
|
|
82
|
-
with DurableConsumer(
|
|
94
|
+
with DurableConsumer(
|
|
95
|
+
consume_queue=queue, prefetch_count=100, connection_parameters=connection_parameters
|
|
96
|
+
) as c:
|
|
83
97
|
yield c
|
|
84
98
|
# Clean up all the queues, skipping queues that are not empty:
|
|
85
99
|
for binding in common_message_queue_bindings:
|
|
@@ -737,9 +737,9 @@ def test_ao_status(quality_l1_task_with_calibrated_frames: QualityL1Metrics):
|
|
|
737
737
|
# Then
|
|
738
738
|
metric_code = "AO_STATUS"
|
|
739
739
|
tags = [Tag.quality("GENERIC")]
|
|
740
|
-
metrics =
|
|
741
|
-
|
|
742
|
-
|
|
740
|
+
metrics: list[QualityMetric] = list(
|
|
741
|
+
task.read(tags=tags, decoder=basemodel_decoder, model=QualityMetric)
|
|
742
|
+
)
|
|
743
743
|
assert len([metric for metric in metrics if metric.metric_code in metric_code]) == 1
|
|
744
744
|
for metric in metrics:
|
|
745
745
|
if metric.metric_code != metric_code:
|
|
@@ -772,9 +772,9 @@ def test_fried_parameter(
|
|
|
772
772
|
# Then
|
|
773
773
|
metric_code = "FRIED_PARAMETER"
|
|
774
774
|
tags = [Tag.quality("GENERIC")]
|
|
775
|
-
metrics =
|
|
776
|
-
|
|
777
|
-
|
|
775
|
+
metrics: list[QualityMetric] = list(
|
|
776
|
+
task.read(tags=tags, decoder=basemodel_decoder, model=QualityMetric)
|
|
777
|
+
)
|
|
778
778
|
assert len([metric for metric in metrics if metric.metric_code in metric_code]) == 1
|
|
779
779
|
for metric in metrics:
|
|
780
780
|
if metric.metric_code != metric_code:
|
|
@@ -823,9 +823,9 @@ def test_health_status(quality_l1_task_with_calibrated_frames: QualityL1Metrics)
|
|
|
823
823
|
# Then
|
|
824
824
|
metric_code = "HEALTH_STATUS"
|
|
825
825
|
tags = [Tag.quality("GENERIC")]
|
|
826
|
-
metrics =
|
|
827
|
-
|
|
828
|
-
|
|
826
|
+
metrics: list[QualityMetric] = list(
|
|
827
|
+
task.read(tags=tags, decoder=basemodel_decoder, model=QualityMetric)
|
|
828
|
+
)
|
|
829
829
|
assert len([metric for metric in metrics if metric.metric_code in metric_code]) == 1
|
|
830
830
|
for metric in metrics:
|
|
831
831
|
if metric.metric_code != metric_code:
|
|
@@ -867,9 +867,9 @@ def test_light_level(
|
|
|
867
867
|
# Then
|
|
868
868
|
metric_code = "LIGHT_LEVEL"
|
|
869
869
|
tags = [Tag.quality("GENERIC")]
|
|
870
|
-
metrics =
|
|
871
|
-
|
|
872
|
-
|
|
870
|
+
metrics: list[QualityMetric] = list(
|
|
871
|
+
task.read(tags=tags, decoder=basemodel_decoder, model=QualityMetric)
|
|
872
|
+
)
|
|
873
873
|
assert len([metric for metric in metrics if metric.metric_code in metric_code]) == 1
|
|
874
874
|
for metric in metrics:
|
|
875
875
|
if metric.metric_code != metric_code:
|
|
@@ -919,9 +919,9 @@ def test_compute_and_write_ao_status(
|
|
|
919
919
|
task.compute_and_write_ao_status(l1_quality_data)
|
|
920
920
|
# Then
|
|
921
921
|
tags = [Tag.quality("GENERIC")]
|
|
922
|
-
metrics: list[QualityMetric] =
|
|
923
|
-
|
|
924
|
-
|
|
922
|
+
metrics: list[QualityMetric] = list(
|
|
923
|
+
task.read(tags=tags, decoder=basemodel_decoder, model=QualityMetric)
|
|
924
|
+
)
|
|
925
925
|
assert len(metrics) == 1
|
|
926
926
|
metric = metrics[0]
|
|
927
927
|
# basics
|
|
@@ -956,9 +956,9 @@ def test_compute_and_write_fried_parameter(
|
|
|
956
956
|
task.compute_and_write_fried_parameter(l1_quality_data)
|
|
957
957
|
# Then
|
|
958
958
|
tags = [Tag.quality("GENERIC")]
|
|
959
|
-
metrics: list[QualityMetric] =
|
|
960
|
-
|
|
961
|
-
|
|
959
|
+
metrics: list[QualityMetric] = list(
|
|
960
|
+
task.read(tags=tags, decoder=basemodel_decoder, model=QualityMetric)
|
|
961
|
+
)
|
|
962
962
|
assert len(metrics) == 1
|
|
963
963
|
metric = metrics[0]
|
|
964
964
|
# basics
|
|
@@ -1013,9 +1013,9 @@ def test_compute_and_write_health_status(
|
|
|
1013
1013
|
task.compute_and_write_health_status(l1_quality_data)
|
|
1014
1014
|
# Then
|
|
1015
1015
|
tags = [Tag.quality("GENERIC")]
|
|
1016
|
-
metrics: list[QualityMetric] =
|
|
1017
|
-
|
|
1018
|
-
|
|
1016
|
+
metrics: list[QualityMetric] = list(
|
|
1017
|
+
task.read(tags=tags, decoder=basemodel_decoder, model=QualityMetric)
|
|
1018
|
+
)
|
|
1019
1019
|
assert len(metrics) == 1
|
|
1020
1020
|
metric = metrics[0]
|
|
1021
1021
|
# basics
|
|
@@ -1069,9 +1069,9 @@ def test_compute_and_write_light_level(
|
|
|
1069
1069
|
task.compute_and_write_light_level(l1_quality_data)
|
|
1070
1070
|
# Then
|
|
1071
1071
|
tags = [Tag.quality("GENERIC")]
|
|
1072
|
-
metrics: list[QualityMetric] =
|
|
1073
|
-
|
|
1074
|
-
|
|
1072
|
+
metrics: list[QualityMetric] = list(
|
|
1073
|
+
task.read(tags=tags, decoder=basemodel_decoder, model=QualityMetric)
|
|
1074
|
+
)
|
|
1075
1075
|
assert len(metrics) == 1
|
|
1076
1076
|
metric = metrics[0]
|
|
1077
1077
|
# basics
|
|
@@ -1122,7 +1122,7 @@ def test_no_calibration_frames_no_l1_metrics(quality_l1_task_no_scratch_data: Qu
|
|
|
1122
1122
|
task()
|
|
1123
1123
|
# Then
|
|
1124
1124
|
tags = [Tag.quality("GENERIC")]
|
|
1125
|
-
metrics =
|
|
1126
|
-
|
|
1127
|
-
|
|
1125
|
+
metrics: list[QualityMetric] = list(
|
|
1126
|
+
task.read(tags=tags, decoder=basemodel_decoder, model=QualityMetric)
|
|
1127
|
+
)
|
|
1128
1128
|
assert len(metrics) == 0
|
|
File without changes
|
{dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/.pre-commit-config.yaml
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/bitbucket-pipelines.yml
RENAMED
|
File without changes
|
|
File without changes
|
{dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/changelog/326.feature.rst
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/docs/landing_page.rst
RENAMED
|
File without changes
|
|
File without changes
|
{dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/docs/requirements.txt
RENAMED
|
File without changes
|
{dkist_processing_common-13.0.3rc2 → dkist_processing_common-13.0.3rc3}/licenses/LICENSE.rst
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|