Skip to content

Commit

Permalink
JP-3632: Change the Spec of Ramp Fitting to Select Algorithm (spacete…
Browse files Browse the repository at this point in the history
  • Loading branch information
kmacdonald-stsci authored May 23, 2024
1 parent aaf38ad commit 3705c37
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 2 deletions.
5 changes: 5 additions & 0 deletions CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,11 @@ ramp_fitting
to use uint16 instead of uint8, in order to avoid potential
overflow/wraparound problems. [#8377]

- Changed the spec for ramp fitting that allows for selecting
the algorithm "OLS" to use the python implementation of ramp
fitting or "OLS_C" to use the C extension implementation of
ramp fitting. [#8503]

resample
--------

Expand Down
5 changes: 5 additions & 0 deletions docs/jwst/ramp_fitting/arguments.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@ Arguments
=========
The ramp fitting step has the following optional arguments that can be set by the user:

* ``--algorithm``: A string to select the desired algorithm. The available
values are "OLS" to select the python implementation of the Ordinary
Least Squares algorithm and "OLS_C" to select the C extension
implementation of OLS. The algorithm defaults to "OLS".

* ``--save_opt``: A True/False value that specifies whether to write
the optional output product. Default is False.

Expand Down
5 changes: 3 additions & 2 deletions jwst/ramp_fitting/ramp_fit_step.py
Original file line number Diff line number Diff line change
Expand Up @@ -385,6 +385,7 @@ class RampFitStep(Step):
class_alias = "ramp_fit"

spec = """
algorithm = option('OLS', 'OLS_C', default='OLS') # Can be 'OLS_C' to select the C extension
int_name = string(default='')
save_opt = boolean(default=False) # Save optional output
opt_name = string(default='')
Expand All @@ -399,8 +400,8 @@ class RampFitStep(Step):
# As of 04/26/17, the only allowed algorithm is 'ols', and the
# only allowed weighting is 'optimal'.

algorithm = 'ols' # Only algorithm allowed for Build 7.1
# algorithm = 'gls' # 032520
# algorithm = 'ols' # Only algorithm allowed for Build 7.1
# algorithm = 'gls' # 032520

weighting = 'optimal' # Only weighting allowed for Build 7.1

Expand Down

0 comments on commit 3705c37

Please sign in to comment.