dkist-processing-visp 2.20.14__py3-none-any.whl → 5.1.1__py3-none-any.whl

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.
Files changed (73) hide show
  1. dkist_processing_visp/__init__.py +1 -0
  2. dkist_processing_visp/config.py +1 -0
  3. dkist_processing_visp/models/constants.py +61 -20
  4. dkist_processing_visp/models/fits_access.py +20 -0
  5. dkist_processing_visp/models/metric_code.py +10 -0
  6. dkist_processing_visp/models/parameters.py +129 -24
  7. dkist_processing_visp/models/tags.py +22 -1
  8. dkist_processing_visp/models/task_name.py +1 -0
  9. dkist_processing_visp/parsers/map_repeats.py +1 -0
  10. dkist_processing_visp/parsers/modulator_states.py +1 -0
  11. dkist_processing_visp/parsers/polarimeter_mode.py +4 -2
  12. dkist_processing_visp/parsers/raster_step.py +4 -1
  13. dkist_processing_visp/parsers/spectrograph_configuration.py +75 -0
  14. dkist_processing_visp/parsers/time.py +24 -14
  15. dkist_processing_visp/parsers/visp_l0_fits_access.py +19 -8
  16. dkist_processing_visp/parsers/visp_l1_fits_access.py +1 -0
  17. dkist_processing_visp/tasks/__init__.py +1 -0
  18. dkist_processing_visp/tasks/assemble_movie.py +1 -0
  19. dkist_processing_visp/tasks/background_light.py +2 -1
  20. dkist_processing_visp/tasks/dark.py +5 -4
  21. dkist_processing_visp/tasks/geometric.py +132 -20
  22. dkist_processing_visp/tasks/instrument_polarization.py +128 -18
  23. dkist_processing_visp/tasks/l1_output_data.py +203 -0
  24. dkist_processing_visp/tasks/lamp.py +53 -93
  25. dkist_processing_visp/tasks/make_movie_frames.py +8 -6
  26. dkist_processing_visp/tasks/mixin/beam_access.py +1 -0
  27. dkist_processing_visp/tasks/mixin/corrections.py +54 -4
  28. dkist_processing_visp/tasks/mixin/downsample.py +1 -0
  29. dkist_processing_visp/tasks/parse.py +50 -17
  30. dkist_processing_visp/tasks/quality_metrics.py +5 -4
  31. dkist_processing_visp/tasks/science.py +126 -46
  32. dkist_processing_visp/tasks/solar.py +896 -456
  33. dkist_processing_visp/tasks/visp_base.py +4 -3
  34. dkist_processing_visp/tasks/write_l1.py +38 -10
  35. dkist_processing_visp/tests/conftest.py +145 -47
  36. dkist_processing_visp/tests/header_models.py +157 -20
  37. dkist_processing_visp/tests/local_trial_workflows/l0_cals_only.py +21 -78
  38. dkist_processing_visp/tests/local_trial_workflows/l0_polcals_as_science.py +421 -0
  39. dkist_processing_visp/tests/local_trial_workflows/l0_solar_gain_as_science.py +387 -0
  40. dkist_processing_visp/tests/local_trial_workflows/l0_to_l1.py +18 -75
  41. dkist_processing_visp/tests/local_trial_workflows/local_trial_helpers.py +346 -14
  42. dkist_processing_visp/tests/test_assemble_movie.py +2 -3
  43. dkist_processing_visp/tests/test_assemble_quality.py +89 -4
  44. dkist_processing_visp/tests/test_background_light.py +51 -44
  45. dkist_processing_visp/tests/test_dark.py +4 -3
  46. dkist_processing_visp/tests/test_downsample.py +1 -0
  47. dkist_processing_visp/tests/test_fits_access.py +43 -0
  48. dkist_processing_visp/tests/test_geometric.py +45 -4
  49. dkist_processing_visp/tests/test_instrument_polarization.py +72 -9
  50. dkist_processing_visp/tests/test_lamp.py +22 -26
  51. dkist_processing_visp/tests/test_make_movie_frames.py +4 -4
  52. dkist_processing_visp/tests/test_map_repeats.py +3 -1
  53. dkist_processing_visp/tests/test_parameters.py +122 -21
  54. dkist_processing_visp/tests/test_parse.py +164 -18
  55. dkist_processing_visp/tests/test_quality.py +3 -4
  56. dkist_processing_visp/tests/test_science.py +113 -15
  57. dkist_processing_visp/tests/test_solar.py +318 -99
  58. dkist_processing_visp/tests/test_visp_constants.py +38 -8
  59. dkist_processing_visp/tests/test_workflows.py +1 -0
  60. dkist_processing_visp/tests/test_write_l1.py +22 -3
  61. dkist_processing_visp/workflows/__init__.py +1 -0
  62. dkist_processing_visp/workflows/l0_processing.py +10 -3
  63. dkist_processing_visp/workflows/trial_workflows.py +8 -2
  64. dkist_processing_visp-5.1.1.dist-info/METADATA +552 -0
  65. dkist_processing_visp-5.1.1.dist-info/RECORD +94 -0
  66. {dkist_processing_visp-2.20.14.dist-info → dkist_processing_visp-5.1.1.dist-info}/WHEEL +1 -1
  67. docs/conf.py +5 -1
  68. docs/gain_correction.rst +52 -44
  69. docs/science_calibration.rst +7 -0
  70. dkist_processing_visp/tasks/mixin/line_zones.py +0 -115
  71. dkist_processing_visp-2.20.14.dist-info/METADATA +0 -196
  72. dkist_processing_visp-2.20.14.dist-info/RECORD +0 -89
  73. {dkist_processing_visp-2.20.14.dist-info → dkist_processing_visp-5.1.1.dist-info}/top_level.txt +0 -0
docs/conf.py CHANGED
@@ -1,4 +1,5 @@
1
1
  """Configuration file for the Sphinx documentation builder."""
2
+
2
3
  # -- stdlib imports ------------------------------------------------------------
3
4
  import importlib
4
5
  import sys
@@ -32,7 +33,10 @@ autoapi_dirs = [Path(package.__file__).parent]
32
33
  # autoapi_keep_files = True
33
34
 
34
35
  # -- Options for intersphinx extension -----------------------------------------
35
- intersphinx_mapping = create_intersphinx_mapping(repo_name)
36
+ intersphinx_mapping = create_intersphinx_mapping(repo_name) | {
37
+ "lmfit": ("https://lmfit.github.io/lmfit-py", None),
38
+ "sklearn": ("https://scikit-learn.org/stable/", None),
39
+ }
36
40
  # Remaining sphinx settings are in dkist-sphinx-theme conf.py
37
41
 
38
42
  # -- Project information -------------------------------------------------------
docs/gain_correction.rst CHANGED
@@ -4,8 +4,8 @@ Gain Calibration
4
4
  Introduction
5
5
  ------------
6
6
 
7
- NOTE: The usage of the term "gain" throughout this document refers to total system response of the DKIST/ViSP optical
8
- train; it does NOT refer to the detector gain that has units of ADU / electron. Sometimes the term "flat" is used in
7
+ NOTE: The usage of the term "gain" throughout this document refers to the total system response of the DKIST/ViSP optical
8
+ train; it does NOT refer to the detector gain that has units of ADU / electron. Often the term "flat" is used in
9
9
  a way that is interchangeable with the usage of "gain" in this document.
10
10
 
11
11
  The ViSP gain calibration is broken down into the following steps across two pipeline tasks
@@ -13,27 +13,28 @@ The ViSP gain calibration is broken down into the following steps across two pip
13
13
 
14
14
  #. Subtract dark and :doc:`background <background_light>` signals from all input gain images.
15
15
 
16
- #. Compute an average, equalized lamp gain and mask the hairlines.
16
+ #. Compute an average lamp gain and mask the hairlines.
17
17
 
18
- #. Divide the solar gain by the resulting lamp image and correct for :doc:`geometric </geometric>` rotation/shifts and
18
+ #. Divide the solar gain by the resulting lamp image and correct for :doc:`geometric </geometric>` rotation and
19
19
  spectral curvature.
20
20
 
21
- #. Mask hairlines and compute 2D characteristic solar spectra with spatial median filter.
21
+ #. Separate the true solar spectrum from vignetting effects by fitting a solar atlas to the solar gain data.
22
22
 
23
- #. Re-curve/shift/rotate the characteristic spectra into the same coordinates as the input frames.
23
+ #. Mask hairlines and compute a 2D characteristic solar spectra with a spatial median filter over the vignette-corrected solar gain data.
24
+
25
+ #. Re-curve and rotate the characteristic spectra into the same coordinates as the input frames.
24
26
 
25
27
  #. Remove the characteristic spectra from solar gain images that have NOT had a lamp correction applied.
26
28
 
27
- The result is a final gain image that can be applied to science data. Note that all steps happen separately for every
28
- modulator state and beam. This is because the geometric x/y shifts have been found to be significantly different for each
29
- modulator state and beam.
29
+ The result is a final gain image that can be applied to science data. Note that all steps happen separately for each
30
+ beam to capture the differences in optical response between the two beams.
30
31
 
31
32
  Important Features
32
33
  ------------------
33
34
 
34
35
  The final gain images (those used to correct science frames) are *not* normalized; they retain their original input values.
35
- As a result, pixel values in the L1 data will be normalized to the average solar signal at disk center on the day of calibrations
36
- (usually the same day as science acquisition). Note that this is **NOT** intended to be an accurate photometric calibration.
36
+ As a result, pixel values in the L1 data will be normalized to the average solar signal at disk center on the day of calibration
37
+ acquisition (usually the same day as science acquisition). Note that this is **NOT** intended to be an accurate photometric calibration.
37
38
 
38
39
  Algorithm Detail
39
40
  ----------------
@@ -49,40 +50,53 @@ from all input frames.
49
50
  Average Lamp Frames and Mask Hairlines
50
51
  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
51
52
 
52
- All lamp frames for a particular modulator state and beam are averaged into a single array. The slit hairlines are then
53
- identified by smoothing the image in the spatial dimension and then computing the relative difference between this smoothed
54
- image and the original image. Any pixels that deviate by a large amount (set by the ``hairline_fraction`` parameter) are
55
- considered to be hairline pixels. These hairline pixels are masked by replacing them with values from the smoothed array.
56
-
57
- Lamp gains for all modulator states are then compared and equalized so each individual modulator state has the same
58
- median as the median of all (pre-equalized) modulator states. This step helps to mitigate any residual polarization that
59
- may exist in input gain images that would otherwise affect the residual continuum polarization in the processed
60
- science frames.
61
-
62
- Finally, all lamp gain images have any spatial intensity gradients removed by normalizing each spatial position by its
63
- median. This removes known gradients caused by the different input illumination of the lamp compared to the Sun.
53
+ All lamp frames for a single beam are averaged into a single array. The slit hairlines are then identified by smoothing
54
+ the image in the spatial dimension and then computing the relative difference between this smoothed image and the
55
+ original image. Any pixels that deviate by a large amount (set by the ``hairline_fraction`` parameter) are considered to
56
+ be hairline pixels. These hairline pixels are masked by replacing them with values from the smoothed array.
64
57
 
65
58
  Prepare and Rectify Solar Frames
66
59
  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
67
60
 
68
- The averaged modulated lamp frames from the previous step are applied to dark/background subtracted solar gain frames through
69
- division. Then the pre-computed :doc:`geometric </geometric>` correction removes any spectral rotation, x/y shifts, and
70
- spectral curvature (in that order). At the end of this step the dispersion axis will be parallel to a pixel axis and a
71
- single spectral pixel will have the same physical wavelength value for all spatial pixels.
61
+ The averaged lamp frames from the previous step are applied to dark/background subtracted solar gain frames through
62
+ division. Then the pre-computed :doc:`geometric </geometric>` correction removes any spectral rotation and spectral
63
+ curvature (in that order). Note that at this point we do NOT correct for X/Y offsets for two reasons: 1). a separate gain
64
+ is computed for each beam so applying the beam offsets is not necessary, and 2). it has been found that the
65
+ modstate-to-modstate offsets are small enough to ignore when making gain frames. At the end of this step the dispersion
66
+ axis will be parallel to a pixel axis and a single spectral pixel will have the same physical wavelength value for all
67
+ spatial pixels.
68
+
69
+ Separate Solar and Vignette Signals
70
+ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
71
+
72
+ Aperture masks in ViSP cause known vignetting in both the spatial and spectral dimensions and we need to capture this
73
+ vignetting in our final gain images so it can be correctly removed from science data. To separate the spectral vignette
74
+ signature from the true solar spectrum we fit a representative spectrum to a solar atlas with a parameterized continuum.
75
+ The representative spectrum is a spatial median of the rectified solar gain array, and the continuum is parameterized as
76
+ a polynomial with an order set by the ``solar_vignette_initial_continuum_poly_fit_order`` parameter. Atlas fits are
77
+ done with the `solar-wavelength-calibration <https://docs.dkist.nso.edu/projects/solar-wavelength-calibration/en/latest/>`_
78
+ package. We take the fit continuum as a first estimate of the vignette signal in the spectral dimension.
79
+
80
+ This first vignette estimate is then removed from the representative spectrum, thus producing an estimate of the true
81
+ solar signal, and that spectrum is divided from every spatial pixel of the gain array. The residuals capture how the
82
+ vignette signal varies with spatial and spectral position across the chip. We fit these residuals for each spatial pixel
83
+ to compute a fully 2D estimate of the true vignette signal. The order of this polynomial fit is set by the
84
+ ``solar_vignette_spectral_poly_fit_order`` parameter.
72
85
 
73
86
  Compute Characteristic Spectra
74
87
  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
75
88
 
76
- First, the slit hairlines are masked using the same method as :ref:`above <hairline-description>`.
89
+ First, the 2D vignette signal is divided from the solar gain array and the slit hairlines are masked using the same
90
+ method as :ref:`above <hairline-description>`.
77
91
 
78
92
  The goal of this step is to derive pure solar spectra, free from any optical effects of the DKIST/ViSP system. By applying
79
- lamp gain frames to our solar images we have already removed a lot of optical effects, but some spatial variations still
80
- remain. Thus, the characteristic spectra is computed by applying a median filter (with width controlled by the
81
- ``solar_spectral_avg_window`` parameter) in the spatial direction. Previously, a single, median spectrum had been used,
82
- but it did not accurately capture small, but important variations in spectral shape along the slit.
93
+ lamp gain and vignette corrections to our solar images we have already removed a lot of optical effects, but some spatial
94
+ variations still remain. Thus, the characteristic spectra is computed by applying a median filter (with width controlled
95
+ by the ``solar_spatial_median_filter_width_px`` parameter) in the spatial direction. Previously, a single, median spectrum had been
96
+ used, but it did not accurately capture small, but important variations in spectral shape along the slit.
83
97
 
84
- Finally, the smooth characteristic spectra has any spatial gradients removed by normalizing each spatial positions by its
85
- median. This ensures that the characteristic spectra contain *only* pure solar spectra, and thus any real spatial
98
+ Finally, the smooth characteristic spectra have any spatial gradients removed by normalizing each spatial position by its
99
+ continuum level. This ensures that the characteristic spectra contain *only* pure solar spectra, and thus any real spatial
86
100
  gradients are preserved in the final gain image. This normalization also ensures the absolute flux of the final
87
101
  gain images is preserved so that science frames will have values relative to average disk center (where the solar images
88
102
  are taken).
@@ -90,21 +104,15 @@ are taken).
90
104
  Un-rectify Characteristic Spectra
91
105
  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
92
106
 
93
- The characteristic spectra have spectral shifts, x/y offsets, and spectral rotation re-applied to bring them back into
94
- raw input pixel coordinates.
95
-
96
- The spectral curvature is NOT applied using the precomputed curvature. Instead, for each spatial position a new spectral
97
- shift is computed that minimizes the residual of the final gain image at that position. This step is needed because the
98
- characteristic spectra have *slightly* different spectral shapes than the input solar image (see above) and any small
99
- misalignment causes large, sharp residuals in the line wings. By explicitly minimizing final gain residuals we ensure
100
- that the new spectral shifts remove the solar signal as much as possible.
107
+ The characteristic spectra have spectral shifts and spectral rotation re-applied to bring them back into raw input pixel
108
+ coordinates.
101
109
 
102
110
  Remove Characteristic Solar Spectra from Input Solar Frames
103
111
  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
104
112
 
105
113
  The dark/background corrected solar gain image is simply divided by the re-distorted characteristic spectra. Because we
106
- do NOT use a solar image with a lamp correction applied, the resulting gain image includes the full optical response of
107
- the system and can be applied directly to the science data.
114
+ do NOT use a solar image with a lamp or vignette correction applied, the resulting gain image includes the full optical
115
+ response of the system and can be applied directly to the science data.
108
116
 
109
117
  As mentioned above, these gain calibration images are not normalized. The result is that L1 science data will have
110
118
  values that are relative to solar disk center (where the solar gain images are observed).
@@ -11,6 +11,13 @@ may not be obvious.
11
11
  Important Features
12
12
  ------------------
13
13
 
14
+ Pixel Units
15
+ ^^^^^^^^^^^
16
+
17
+ The :doc:`gain arrays </gain_correction>` used to correct science data are *not* normalized; they retain their original input values.
18
+ As a result, pixel values in the L1 data will be normalized to the average solar signal at disk center on the day of calibration
19
+ acquisition (usually the same day as science acquisition). Note that this is **NOT** intended to be an accurate photometric calibration.
20
+
14
21
  Beam Combination
15
22
  ^^^^^^^^^^^^^^^^
16
23
 
@@ -1,115 +0,0 @@
1
- """Helper functions for line zone determination."""
2
- import numpy as np
3
- import peakutils
4
- import scipy.signal as sps
5
- from dkist_service_configuration.logging import logger
6
-
7
-
8
- class LineZonesMixin:
9
- """Helper functions for line zone determination."""
10
-
11
- def compute_line_zones(
12
- self,
13
- spec_2d: np.ndarray,
14
- prominence: float = 0.2,
15
- width: float = 2,
16
- bg_order: int = 22,
17
- normalization_percentile: int = 99,
18
- rel_height=0.97,
19
- ) -> list[tuple[int, int]]:
20
- """
21
- Identify spectral regions around strong spectra features.
22
-
23
- Parameters
24
- ----------
25
- spec_2d : np.ndarray
26
- Data
27
-
28
- prominence : float
29
- Zone prominence threshold used to identify strong spectral features
30
-
31
- width : float
32
- Zone width
33
-
34
- bg_order : int
35
- Order of polynomial fit used to remove continuum when identifying strong spectral features
36
-
37
- normalization_percentile : int
38
- Compute this percentile of the data along a specified axis
39
-
40
-
41
-
42
- Returns
43
- -------
44
- List
45
- List of regions to remove
46
-
47
- """
48
- logger.info(
49
- f"Finding zones using {prominence=}, {width=}, {bg_order=}, {normalization_percentile=}, and {rel_height=}"
50
- )
51
- # Compute average along slit to improve signal. Line smearing isn't important here
52
- avg_1d = np.mean(spec_2d, axis=1)
53
-
54
- # Convert to an emission spectrum and remove baseline continuum so peakutils has an easier time
55
- em_spec = -1 * avg_1d + avg_1d.max()
56
- em_spec /= np.nanpercentile(em_spec, normalization_percentile)
57
- baseline = peakutils.baseline(em_spec, bg_order)
58
- em_spec -= baseline
59
-
60
- # Find indices of peaks
61
- peak_idxs = sps.find_peaks(em_spec, prominence=prominence, width=width)[0]
62
-
63
- # Find the rough width based only on the height of the peak
64
- # rips and lips are the right and left borders of the region around the peak
65
- _, _, rips, lips = sps.peak_widths(em_spec, peak_idxs, rel_height=rel_height)
66
-
67
- # Convert to ints so they can be used as indices
68
- rips = np.floor(rips).astype(int)
69
- lips = np.ceil(lips).astype(int)
70
-
71
- # Remove any regions that are contained within another region
72
- ranges_to_remove = self.identify_overlapping_zones(rips, lips)
73
- rips = np.delete(rips, ranges_to_remove)
74
- lips = np.delete(lips, ranges_to_remove)
75
-
76
- return list(zip(rips, lips))
77
-
78
- @staticmethod
79
- def identify_overlapping_zones(rips: np.ndarray, lips: np.ndarray) -> list[int]:
80
- """
81
- Identify line zones that overlap with other zones. Any overlap greater than 1 pixel is flagged.
82
-
83
- Parameters
84
- ----------
85
- rips : np.ndarray
86
- Right borders of the region around the peak
87
-
88
- lips : np.ndarray
89
- Left borders of the region around the peak
90
-
91
- Returns
92
- -------
93
- List
94
- List of ranges to be removed
95
- """
96
- all_ranges = [np.arange(zmin, zmax) for zmin, zmax in zip(rips, lips)]
97
- ranges_to_remove = []
98
- for i in range(len(all_ranges)):
99
- target_range = all_ranges[i]
100
- for j in range(i + 1, len(all_ranges)):
101
- if (
102
- np.intersect1d(target_range, all_ranges[j]).size > 1
103
- ): # Allow for a single overlap just to be nice
104
- if target_range.size > all_ranges[j].size:
105
- ranges_to_remove.append(j)
106
- logger.info(
107
- f"Zone ({all_ranges[j][0]}, {all_ranges[j][-1]}) inside zone ({target_range[0]}, {target_range[-1]})"
108
- )
109
- else:
110
- ranges_to_remove.append(i)
111
- logger.info(
112
- f"Zone ({target_range[0]}, {target_range[-1]}) inside zone ({all_ranges[j][0]}, {all_ranges[j][-1]})"
113
- )
114
-
115
- return ranges_to_remove
@@ -1,196 +0,0 @@
1
- Metadata-Version: 2.2
2
- Name: dkist-processing-visp
3
- Version: 2.20.14
4
- Summary: Science processing code for the ViSP instrument on DKIST
5
- Author-email: NSO / AURA <dkistdc@nso.edu>
6
- License: BSD-3-Clause
7
- Project-URL: Homepage, https://nso.edu/dkist/data-center/
8
- Project-URL: Repository, https://bitbucket.org/dkistdc/dkist-processing-visp
9
- Project-URL: Documentation, https://docs.dkist.nso.edu/projects/visp
10
- Project-URL: Help, https://nso.atlassian.net/servicedesk/customer/portal/5
11
- Classifier: Programming Language :: Python
12
- Classifier: Programming Language :: Python :: 3
13
- Classifier: Programming Language :: Python :: 3.11
14
- Requires-Python: >=3.11
15
- Description-Content-Type: text/x-rst
16
- Requires-Dist: dkist-processing-common==10.5.11
17
- Requires-Dist: dkist-processing-math==2.1.2
18
- Requires-Dist: dkist-processing-pac==3.1.1
19
- Requires-Dist: dkist-header-validator==5.1.1
20
- Requires-Dist: dkist-fits-specifications==4.10.0
21
- Requires-Dist: dkist-service-configuration==2.2
22
- Requires-Dist: dkist-spectral-lines==3.0.0
23
- Requires-Dist: astropy==6.1.5
24
- Requires-Dist: numpy==1.26.4
25
- Requires-Dist: sunpy==5.1.3
26
- Requires-Dist: scipy==1.15.1
27
- Requires-Dist: scikit-image==0.23.2
28
- Requires-Dist: scikit-learn==1.5.0
29
- Requires-Dist: peakutils==1.3.5
30
- Requires-Dist: Pillow==10.3.0
31
- Requires-Dist: moviepy==2.0.0
32
- Provides-Extra: test
33
- Requires-Dist: pytest; extra == "test"
34
- Requires-Dist: pytest-cov; extra == "test"
35
- Requires-Dist: pytest-xdist; extra == "test"
36
- Requires-Dist: pytest-mock; extra == "test"
37
- Requires-Dist: hypothesis; extra == "test"
38
- Requires-Dist: towncrier; extra == "test"
39
- Requires-Dist: dkist-data-simulator>=5.2.0; extra == "test"
40
- Requires-Dist: pydantic; extra == "test"
41
- Requires-Dist: dkist-processing-visp[inventory]; extra == "test"
42
- Requires-Dist: dkist-processing-visp[asdf]; extra == "test"
43
- Requires-Dist: dkist-processing-visp[quality]; extra == "test"
44
- Provides-Extra: inventory
45
- Requires-Dist: dkist-processing-common[inventory]; extra == "inventory"
46
- Requires-Dist: dkist-inventory==1.6.0; extra == "inventory"
47
- Provides-Extra: asdf
48
- Requires-Dist: dkist-processing-common[asdf]; extra == "asdf"
49
- Requires-Dist: dkist-inventory[asdf]==1.6.0; extra == "asdf"
50
- Provides-Extra: quality
51
- Requires-Dist: dkist-quality==1.2.0; extra == "quality"
52
- Provides-Extra: grogu
53
- Requires-Dist: dkist; extra == "grogu"
54
- Requires-Dist: pyparsing; extra == "grogu"
55
- Requires-Dist: dkist-inventory>=1.6.0; extra == "grogu"
56
- Requires-Dist: dkist-processing-visp[test]; extra == "grogu"
57
- Provides-Extra: docs
58
- Requires-Dist: sphinx; extra == "docs"
59
- Requires-Dist: sphinx-astropy; extra == "docs"
60
- Requires-Dist: sphinx-changelog; extra == "docs"
61
- Requires-Dist: sphinx-autoapi==3.3.3; extra == "docs"
62
- Requires-Dist: pytest; extra == "docs"
63
- Requires-Dist: towncrier; extra == "docs"
64
- Requires-Dist: dkist-sphinx-theme; extra == "docs"
65
- Requires-Dist: packaging; extra == "docs"
66
-
67
- dkist-processing-visp
68
- =====================
69
-
70
- Overview
71
- --------
72
- The dkist-processing-visp library contains the implementation of the visp pipelines as a collection of the
73
- `dkist-processing-core <https://pypi.org/project/dkist-processing-core/>`_ framework and
74
- `dkist-processing-common <https://pypi.org/project/dkist-processing-common/>`_ Tasks.
75
-
76
- The recommended project structure is to separate tasks and workflows into separate packages. Having the workflows
77
- in their own package facilitates using the build_utils to test the integrity of those workflows in the unit test.
78
-
79
- Calibration Pipeline
80
- ------------------------
81
-
82
- Build
83
- --------
84
- Artifacts are built through Bitbucket Pipelines.
85
-
86
- The pipeline can be used in other repos with a modification of the package and artifact locations
87
- to use the names relevant to the target repo.
88
-
89
- e.g. dkist-processing-test -> dkist-processing-vbi and dkist_processing_test -> dkist_processing_vbi
90
-
91
- Deployment
92
- ----------
93
- Deployment is done with `turtlebot <https://bitbucket.org/dkistdc/turtlebot/src/main/>`_ and follows
94
- the process detailed in `dkist-processing-core <https://pypi.org/project/dkist-processing-core/>`_
95
-
96
- Environment Variables
97
- ---------------------
98
- Only those specified by `dkist-processing-core <https://pypi.org/project/dkist-processing-core/>`_ and `dkist-processing-common <https://pypi.org/project/dkist-processing-common/>`_.
99
-
100
- Development
101
- -----------
102
- .. code-block:: bash
103
-
104
- git clone git@bitbucket.org:dkistdc/dkist-processing-visp.git
105
- cd dkist-processing-visp
106
- pre-commit install
107
- pip install -e .[test]
108
- pytest -v --cov dkist_processing_visp
109
-
110
- Changelog
111
- #########
112
-
113
- When you make **any** change to this repository it **MUST** be accompanied by a changelog file.
114
- The changelog for this repository uses the `towncrier <https://github.com/twisted/towncrier>`__ package.
115
- Entries in the changelog for the next release are added as individual files (one per change) to the ``changelog/`` directory.
116
-
117
- Writing a Changelog Entry
118
- ^^^^^^^^^^^^^^^^^^^^^^^^^
119
-
120
- A changelog entry accompanying a change should be added to the ``changelog/`` directory.
121
- The name of a file in this directory follows a specific template::
122
-
123
- <PULL REQUEST NUMBER>.<TYPE>[.<COUNTER>].rst
124
-
125
- The fields have the following meanings:
126
-
127
- * ``<PULL REQUEST NUMBER>``: This is the number of the pull request, so people can jump from the changelog entry to the diff on BitBucket.
128
- * ``<TYPE>``: This is the type of the change and must be one of the values described below.
129
- * ``<COUNTER>``: This is an optional field, if you make more than one change of the same type you can append a counter to the subsequent changes, i.e. ``100.bugfix.rst`` and ``100.bugfix.1.rst`` for two bugfix changes in the same PR.
130
-
131
- The list of possible types is defined in the towncrier section of ``pyproject.toml``, the types are:
132
-
133
- * ``feature``: This change is a new code feature.
134
- * ``bugfix``: This is a change which fixes a bug.
135
- * ``doc``: A documentation change.
136
- * ``removal``: A deprecation or removal of public API.
137
- * ``misc``: Any small change which doesn't fit anywhere else, such as a change to the package infrastructure.
138
-
139
-
140
- Rendering the Changelog at Release Time
141
- ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
142
-
143
- When you are about to tag a release first you must run ``towncrier`` to render the changelog.
144
- The steps for this are as follows:
145
-
146
- * Run `towncrier build --version vx.y.z` using the version number you want to tag.
147
- * Agree to have towncrier remove the fragments.
148
- * Add and commit your changes.
149
- * Tag the release.
150
-
151
- **NOTE:** If you forget to add a Changelog entry to a tagged release (either manually or automatically with ``towncrier``)
152
- then the Bitbucket pipeline will fail. To be able to use the same tag you must delete it locally and on the remote branch:
153
-
154
- .. code-block:: bash
155
-
156
- # First, actually update the CHANGELOG and commit the update
157
- git commit
158
-
159
- # Delete tags
160
- git tag -d vWHATEVER.THE.VERSION
161
- git push --delete origin vWHATEVER.THE.VERSION
162
-
163
- # Re-tag with the same version
164
- git tag vWHATEVER.THE.VERSION
165
- git push --tags origin main
166
-
167
- Science Changelog
168
- ^^^^^^^^^^^^^^^^^
169
-
170
- Whenever a release involves changes to the scientific quality of L1 data, additional changelog fragment(s) should be
171
- created. These fragments are intended to be as verbose as is needed to accurately capture the scope of the change(s),
172
- so feel free to use all the fancy RST you want. Science fragments are placed in the same ``changelog/`` directory
173
- as other fragments, but are always called::
174
-
175
- <PR NUMBER | +>.science[.<COUNTER>].rst
176
-
177
- In the case that a single pull request encapsulates the entirety of the scientific change then the first field should
178
- be that PR number (same as the normal CHANGELOG). If, however, there is not a simple mapping from a single PR to a scientific
179
- change then use the character "+" instead; this will create a changelog entry with no associated PR. For example:
180
-
181
- .. code-block:: bash
182
-
183
- $ ls changelog/
184
- 99.bugfix.rst # This is a normal changelog fragment associated with a bugfix in PR 99
185
- 99.science.rst # Apparently that bugfix also changed the scientific results, so that PR also gets a science fragment
186
- +.science.rst # This fragment is not associated with a PR
187
-
188
-
189
- When it comes time to build the SCIENCE_CHANGELOG, use the ``science_towncrier.sh`` script in this repo to do so.
190
- This script accepts all the same arguments as the default `towncrier`. For example:
191
-
192
- .. code-block:: bash
193
-
194
- ./science_towncrier.sh build --version vx.y.z
195
-
196
- This will update the SCIENCE_CHANGELOG and remove any science fragments from the changelog directory.
@@ -1,89 +0,0 @@
1
- changelog/.gitempty,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
2
- dkist_processing_visp/__init__.py,sha256=fAB6NDfsUfegrxJPQ_yKMR9dDDqfkyRoOGdHMqKcqOI,350
3
- dkist_processing_visp/config.py,sha256=wYyvQ3vPMg5ltU7KlcikK2_NAR9twve4W-Jm8YxNv6A,477
4
- dkist_processing_visp/fonts/Lato-Regular.ttf,sha256=1jbkaDIx-THtoiLViOlE0IK_0726AvkovuRhwPGFslE,656568
5
- dkist_processing_visp/models/__init__.py,sha256=z2nFVvvIzirxklQ9i5-F1nR-WOgcDttYtog_jx4yN5I,12
6
- dkist_processing_visp/models/constants.py,sha256=SYH9qwbQOvkZJyM1fsN8JzUkECGZ1_FFdD-iLRYOwWw,5127
7
- dkist_processing_visp/models/parameters.py,sha256=fh-rq4n_kgLDqCaHk1MuU5iZu65_OCDlkD038jKrdK8,10023
8
- dkist_processing_visp/models/tags.py,sha256=lt2iNujwr_Xmp6jeLldjV6N3zoK1rEDdx-TgqVmWg9I,2336
9
- dkist_processing_visp/models/task_name.py,sha256=0xsFYkWI1_M8emcXV6peqK8oQ0ggC8VA1mQjmNZy84A,186
10
- dkist_processing_visp/parsers/__init__.py,sha256=z2nFVvvIzirxklQ9i5-F1nR-WOgcDttYtog_jx4yN5I,12
11
- dkist_processing_visp/parsers/map_repeats.py,sha256=KAGQeFOe4a4Zimq601gEhvSTlRMcngWlSgwN0vj_TlQ,5467
12
- dkist_processing_visp/parsers/modulator_states.py,sha256=R0Cy3KikURfdndU6opqY7dfHt3WV3a6XMNQqcWMttSA,3005
13
- dkist_processing_visp/parsers/polarimeter_mode.py,sha256=R9m-ZcfX7iQ_Qj18hv954J-GyB0nmimGa784FAj-t78,540
14
- dkist_processing_visp/parsers/raster_step.py,sha256=-LP8cc-am-gQ1y_ZFJXVN4SbsOyjYreVEpo2ROVSC0Y,3045
15
- dkist_processing_visp/parsers/time.py,sha256=OCstnx_lLmoWXOq10QrLqRIZ-cxb8q5XHG8ejb_TclE,4350
16
- dkist_processing_visp/parsers/visp_l0_fits_access.py,sha256=3c1hvjiJfY7DFz1Gg4c8v6QYnh-22aSgVIvNFtEkA9I,1335
17
- dkist_processing_visp/parsers/visp_l1_fits_access.py,sha256=hOKAYyg60UWlzBJT6-xu83rmTATiuxqVru7zp74Cg88,859
18
- dkist_processing_visp/tasks/__init__.py,sha256=I3KqYsTPncD7SQsLZR5NGIcRNa0ByIMmZCaRagxTt1Y,712
19
- dkist_processing_visp/tasks/assemble_movie.py,sha256=R9-xxqJunNXDHoT-Ue5F0g5a1DBoX9SVmavqc6vAtkY,3329
20
- dkist_processing_visp/tasks/background_light.py,sha256=BHNMGmYmtvTFMZ4d1dEPrPhIWm91w-e60q86IOq0amQ,16205
21
- dkist_processing_visp/tasks/dark.py,sha256=79ztYVa61mmn-sPfSbMeYyK4wdmiOHXNs_WuQlWQ3E4,4344
22
- dkist_processing_visp/tasks/geometric.py,sha256=IXF2TDl4UrlyYYK5KOYOjwAJIDl95c7QWfkPp58EicY,44689
23
- dkist_processing_visp/tasks/instrument_polarization.py,sha256=hpuWdW4D6SJc1keIcZoDxRYO6NojX16TQj2qrFCGWlE,21703
24
- dkist_processing_visp/tasks/l1_output_data.py,sha256=HQT-q3uG9IT_6b0sN4AKn7xBcEuXMay4N9O-uLZ9ZGU,458
25
- dkist_processing_visp/tasks/lamp.py,sha256=2pGWVhi9hMClHltPaqcqGc3PSfCOEdt2c6kyjJ-Qg1c,6070
26
- dkist_processing_visp/tasks/make_movie_frames.py,sha256=asDWEsSJ8o_D_S527rmpcHkrzH7UIwB3o8hllglfJWw,7426
27
- dkist_processing_visp/tasks/parse.py,sha256=CuXKOcSSRbMrXTS8kmAa9zP5rVjLJtWewHRN6OZNu9A,6383
28
- dkist_processing_visp/tasks/quality_metrics.py,sha256=4rKvwfochMXR9t8Qmidgmd9T4e910ELlZn8yglLyKig,8133
29
- dkist_processing_visp/tasks/science.py,sha256=J2sCBfgabOnllWYXtJTXcCjLpp1aJ_--M-HBfBTsIO4,30844
30
- dkist_processing_visp/tasks/solar.py,sha256=JbepDTMz2mrEogIsvtzfBvEzF97GFhFhxl5uMTTN2Lg,27689
31
- dkist_processing_visp/tasks/visp_base.py,sha256=IXfy4YK9mPhGU_4ulc1mdSNimfi0-XQnqpSvv6Yabz0,1477
32
- dkist_processing_visp/tasks/write_l1.py,sha256=XYfucJUGQdsjdvV_pzVskm9euDweL779CwgJMcenme4,7272
33
- dkist_processing_visp/tasks/mixin/__init__.py,sha256=z2nFVvvIzirxklQ9i5-F1nR-WOgcDttYtog_jx4yN5I,12
34
- dkist_processing_visp/tasks/mixin/beam_access.py,sha256=JipTbMKR0VVKCxddUfxQIkYtsGHTCFvkMPkAqCazGG4,869
35
- dkist_processing_visp/tasks/mixin/corrections.py,sha256=2cZL7b0mcfSa5TbYJVH-auNF4P2marNymlM1RUZnO_k,5665
36
- dkist_processing_visp/tasks/mixin/downsample.py,sha256=tO0yyE6gC9WV_lvfwoeKCok-5dgxOg56PozjzSEQUwY,1343
37
- dkist_processing_visp/tasks/mixin/line_zones.py,sha256=3hT0PRgeVP_Sn2kUMwf0r1SHerTCZGNj88XEWO7HrBE,4064
38
- dkist_processing_visp/tests/README.rst,sha256=rnedwwg25c0lB9Me7cT7QNZA17FYlqCu9ZnjQxR5hi0,12502
39
- dkist_processing_visp/tests/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
40
- dkist_processing_visp/tests/conftest.py,sha256=ruB70JiJjw5VWKQJSBX5e0VMGqMfUAJDLmD2ouYuHrU,15425
41
- dkist_processing_visp/tests/header_models.py,sha256=UF5GyhZphARhvsoz7BfT_9UweIDMMMgxKdRlUfJ213s,16253
42
- dkist_processing_visp/tests/test_assemble_movie.py,sha256=ea6cZYIbntVBjOQJIUt4zg1N4OOHpVvz_AAYD6Xs0OE,2293
43
- dkist_processing_visp/tests/test_assemble_quality.py,sha256=Hm0nAW90Kbb-6OLkUsW6Hpv_YAZwKOiG114Ui2PqRUw,1229
44
- dkist_processing_visp/tests/test_background_light.py,sha256=VR5sBFdRONch83AlAI-ZMze9pWK6HnukKYu7lBUjOs4,17438
45
- dkist_processing_visp/tests/test_dark.py,sha256=FmOHtvMq77m1yd_3jPFmvLVco5zkV99uPokuDW-tdDg,5592
46
- dkist_processing_visp/tests/test_downsample.py,sha256=AWz4tFpsnLgQIsyWMk7TjAx5pU4f2SWoMCWWmFwr31o,2193
47
- dkist_processing_visp/tests/test_geometric.py,sha256=mwKfDAT4m_G5eoIS8g-UTrn8L5eRYBwyq5IHtPLdX7U,12576
48
- dkist_processing_visp/tests/test_instrument_polarization.py,sha256=beXt1zR38J2FKUH82hWjkRbwIISp7EsF2uOhbOwSSIw,10079
49
- dkist_processing_visp/tests/test_lamp.py,sha256=kmlFhjp_gMa2ypANhy0IYRdnfFi0R_17pePpat6zXG0,5252
50
- dkist_processing_visp/tests/test_make_movie_frames.py,sha256=eOupoM-rp1BnCaUr_L0BOO7wXxQc1hM_0q-tjEIUy8c,2595
51
- dkist_processing_visp/tests/test_map_repeats.py,sha256=i_niVHsKAFrqk_weisKcU7JAkcfI3muOWFDHQiPyB9A,7511
52
- dkist_processing_visp/tests/test_parameters.py,sha256=uoEjSyGo76dnnZNYVLi5bLDNUBkJuUJ_KvVYSsJ1TTM,4385
53
- dkist_processing_visp/tests/test_parse.py,sha256=0EZYkSn0yTCb7r751RnbYhQsm2L8UoiBa1o1ZVWcjiU,18300
54
- dkist_processing_visp/tests/test_quality.py,sha256=g0T2DRqMUhJZl9p7mGomyWbE0vAyW1H-p_Kxnu7q_Uo,6922
55
- dkist_processing_visp/tests/test_science.py,sha256=QRCaumnuvenCfXBLd0u3oW_liDkHByn0q4QRzSjVIig,20211
56
- dkist_processing_visp/tests/test_solar.py,sha256=6U4tQeA0IMNrTvpwRK4Bg_ihx4n5tW5Ka1uFPa4wkiQ,9510
57
- dkist_processing_visp/tests/test_trial_create_quality_report.py,sha256=t3de9LMJOqrRaFXAvKV_5sotAfzDR8fZVIrFNRB2I_A,2779
58
- dkist_processing_visp/tests/test_visp_constants.py,sha256=5BdmYjC4mETWXDH69sfhdExOqpBMr-ZJE97eqQkjqhs,1878
59
- dkist_processing_visp/tests/test_workflows.py,sha256=AiPmG3rhTvhBwCvzn-xWgatQSt5M6-zSdJC6owWofrc,286
60
- dkist_processing_visp/tests/test_write_l1.py,sha256=1RIdi2yBKZKBw0QfCgiOVjy6mm9mGCkzH40hH0uaSBU,5958
61
- dkist_processing_visp/tests/local_trial_workflows/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
62
- dkist_processing_visp/tests/local_trial_workflows/l0_cals_only.py,sha256=KDK8S1oyX2nSkJV5RrFnrVg9DPFK9Ty0E9TTFu72STY,12908
63
- dkist_processing_visp/tests/local_trial_workflows/l0_to_l1.py,sha256=PiAmhJJefOWa-T_X-BqGf2-e-9vdY3QEi8fOpbVMI_0,17435
64
- dkist_processing_visp/tests/local_trial_workflows/local_trial_helpers.py,sha256=u7ahCUmC3e7mncJVnAlM8iZLnf2NoBA-kHHwbRZ-cBQ,15384
65
- dkist_processing_visp/workflows/__init__.py,sha256=-m_gkn5_hCSwvwaDjlbmE75G-tUnBo4y2wkDSnHDsWk,102
66
- dkist_processing_visp/workflows/l0_processing.py,sha256=QRYCXfzmlUhCkDT7eW0sncGPwH3MNEQ8McmoR0rXdNk,3237
67
- dkist_processing_visp/workflows/single_task_workflows.py,sha256=LK4dsshM0-lwy79WaMoTplyCxUyINnP9RU74MG_dhyc,33
68
- dkist_processing_visp/workflows/trial_workflows.py,sha256=rEBYOc7UnNhUtQXo0AFkO-PKHamLUEz5zWzaApBwxAs,3730
69
- docs/Makefile,sha256=qnlVz6PuBqE39NfHWuUnHhNEA-EFgT2-WJNNNy9ttfk,4598
70
- docs/background_light.rst,sha256=FWj8KH7H51BtoqPCJ1A_VIWJkjaXD8-dwM9RdY1rkIc,5147
71
- docs/changelog.rst,sha256=ZpZPJIyl4nI0Eicku6uSrLdiinNOF2GcZwrvTEsb-Zs,346
72
- docs/conf.py,sha256=b1GjKdimrcugueR5gZmZO6zyphPOSV6CedDRIhO6ILY,2028
73
- docs/gain_correction.rst,sha256=lMdwa5YrBuARFl3PQuqkhzO0VUMGVWV7ZMF3UNZ7f9Y,6470
74
- docs/geometric.rst,sha256=VsAWefgJ1j64Uo1TQ-ltAQ6INgsdS7-_FSvOtm0i17s,7301
75
- docs/index.rst,sha256=pl8VhwISd-kb1IQi2h7gOySfOhQQl2C71pjTatShGNI,319
76
- docs/l0_to_l1_visp.rst,sha256=wE1TT7DD93r3kByaFAaT2HO907pjV4YrJ_fzvJFTchw,623
77
- docs/l0_to_l1_visp_full-trial.rst,sha256=Y6YLkRA5b0tgui5l_WdthCx2wrXjLD8U97XKZHXVVBk,558
78
- docs/landing_page.rst,sha256=tdxWtmGjO7OUPYvRjgBAI461nubEE61HrtBwPdBeawI,1052
79
- docs/make.bat,sha256=mBAhtURwhQ7yc95pqwJzlhqBSvRknr1aqZ5s8NKvdKs,4513
80
- docs/polarization_calibration.rst,sha256=fYdB_FYB7NjvknuQIa3EGc4ZWjeUaBkkeRb8Y1bGihk,5068
81
- docs/requirements.txt,sha256=Kbl_X4c7RQZw035YTeNB63We6I7pvXFU4T0Uflp2yDY,29
82
- docs/requirements_table.rst,sha256=_HIbwFpDooM5n0JjiDAbFozGfJuX13smtcoujLFN4Gk,292
83
- docs/science_calibration.rst,sha256=akj3QrrTx0Rj08b_a1jlysVfL_fAFh28sRjRrA_HeRQ,2513
84
- docs/scientific_changelog.rst,sha256=01AWBSHg8zElnodCgAq-hMxhk9CkX5rtEENx4iz0sjI,300
85
- licenses/LICENSE.rst,sha256=piZaQplkzOMmH1NXg6QIdo9wwo9pPCoHkvm2-DmH76E,1462
86
- dkist_processing_visp-2.20.14.dist-info/METADATA,sha256=f7ko4I467eIPzuslow78IF39Vhq6zlenqoS2VF2D0Qw,8445
87
- dkist_processing_visp-2.20.14.dist-info/WHEEL,sha256=In9FTNxeP60KnTkGw7wk6mJPYd_dQSjEZmXdBdMCI-8,91
88
- dkist_processing_visp-2.20.14.dist-info/top_level.txt,sha256=9GHSn-ZMGQxaRNGrPP3HNc5ZkE7ftzluO74Jz5vUSTE,46
89
- dkist_processing_visp-2.20.14.dist-info/RECORD,,