Skip to content

Commit

Permalink
coeff shape bug, take 2
Browse files Browse the repository at this point in the history
  • Loading branch information
JarronL committed May 28, 2020
1 parent b7e8a38 commit 12f2972
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion pynrc/pynrc_core.py
Original file line number Diff line number Diff line change
Expand Up @@ -2050,9 +2050,10 @@ def gen_psf(self, sp=None, return_oversample=False, use_bg_psf=False,
cf_fit = self._psf_coeff_mod['wfe_drift']
lxmap = self._psf_coeff_mod['wfe_drift_lxmap']

cf_fit_shape = cf_fit.shape
cf_fit = cf_fit.reshape([cf_fit.shape[0], -1])
cf_mod = jl_poly(np.array([wfe_drift]), cf_fit, use_legendre=True, lxmap=lxmap)
cf_mod = cf_mod.reshape(cf_fit[1:])
cf_mod = cf_mod.reshape(cf_fit_shape[1:])
# Pad cf_mod array with 0s if undersized
if not np.allclose(psf_coeff.shape, cf_mod.shape):
new_shape = psf_coeff.shape[1:]
Expand Down

0 comments on commit 12f2972

Please sign in to comment.