pz-rail-astro-tools 1.0.2__py3-none-any.whl → 1.0.3__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.

Potentially problematic release.


This version of pz-rail-astro-tools might be problematic. Click here for more details.

@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: pz-rail-astro-tools
3
- Version: 1.0.2
3
+ Version: 1.0.3
4
4
  Author-email: "LSST Dark Energy Science Collaboration (DESC)" <lsst-desc-rail-admin@slac.stanford.edu>
5
5
  License: MIT License
6
6
 
@@ -34,7 +34,9 @@ Requires-Python: >=3.9
34
34
  Description-Content-Type: text/markdown
35
35
  License-File: LICENSE
36
36
  Requires-Dist: deprecated
37
- Requires-Dist: pz-rail-base
37
+ Requires-Dist: pz-rail-base >=1.0.3
38
+ Requires-Dist: numpy
39
+ Requires-Dist: pandas >=2.2.2
38
40
  Requires-Dist: astropy
39
41
  Requires-Dist: healpy
40
42
  Requires-Dist: photerr
@@ -0,0 +1,22 @@
1
+ rail/astro_tools/__init__.py,sha256=c0yzN5jMhByii01h_mjOWipeProO8vludBsO09dJkmc,377
2
+ rail/astro_tools/_version.py,sha256=vs6W4yrsz3i8OMGT2jlW8NQDmpo9yxVa6jtyzIhHvWw,411
3
+ rail/creation/degraders/grid_selection.py,sha256=gJKM0AYdG-HgvjTS3ovupbyoB5bxKhZn9FAAb94pQXY,12429
4
+ rail/creation/degraders/lsst_error_model.py,sha256=YSjSqVJBloxCaWZRjP7nzkUXIARQ3mX5ZRmmQjnkJ_g,1960
5
+ rail/creation/degraders/observing_condition_degrader.py,sha256=y6Nal_kSdAz6N8amY4oV6mQ3upa2nIgVbV9P6F0PKwA,19977
6
+ rail/creation/degraders/photometric_errors.py,sha256=oCbWJuy-C_1drrWgW3_HOfn90-ynIEs66EDBsGX26ZA,3659
7
+ rail/creation/degraders/spectroscopic_degraders.py,sha256=2OhT6ZfD2KVqsQauFKkJZezuuyQtZEcysNVw0acGLns,5019
8
+ rail/creation/degraders/spectroscopic_selections.py,sha256=FY17k2qvpCmHMClS-NoQ5mp4pSMGQfC0D9NMbFbIFCs,22170
9
+ rail/creation/engines/gcr_engine.py,sha256=LSp599uQGu8GcFNUmib792ScQwSB_Og8VxPLTt9aSNU,2981
10
+ rail/examples_data/creation_data/data/HSC_grid_settings.pkl,sha256=zpJoSR9TSnDyL64DPXivIMam3fn6GOZoyoJoeBj2LAk,141
11
+ rail/examples_data/creation_data/data/hsc_ratios_and_specz.hdf5,sha256=liH54wuuuHxToqjoAwQ_fFmEefk3haNweVThMwdDKN4,13823712
12
+ rail/examples_data/creation_data/data/survey_conditions/DC2-dr6-galcounts-i20-i25.3-nside-128.fits,sha256=jHv3dwoLQSKcGUx29cnN9t9AWef4JlGsqSbITJfZI0o,1581120
13
+ rail/examples_data/creation_data/data/survey_conditions/DC2-mask-neg-nside-128.fits,sha256=79Kg4xRP4WHlOCcS-3SKqf9aP_LZRAq-izIM0DFL6bw,1581120
14
+ rail/examples_data/creation_data/data/survey_conditions/minion_1016_dc2_Median_airmass_i_and_nightlt1825_HEAL.fits,sha256=twvyce70G3h1MQnGGFQJG9wZc8UbuNqXc6mjtiuaL1s,1581120
15
+ rail/examples_data/creation_data/data/survey_conditions/minion_1016_dc2_Median_fiveSigmaDepth_i_and_nightlt1825_HEAL.fits,sha256=RbMMFSVJQxGhZnL4BnISE9VTNljfTZwV6Bax6NxverY,1581120
16
+ rail/examples_data/testdata/rubin_dm_dc2_example2.pq,sha256=_Iihbbcz1A332QAkaMiFacT4QAbBQBMTOwpfrS7AclE,25884
17
+ rail/tools/photometry_tools.py,sha256=zwXxWtB-gn6mtmIUr_j5HrZy-xSkTEjgNZTvtt3uN90,19023
18
+ pz_rail_astro_tools-1.0.3.dist-info/LICENSE,sha256=tLMEN21HbzvT-7umOVVvPjaJZbQxCa-2bAeYLwG5Q04,1102
19
+ pz_rail_astro_tools-1.0.3.dist-info/METADATA,sha256=Sz98pDNjnJKkC4KWbqHj3Xfxn9DHRg2UmAmwLEPfJ5E,4006
20
+ pz_rail_astro_tools-1.0.3.dist-info/WHEEL,sha256=R0nc6qTxuoLk7ShA2_Y-UWkN8ZdfDBG2B6Eqpz2WXbs,91
21
+ pz_rail_astro_tools-1.0.3.dist-info/top_level.txt,sha256=6R6sqn-85I8YZTzmB9gv7sqckB2QaOTHbu-QLGTWBRE,5
22
+ pz_rail_astro_tools-1.0.3.dist-info/RECORD,,
@@ -1,5 +1,5 @@
1
1
  Wheel-Version: 1.0
2
- Generator: bdist_wheel (0.43.0)
2
+ Generator: setuptools (72.1.0)
3
3
  Root-Is-Purelib: true
4
4
  Tag: py3-none-any
5
5
 
@@ -12,5 +12,5 @@ __version__: str
12
12
  __version_tuple__: VERSION_TUPLE
13
13
  version_tuple: VERSION_TUPLE
14
14
 
15
- __version__ = version = '1.0.2'
16
- __version_tuple__ = version_tuple = (1, 0, 2)
15
+ __version__ = version = '1.0.3'
16
+ __version_tuple__ = version_tuple = (1, 0, 3)
@@ -57,9 +57,9 @@ class GridSelection(Selector):
57
57
  random_seed=Param(int, 12345, msg="random seed for reproducibility"),
58
58
  scaling_factor=Param(float, 1.588, msg="multiplicative factor for ratios to adjust number of galaxies kept"))
59
59
 
60
- def __init__(self, args, comm=None):
60
+ def __init__(self, args, **kwargs):
61
61
 
62
- Selector.__init__(self, args, comm=comm)
62
+ super().__init__(args, **kwargs)
63
63
 
64
64
  if self.config.redshift_cut < 0:
65
65
  raise ValueError("redshift cut must be positive")
@@ -38,13 +38,13 @@ class LSSTErrorModel(Degrader):
38
38
  required=False,
39
39
  )
40
40
 
41
- def __init__(self, args, comm=None):
41
+ def __init__(self, args, **kwargs):
42
42
  """
43
43
  Constructor
44
44
 
45
45
  Does standard Degrader initialization and sets up the error model.
46
46
  """
47
- Degrader.__init__(self, args, comm=comm)
47
+ super().__init__(args, **kwargs)
48
48
  self.error_model = PhotErrErrorModel(
49
49
  **{key: self.config[key] for key in self._photerr_params}
50
50
  )
@@ -116,8 +116,8 @@ class ObsCondition(Noisifier):
116
116
  }
117
117
 
118
118
 
119
- def __init__(self, args, comm=None):
120
- Noisifier.__init__(self, args, comm=comm)
119
+ def __init__(self, args, **kwargs):
120
+ super().__init__(args, **kwargs)
121
121
 
122
122
  # store a list of keys relevant for
123
123
  # survey conditions;
@@ -53,14 +53,6 @@ class PhotoErrorModel(Noisifier):
53
53
  required=False,
54
54
  )
55
55
 
56
- def __init__(self, args, comm=None):
57
- """
58
- Constructor
59
-
60
- Does standard Degrader initialization and sets up the error model.
61
- """
62
- Noisifier.__init__(self, args, comm=comm)
63
-
64
56
  def _initNoiseModel(self):
65
57
  """
66
58
  Initialize the noise model by the peNoiseModel
@@ -93,9 +85,9 @@ class LSSTErrorModel(PhotoErrorModel):
93
85
 
94
86
  name = "LSSTErrorModel"
95
87
 
96
- def __init__(self, args, comm=None):
88
+ def __init__(self, args, **kwargs):
97
89
 
98
- PhotoErrorModel.__init__(self, args, comm=comm)
90
+ super().__init__(args, **kwargs)
99
91
 
100
92
  self.set_params(peLsstErrorParams)
101
93
  self.peNoiseModel = peLsstErrorModel
@@ -111,9 +103,9 @@ class RomanErrorModel(PhotoErrorModel):
111
103
 
112
104
  name = "RomanErrorModel"
113
105
 
114
- def __init__(self, args, comm=None):
106
+ def __init__(self, args, **kwargs):
115
107
 
116
- PhotoErrorModel.__init__(self, args, comm=comm)
108
+ super().__init__(args, **kwargs)
117
109
 
118
110
  self.set_params(peRomanErrorParams)
119
111
  self.peNoiseModel = peRomanErrorModel
@@ -128,9 +120,9 @@ class EuclidErrorModel(PhotoErrorModel):
128
120
 
129
121
  name = "EuclidErrorModel"
130
122
 
131
- def __init__(self, args, comm=None):
123
+ def __init__(self, args, **kwargs):
132
124
 
133
- PhotoErrorModel.__init__(self, args, comm=comm)
125
+ super().__init__(args, **kwargs)
134
126
 
135
127
  self.set_params(peEuclidErrorParams)
136
128
  self.peNoiseModel = peEuclidErrorModel
@@ -44,10 +44,10 @@ class LineConfusion(Noisifier):
44
44
  wrong_wavelen=float,
45
45
  frac_wrong=float)
46
46
 
47
- def __init__(self, args, comm=None):
47
+ def __init__(self, args, **kwargs):
48
48
  """
49
49
  """
50
- Noisifier.__init__(self, args, comm=comm)
50
+ super().__init__(args, **kwargs)
51
51
  # validate parameters
52
52
  if self.config.true_wavelen < 0:
53
53
  raise ValueError("true_wavelen must be positive, not {self.config.true_wavelen}")
@@ -115,10 +115,10 @@ class InvRedshiftIncompleteness(Selector):
115
115
  config_options = Selector.config_options.copy()
116
116
  config_options.update(pivot_redshift=float)
117
117
 
118
- def __init__(self, args, comm=None):
118
+ def __init__(self, args, **kwargs):
119
119
  """
120
120
  """
121
- Selector.__init__(self, args, comm=comm)
121
+ super().__init__(args, **kwargs)
122
122
  if self.config.pivot_redshift < 0:
123
123
  raise ValueError("pivot redshift must be positive, not {self.config.pivot_redshift}")
124
124
 
@@ -67,8 +67,8 @@ class SpecSelection(Selector):
67
67
  random_seed=Param(int, 42, msg="random seed for reproducibility"),
68
68
  )
69
69
 
70
- def __init__(self, args, comm=None):
71
- Selector.__init__(self, args, comm=comm)
70
+ def __init__(self, args, **kwargs):
71
+ super().__init__(args, **kwargs)
72
72
  self._validate_settings()
73
73
  self.mask = None
74
74
  self.rng = None
@@ -155,7 +155,7 @@ class SpecSelection(Selector):
155
155
  # get the bands and bandNames present in the data
156
156
  data = self.get_data("input", allow_missing=True)
157
157
  self.validate_colnames(data)
158
- self.mask = np.product(~np.isnan(data.to_numpy()), axis=1)
158
+ self.mask = np.prod(~np.isnan(data.to_numpy()), axis=1)
159
159
  self.invalid_cut(data)
160
160
  self.selection(data)
161
161
  if self.config.downsample is True:
@@ -52,8 +52,8 @@ class GCRCreator(Creator):
52
52
  ),
53
53
  )
54
54
 
55
- def __init__(self, args, comm=None):
56
- Creator.__init__(self, args, comm=comm)
55
+ def __init__(self, args, **kwargs):
56
+ super().__init__(args, **kwargs)
57
57
 
58
58
  # Provides override for unit test
59
59
  self._catalog_override = None
@@ -95,8 +95,8 @@ class PhotometryManipulator(RailStage, ABC):
95
95
  inputs = [('input', PqHandle)]
96
96
  outputs = [('output', PqHandle)]
97
97
 
98
- def __init__(self, args, comm=None):
99
- super().__init__(args, comm)
98
+ def __init__(self, args, **kwargs):
99
+ super().__init__(args, **kwargs)
100
100
  self._check_config()
101
101
  # convenience remapping of parameters
102
102
  self.value_columns = self.config.value_columns
@@ -371,9 +371,6 @@ class LSSTFluxToMagConverter(RailStage):
371
371
  inputs = [('input', PqHandle)]
372
372
  outputs = [('output', Hdf5Handle)]
373
373
 
374
- def __init__(self, args, comm=None):
375
- RailStage.__init__(self, args, comm=comm)
376
-
377
374
  def _flux_to_mag(self, flux_vals):
378
375
  return -2.5*np.log10(flux_vals) + self.config.mag_offset
379
376
 
@@ -452,9 +449,6 @@ class DustMapBase(RailStage):
452
449
  fetch_func = dust_map_submod.fetch
453
450
  fetch_func()
454
451
 
455
-
456
- def __init__(self, args, comm=None):
457
- RailStage.__init__(self, args, comm=comm)
458
452
 
459
453
  def run(self):
460
454
  data = self.get_data('input', allow_missing=True)
@@ -1,22 +0,0 @@
1
- rail/astro_tools/__init__.py,sha256=c0yzN5jMhByii01h_mjOWipeProO8vludBsO09dJkmc,377
2
- rail/astro_tools/_version.py,sha256=BGgbj7AHZwtVw29XgDIjcG5woR-f3jQy2X-ArcRT22E,411
3
- rail/creation/degraders/grid_selection.py,sha256=QCs7ZpLJ_GdJnIIt0WF09mBLeqsrzQ2CiDo0h0Hd3dQ,12438
4
- rail/creation/degraders/lsst_error_model.py,sha256=WWQxPO3w1S6sALQxl7x7_mUI1f3o1eOGpBk3Yzi-1Q0,1969
5
- rail/creation/degraders/observing_condition_degrader.py,sha256=jelIfFHzrgmRmRARm5uC36ZohepfMHq5djWT5wGEaZI,19987
6
- rail/creation/degraders/photometric_errors.py,sha256=HbQaEKHEcSo4ab2J3qZAiVFxlJpLAQFwjGKUnSUmG8U,3927
7
- rail/creation/degraders/spectroscopic_degraders.py,sha256=zpCxK0jbKTKlU-eqe05pW-BM2O743_ocEQy2TQPP3EA,5038
8
- rail/creation/degraders/spectroscopic_selections.py,sha256=1nWeWFN3nE5mw1W6fxAcSjp3eWcWbRuY6TsYvDlT7Zc,22182
9
- rail/creation/engines/gcr_engine.py,sha256=MTzbV-FDRAoWfTpUzKCrdyOGK3hsSJ5atSLpwslBE5Y,2989
10
- rail/examples_data/creation_data/data/HSC_grid_settings.pkl,sha256=zpJoSR9TSnDyL64DPXivIMam3fn6GOZoyoJoeBj2LAk,141
11
- rail/examples_data/creation_data/data/hsc_ratios_and_specz.hdf5,sha256=liH54wuuuHxToqjoAwQ_fFmEefk3haNweVThMwdDKN4,13823712
12
- rail/examples_data/creation_data/data/survey_conditions/DC2-dr6-galcounts-i20-i25.3-nside-128.fits,sha256=jHv3dwoLQSKcGUx29cnN9t9AWef4JlGsqSbITJfZI0o,1581120
13
- rail/examples_data/creation_data/data/survey_conditions/DC2-mask-neg-nside-128.fits,sha256=79Kg4xRP4WHlOCcS-3SKqf9aP_LZRAq-izIM0DFL6bw,1581120
14
- rail/examples_data/creation_data/data/survey_conditions/minion_1016_dc2_Median_airmass_i_and_nightlt1825_HEAL.fits,sha256=twvyce70G3h1MQnGGFQJG9wZc8UbuNqXc6mjtiuaL1s,1581120
15
- rail/examples_data/creation_data/data/survey_conditions/minion_1016_dc2_Median_fiveSigmaDepth_i_and_nightlt1825_HEAL.fits,sha256=RbMMFSVJQxGhZnL4BnISE9VTNljfTZwV6Bax6NxverY,1581120
16
- rail/examples_data/testdata/rubin_dm_dc2_example2.pq,sha256=_Iihbbcz1A332QAkaMiFacT4QAbBQBMTOwpfrS7AclE,25884
17
- rail/tools/photometry_tools.py,sha256=GdqHWoYzkbQTQoEWvkz1qNZjJbJCFgQUR39d4xuz1cI,19216
18
- pz_rail_astro_tools-1.0.2.dist-info/LICENSE,sha256=tLMEN21HbzvT-7umOVVvPjaJZbQxCa-2bAeYLwG5Q04,1102
19
- pz_rail_astro_tools-1.0.2.dist-info/METADATA,sha256=YooFUgTa8FAlMqG7boZeO2dQ6yaa8Gaaf7GeeYZD4xA,3947
20
- pz_rail_astro_tools-1.0.2.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
21
- pz_rail_astro_tools-1.0.2.dist-info/top_level.txt,sha256=6R6sqn-85I8YZTzmB9gv7sqckB2QaOTHbu-QLGTWBRE,5
22
- pz_rail_astro_tools-1.0.2.dist-info/RECORD,,