Commit 4b47f9f1 authored by Emmanuel Bertin's avatar Emmanuel Bertin
Browse files

Fixed Inf in some instances of SPREADERR_MODEL.

parent def38ae6
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
* You should have received a copy of the GNU General Public License * You should have received a copy of the GNU General Public License
* along with SExtractor. If not, see <http://www.gnu.org/licenses/>. * along with SExtractor. If not, see <http://www.gnu.org/licenses/>.
* *
* Last modified: 01/06/2012 * Last modified: 06/06/2012
* *
*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/ *%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
...@@ -166,7 +166,7 @@ OUTPUT Pointer to an allocated fit structure (containing details about the ...@@ -166,7 +166,7 @@ OUTPUT Pointer to an allocated fit structure (containing details about the
fit). fit).
NOTES It is a modified version of the lm_minimize() of lmfit. NOTES It is a modified version of the lm_minimize() of lmfit.
AUTHOR E. Bertin (IAP) AUTHOR E. Bertin (IAP)
VERSION 01/06/2012 VERSION 06/06/2012
***/ ***/
void profit_fit(profitstruct *profit, void profit_fit(profitstruct *profit,
picstruct *field, picstruct *wfield, picstruct *field, picstruct *wfield,
...@@ -177,13 +177,13 @@ void profit_fit(profitstruct *profit, ...@@ -177,13 +177,13 @@ void profit_fit(profitstruct *profit,
psfstruct *psf; psfstruct *psf;
checkstruct *check; checkstruct *check;
double emx2,emy2,emxy, a , cp,sp, cn, bn, n, double emx2,emy2,emxy, a , cp,sp, cn, bn, n,
sump,sumq, sumpw2,sumqw2,sumpqw, sump0,sumq0; sump,sumq, sumpw2,sumqw2,sumpqw, sump0,sumq0, err;
PIXTYPE valp,valq,sig2; PIXTYPE valp,valq,sig2;
float param0[PARAM_NPARAM], param1[PARAM_NPARAM], float param0[PARAM_NPARAM], param1[PARAM_NPARAM],
param[PARAM_NPARAM], param[PARAM_NPARAM],
**list, **list,
*cov, *cov,
psf_fwhm, dchi2, err, aspect, chi2; psf_fwhm, dchi2, aspect, chi2;
int *index, int *index,
i,j,p, nparam, nparam2, ncomp, nprof; i,j,p, nparam, nparam2, ncomp, nprof;
......
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
* *
* This file part of: SExtractor * This file part of: SExtractor
* *
* Copyright: (C) 1993-2011 Emmanuel Bertin -- IAP/CNRS/UPMC * Copyright: (C) 1993-2012 Emmanuel Bertin -- IAP/CNRS/UPMC
* *
* License: GNU General Public License * License: GNU General Public License
* *
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
* You should have received a copy of the GNU General Public License * You should have received a copy of the GNU General Public License
* along with SExtractor. If not, see <http://www.gnu.org/licenses/>. * along with SExtractor. If not, see <http://www.gnu.org/licenses/>.
* *
* Last modified: 25/03/2010 * Last modified: 04/06/2012
* *
*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/ *%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
...@@ -273,7 +273,7 @@ void readimagehead(picstruct *field) ...@@ -273,7 +273,7 @@ void readimagehead(picstruct *field)
field->npix = (KINGSIZE_T)field->width*field->height; field->npix = (KINGSIZE_T)field->width*field->height;
field->bitpix = tab->bitpix; field->bitpix = tab->bitpix;
field->bytepix = tab->bytepix; field->bytepix = tab->bytepix;
if (tab->bitsgn && prefs.fitsunsigned_flag) if (tab->bitsgn && (prefs.fitsunsigned_flag || tab->bitpix==BP_BYTE))
tab->bitsgn = 0; tab->bitsgn = 0;
FITSREADS(tab->headbuf, "OBJECT ", field->ident, "Unnamed"); FITSREADS(tab->headbuf, "OBJECT ", field->ident, "Unnamed");
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment