Skip to content

Commit

Permalink
Rename lg_model.NrmModel to lg_model.LgModel to avoid confusion with …
Browse files Browse the repository at this point in the history
…stdatamodels NRMModel
  • Loading branch information
rcooper295 committed Nov 20, 2024
1 parent b44da8d commit 79b8edc
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion jwst/ami/find_affine2d_parameters.py
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ def find_rotation(imagedata, psf_offset, rotdegs, mx, my, sx, sy, xo, yo,
crosscorr_rots = []

for (rot, aff) in zip(rotdegs, affine2d_list):
jw = lg_model.NrmModel(mask='jwst_g7s6c', holeshape=holeshape, over=over, affine2d=aff)
jw = lg_model.LgModel(mask='jwst_ami', holeshape=holeshape, over=over, affine2d=aff)

jw.set_pixelscale(pixel)
# psf_offset in data coords & pixels. Does it get rotated? Second order errors poss.
Expand Down
10 changes: 5 additions & 5 deletions jwst/ami/lg_model.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
mas = 1.0e-3 / (60 * 60 * 180 / np.pi) # in radians


class NrmModel:
class LgModel:
"""
A class for conveniently dealing with an "NRM object" This should be able
to take an NRM_definition object for mask geometry.
Expand Down Expand Up @@ -47,7 +47,7 @@ def __init__(
**kwargs,
):
"""
Set attributes of NrmModel class.
Set attributes of LgModel class.
Parameters
----------
Expand Down Expand Up @@ -93,7 +93,7 @@ def __init__(

# get these from mask_definition_ami instead
if mask is None:
log.info("Using JWST AMI mask geometry from NrmModel")
log.info("Using JWST AMI mask geometry from LgModel")
mask = mask_definition_ami.NRM_definition(
maskname="jwst_ami", chooseholes=chooseholes
)
Expand Down Expand Up @@ -122,7 +122,7 @@ def __init__(

self.chooseholes = chooseholes

# affine2d property not to be changed in NrmModel - create a new
# affine2d property not to be changed in LgModel - create a new
# instance instead
# Save affine deformation of pupil object or create a no-deformation
# object.
Expand Down Expand Up @@ -400,7 +400,7 @@ def fit_image(
def create_modelpsf(self):
"""
Make an image from the object's model and fit solutions, by setting the
NrmModel object's modelpsf attribute
LgModel object's modelpsf attribute
Parameters
----------
Expand Down
4 changes: 2 additions & 2 deletions jwst/ami/nrm_core.py
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ def fit_fringes_single_integration(self, slc):
Returns
-------
nrm: NrmModel object
nrm: LgModel object
Model with best fit results
Notes
Expand All @@ -190,7 +190,7 @@ def fit_fringes_single_integration(self, slc):
"""

nrm = lg_model.NrmModel(mask=self.instrument_data.mask,
nrm = lg_model.LgModel(mask=self.instrument_data.mask,
pixscale=self.instrument_data.pscale_rad,
holeshape=self.instrument_data.holeshape,
affine2d=self.instrument_data.affine2d,
Expand Down

0 comments on commit 79b8edc

Please sign in to comment.