Changeset 11702
- Timestamp:
- Feb 7, 2007, 5:52:32 PM (19 years ago)
- Location:
- trunk
- Files:
-
- 35 edited
-
ippTools/src/camtool.c (modified) (1 diff)
-
ippTools/src/camtoolConfig.c (modified) (1 diff)
-
ippTools/src/chiptool.c (modified) (1 diff)
-
ippTools/src/chiptoolConfig.c (modified) (1 diff)
-
ippTools/src/detselect.c (modified) (1 diff)
-
ippTools/src/detselectConfig.c (modified) (1 diff)
-
ippTools/src/dettool.c (modified) (9 diffs)
-
ippTools/src/dettoolConfig.c (modified) (1 diff)
-
ippTools/src/guidetool.c (modified) (1 diff)
-
ippTools/src/pxadmin.c (modified) (1 diff)
-
ippTools/src/pxadminConfig.c (modified) (3 diffs)
-
ippTools/src/pxinject.c (modified) (1 diff)
-
ippTools/src/pztool.c (modified) (1 diff)
-
ippTools/src/pztoolConfig.c (modified) (1 diff)
-
ippTools/src/regtool.c (modified) (1 diff)
-
ippTools/src/regtoolConfig.c (modified) (1 diff)
-
ippTools/src/warptool.c (modified) (1 diff)
-
ippTools/src/warptoolConfig.c (modified) (1 diff)
-
ppImage/src/ppFocusParseCamera.c (modified) (4 diffs)
-
ppImage/src/ppImageDetrendNonLinear.c (modified) (1 diff)
-
ppImage/src/ppImageParseCamera.c (modified) (1 diff)
-
psastro/src/psastroLuminosityFunction.c (modified) (1 diff)
-
psastro/src/psastroWCS.c (modified) (7 diffs)
-
psphot/src/models/pmModel_STRAIL.c (modified) (4 diffs)
-
psphot/src/models/pmModel_TEST1.c (modified) (5 diffs)
-
psphot/src/psphotBlendFit.c (modified) (1 diff)
-
psphot/src/psphotChoosePSF.c (modified) (4 diffs)
-
psphot/src/psphotEnsemblePSF.c (modified) (3 diffs)
-
psphot/src/psphotModelTest.c (modified) (4 diffs)
-
psphot/src/psphotOutput.c (modified) (1 diff)
-
psphot/src/psphotRadiusChecks.c (modified) (3 diffs)
-
psphot/src/psphotSkyReplace.c (modified) (1 diff)
-
psphot/src/psphotSourceFits.c (modified) (5 diffs)
-
psphot/src/psphotTestPSF.c (modified) (2 diffs)
-
psphot/src/psphotWeightBias.c (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ippTools/src/camtool.c
r11572 r11702 59 59 MODECASE(P3TOOL_MODE_UNBLOCK, unblockMode); 60 60 default: 61 psAbort( argv[0],"invalid option (this should not happen)");61 psAbort("invalid option (this should not happen)"); 62 62 } 63 63 -
trunk/ippTools/src/camtoolConfig.c
r11089 r11702 188 188 while ((item = psMetadataGetAndIncrement(iter))) { 189 189 if (!item->type == PS_DATA_METADATA) { 190 psAbort( argv[0],"all options must be specified as a metadata"); }190 psAbort("all options must be specified as a metadata"); } 191 191 192 192 fprintf(stdout, "%s ", item->name); -
trunk/ippTools/src/chiptool.c
r11562 r11702 65 65 MODECASE(P2TOOL_MODE_UNBLOCK, unblockMode); 66 66 default: 67 psAbort( argv[0],"invalid option (this should not happen)");67 psAbort("invalid option (this should not happen)"); 68 68 } 69 69 -
trunk/ippTools/src/chiptoolConfig.c
r11562 r11702 225 225 while ((item = psMetadataGetAndIncrement(iter))) { 226 226 if (!item->type == PS_DATA_METADATA) { 227 psAbort( argv[0],"all options must be specified as a metadata"); }227 psAbort("all options must be specified as a metadata"); } 228 228 229 229 fprintf(stdout, "%s ", item->name); -
trunk/ippTools/src/detselect.c
r11427 r11702 47 47 MODECASE(DETSELECT_MODE_SELECT, selectMode); 48 48 default: 49 psAbort( argv[0],"invalid option (this should not happen)");49 psAbort("invalid option (this should not happen)"); 50 50 } 51 51 -
trunk/ippTools/src/detselectConfig.c
r11418 r11702 118 118 while ((item = psMetadataGetAndIncrement(iter))) { 119 119 if (!item->type == PS_DATA_METADATA) { 120 psAbort( argv[0],"all options must be specified as a metadata"); }120 psAbort("all options must be specified as a metadata"); } 121 121 122 122 fprintf(stdout, "%s ", item->name); -
trunk/ippTools/src/dettool.c
r11480 r11702 136 136 MODECASE(DETTOOL_MODE_REGISTER_DETREND_IMFILE, register_detrend_imfileMode); 137 137 default: 138 psAbort( argv[0],"invalid option (this should not happen)");138 psAbort("invalid option (this should not happen)"); 139 139 } 140 140 … … 457 457 psFree(iter); 458 458 } else { 459 psAbort(config->argv[0], 460 "-exp_tag was not parsed correctly (this should not happen"); 459 psAbort( "-exp_tag was not parsed correctly (this should not happen"); 461 460 } 462 461 … … 476 475 // we should have one rawExp row per exp_tag specified 477 476 if (psListLength(item->data.list) != psArrayLength(detrendExps)) { 478 psAbort(config->argv[0], 479 "an -exp_tag matched more then one rawExp (this should not happen"); 477 psAbort( "an -exp_tag matched more then one rawExp (this should not happen"); 480 478 481 479 } … … 579 577 // sanity check results 580 578 if (psArrayLength(detRuns) != 1) { 581 psAbort( config->argv[0],"found more then one detRun matching det_id %ld(this should not happen)", det_id);579 psAbort("found more then one detRun matching det_id %ld(this should not happen)", det_id); 582 580 return false; 583 581 } … … 1213 1211 // sanity check results 1214 1212 if (psArrayLength(detRuns) != 1) { 1215 psAbort( config->argv[0],"found more then one detRun matching det_id %ld(this should not happen)", det_id);1213 psAbort("found more then one detRun matching det_id %ld(this should not happen)", det_id); 1216 1214 return false; 1217 1215 } … … 1266 1264 // sanity check the result... we should have only found one det_id 1267 1265 if (psArrayLength(detRuns) != 1) { 1268 psAbort( config->argv[0],"found more then one detRun matching det_id %d(this should not happen)", (psS32)atoi(det_id));1266 psAbort("found more then one detRun matching det_id %d(this should not happen)", (psS32)atoi(det_id)); 1269 1267 return false; // unreachable 1270 1268 } … … 1627 1625 // sanity check the result... we should have only found one det_id 1628 1626 if (psArrayLength(newDetRuns) != 1) { 1629 psAbort( config->argv[0],"found more then one detRun matching det_id %ld(this should not happen)", newDet_id);1627 psAbort("found more then one detRun matching det_id %ld(this should not happen)", newDet_id); 1630 1628 return false; // unreachable 1631 1629 } … … 5962 5960 psFree(iter); 5963 5961 } else { 5964 psAbort(config->argv[0], 5965 "-exp_tag was not parsed correctly (this should not happen"); 5962 psAbort( "-exp_tag was not parsed correctly (this should not happen"); 5966 5963 } 5967 5964 … … 6462 6459 if (psArrayLength(detRuns) != 1) { 6463 6460 // this should no happen 6464 psAbort(config->argv[0], 6465 "database query return too many rows (this should not happen"); 6461 psAbort( "database query return too many rows (this should not happen"); 6466 6462 } 6467 6463 -
trunk/ippTools/src/dettoolConfig.c
r11480 r11702 863 863 while ((item = psMetadataGetAndIncrement(iter))) { 864 864 if (!item->type == PS_DATA_METADATA) { 865 psAbort( argv[0],"all options must be specified as a metadata");865 psAbort("all options must be specified as a metadata"); 866 866 } 867 867 -
trunk/ippTools/src/guidetool.c
r9392 r11702 47 47 break; 48 48 default: 49 psAbort( argv[0],"invalid option (this should not happen)");49 psAbort("invalid option (this should not happen)"); 50 50 } 51 51 -
trunk/ippTools/src/pxadmin.c
r10046 r11702 50 50 break; 51 51 default: 52 psAbort( argv[0],"invalid option (this should not happen)");52 psAbort("invalid option (this should not happen)"); 53 53 } 54 54 -
trunk/ippTools/src/pxadminConfig.c
r11089 r11702 49 49 psArgumentRemove(N, &argc, argv); 50 50 if (config->mode) { 51 psAbort( argv[0],"only one mode selection is allowed");51 psAbort("only one mode selection is allowed"); 52 52 } 53 53 config->mode = PXADMIN_MODE_CREATE; … … 56 56 psArgumentRemove(N, &argc, argv); 57 57 if (config->mode) { 58 psAbort( argv[0],"only one mode selection is allowed");58 psAbort("only one mode selection is allowed"); 59 59 } 60 60 config->mode = PXADMIN_MODE_DELETE; … … 63 63 psArgumentRemove(N, &argc, argv); 64 64 if (config->mode) { 65 psAbort( argv[0],"only one mode selection is allowed");65 psAbort("only one mode selection is allowed"); 66 66 } 67 67 config->mode = PXADMIN_MODE_RECREATE; -
trunk/ippTools/src/pxinject.c
r11142 r11702 49 49 MODECASE(PXINJECT_MODE_NEWIMFILE, newImfileMode); 50 50 default: 51 psAbort( argv[0],"invalid option (this should not happen)");51 psAbort("invalid option (this should not happen)"); 52 52 } 53 53 -
trunk/ippTools/src/pztool.c
r10971 r11702 55 55 MODECASE(PZTOOL_MODE_COPYDONE, copydoneMode); 56 56 default: 57 psAbort( argv[0],"invalid option (this should not happen)");57 psAbort("invalid option (this should not happen)"); 58 58 } 59 59 -
trunk/ippTools/src/pztoolConfig.c
r11089 r11702 139 139 while ((item = psMetadataGetAndIncrement(iter))) { 140 140 if (!item->type == PS_DATA_METADATA) { 141 psAbort( argv[0],"all options must be specified as a metadata");141 psAbort("all options must be specified as a metadata"); 142 142 } 143 143 -
trunk/ippTools/src/regtool.c
r11329 r11702 72 72 MODECASE(P0TOOL_MODE_UPDATEPROCESSEDEXP, updateprocessedexpMode); 73 73 default: 74 psAbort( argv[0],"invalid option (this should not happen)");74 psAbort("invalid option (this should not happen)"); 75 75 } 76 76 -
trunk/ippTools/src/regtoolConfig.c
r11561 r11702 259 259 while ((item = psMetadataGetAndIncrement(iter))) { 260 260 if (!item->type == PS_DATA_METADATA) { 261 psAbort( argv[0],"all options must be specified as a metadata"); }261 psAbort("all options must be specified as a metadata"); } 262 262 263 263 fprintf(stdout, "%s ", item->name); -
trunk/ippTools/src/warptool.c
r11138 r11702 69 69 MODECASE(P4TOOL_MODE_DIFFIMFILE, diffimfileMode); 70 70 default: 71 psAbort( argv[0],"invalid option (this should not happen)");71 psAbort("invalid option (this should not happen)"); 72 72 } 73 73 -
trunk/ippTools/src/warptoolConfig.c
r11138 r11702 229 229 while ((item = psMetadataGetAndIncrement(iter))) { 230 230 if (!item->type == PS_DATA_METADATA) { 231 psAbort( argv[0],"all options must be specified as a metadata");231 psAbort("all options must be specified as a metadata"); 232 232 } 233 233 -
trunk/ppImage/src/ppFocusParseCamera.c
r10439 r11702 29 29 pmFPAfileDefineFromConf (&status, config, "PPIMAGE.BIAS"); 30 30 pmFPAfileDefineFromDetDB (&status, config, "PPIMAGE.BIAS", input->fpa, PM_DETREND_TYPE_BIAS); 31 if (!status) psAbort ("ppImageParseDetrend","can't find a bias image source");31 if (!status) psAbort("can't find a bias image source"); 32 32 } 33 33 if (options->doDark) { … … 36 36 pmFPAfileDefineFromConf (&status, config, "PPIMAGE.DARK"); 37 37 pmFPAfileDefineFromDetDB (&status, config, "PPIMAGE.DARK", input->fpa, PM_DETREND_TYPE_DARK); 38 if (!status) psAbort ("ppImageParseDetrend","can't find a dark image source");38 if (!status) psAbort("can't find a dark image source"); 39 39 } 40 40 if (options->doMask) { … … 43 43 pmFPAfileDefineFromConf (&status, config, "PPIMAGE.MASK"); 44 44 pmFPAfileDefineFromDetDB (&status, config, "PPIMAGE.MASK", input->fpa, PM_DETREND_TYPE_MASK); 45 if (!status) psAbort ("ppImageParseDetrend","can't find a mask image source");45 if (!status) psAbort("can't find a mask image source"); 46 46 } 47 47 if (options->doFlat) { … … 50 50 pmFPAfileDefineFromConf (&status, config, "PPIMAGE.FLAT"); 51 51 pmFPAfileDefineFromDetDB (&status, config, "PPIMAGE.FLAT", input->fpa, PM_DETREND_TYPE_FLAT); 52 if (!status) psAbort ("ppImageParseDetrend","can't find a flat image source");52 if (!status) psAbort("can't find a flat image source"); 53 53 } 54 54 -
trunk/ppImage/src/ppImageDetrendNonLinear.c
r8751 r11702 108 108 } 109 109 default: 110 psAbort(" phase2", "Invalid options->nonLinearType");110 psAbort("Invalid options->nonLinearType"); 111 111 } 112 112 return true; -
trunk/ppImage/src/ppImageParseCamera.c
r11199 r11702 126 126 filters = psMemIncrRefCounter(mdi->data.list); 127 127 } else { 128 psAbort ("ppImage","invalid type for FRINGE.FILTERS");128 psAbort("invalid type for FRINGE.FILTERS"); 129 129 } 130 130 -
trunk/psastro/src/psastroLuminosityFunction.c
r11269 r11702 51 51 if (!isfinite(star->Mag)) continue; 52 52 int bin = (star->Mag - mMin) / dMag; 53 if (bin < 0) psAbort ("psastro","bin cannot be negative!");54 if (bin >= nBin) psAbort ("psastro","bin cannot be > %d!", nBin);53 if (bin < 0) psAbort("bin cannot be negative!"); 54 if (bin >= nBin) psAbort("bin cannot be > %d!", nBin); 55 55 nMags->data.F32[bin] += 1.0; 56 56 } -
trunk/psastro/src/psastroWCS.c
r10613 r11702 142 142 fpa->toSky = toSky; 143 143 } else { 144 if (fpa->toTPA == NULL) psAbort ("wcs","projection defined, tangent-plane not defined");145 if (fpa->fromTPA == NULL) psAbort ("wcs","projection defined, tangent-plane not defined");144 if (fpa->toTPA == NULL) psAbort("projection defined, tangent-plane not defined"); 145 if (fpa->fromTPA == NULL) psAbort("projection defined, tangent-plane not defined"); 146 146 147 147 // adjust for common toSky for mosaic: … … 212 212 213 213 // techinically, we can have a plate scale here (toTPA:dx,dy != 1) 214 if (!psPlaneDistortIsIdentity (toTPA)) psAbort ("psastro","invalid TPA transformation");214 if (!psPlaneDistortIsIdentity (toTPA)) psAbort("invalid TPA transformation"); 215 215 216 216 // XXX require toFPA->x->nX == toFPA->x->nY … … 395 395 psMetadataAddF32 (header, PS_LIST_TAIL, "CDELT2", PS_META_REPLACE, "", 1.0); 396 396 397 if (toFPA->x->nX != toFPA->x->nY) psAbort ("psastro","mis-matched tangent plane orders (1)");398 if (toFPA->x->nX != toFPA->y->nX) psAbort ("psastro","mis-matched tangent plane orders (2)");399 if (toFPA->x->nX != toFPA->y->nY) psAbort ("psastro","mis-matched tangent plane orders (3)");397 if (toFPA->x->nX != toFPA->x->nY) psAbort("mis-matched tangent plane orders (1)"); 398 if (toFPA->x->nX != toFPA->y->nX) psAbort("mis-matched tangent plane orders (2)"); 399 if (toFPA->x->nX != toFPA->y->nY) psAbort("mis-matched tangent plane orders (3)"); 400 400 401 401 switch (toFPA->x->nX) { … … 428 428 429 429 case 0: 430 psAbort ("psastro","invalid tangent plane order");430 psAbort("invalid tangent plane order"); 431 431 } 432 432 return true; … … 450 450 psMetadataAddF32 (header, PS_LIST_TAIL, "CDELT2", PS_META_REPLACE, "", toSky->Ys*DEG_RAD*plateScale); 451 451 452 if (toTP->x->nX != toTP->x->nY) psAbort ("psastro","mis-matched tangent plane orders (1)");453 if (toTP->x->nX != toTP->y->nX) psAbort ("psastro","mis-matched tangent plane orders (2)");454 if (toTP->x->nX != toTP->y->nY) psAbort ("psastro","mis-matched tangent plane orders (3)");452 if (toTP->x->nX != toTP->x->nY) psAbort("mis-matched tangent plane orders (1)"); 453 if (toTP->x->nX != toTP->y->nX) psAbort("mis-matched tangent plane orders (2)"); 454 if (toTP->x->nX != toTP->y->nY) psAbort("mis-matched tangent plane orders (3)"); 455 455 456 456 switch (toTP->x->nX) { … … 483 483 484 484 case 0: 485 psAbort ("psastro","invalid tangent plane order");485 psAbort("invalid tangent plane order"); 486 486 } 487 487 return header; … … 493 493 psPlaneDistort *distort; 494 494 495 if (order < 1) psAbort ("psastro","invalid order");496 if (order > 3) psAbort ("psastro","invalid order");495 if (order < 1) psAbort("invalid order"); 496 if (order > 3) psAbort("invalid order"); 497 497 498 498 // all coeffs and masks initially set to 0 -
trunk/psphot/src/models/pmModel_STRAIL.c
r10414 r11702 333 333 334 334 default: 335 psAbort ("psModules.pmModel_GAUSS","invalid parameter %d for beta test", nParam);335 psAbort("invalid parameter %d for beta test", nParam); 336 336 } 337 337 if (fabs(beta[nParam]) > fabs(beta_lim)) { … … 353 353 354 354 default: 355 psAbort ("psModules.pmModel_GAUSS","invalid parameter %d for param min test", nParam);355 psAbort("invalid parameter %d for param min test", nParam); 356 356 } 357 357 if (params[nParam] < params_min) { … … 372 372 case 8: params_max = M_PI; break; 373 373 default: 374 psAbort ("psModules.pmModel_GAUSS","invalid parameter %d for param max test", nParam);374 psAbort("invalid parameter %d for param max test", nParam); 375 375 } 376 376 if (params[nParam] > params_max) { … … 380 380 return true; 381 381 default: 382 psAbort ("psModules.pmModel_GAUSS","invalid choice for limits");382 psAbort("invalid choice for limits"); 383 383 } 384 psAbort ("psModules.pmModel_GAUSS","should not reach here");384 psAbort("should not reach here"); 385 385 return false; 386 386 } -
trunk/psphot/src/models/pmModel_TEST1.c
r10426 r11702 76 76 case PM_PAR_SXY: beta_lim = 0.5; break; 77 77 default: 78 psAbort ("psModules.pmModel_GAUSS","invalid parameter %d for beta test", nParam);78 psAbort("invalid parameter %d for beta test", nParam); 79 79 } 80 80 if (fabs(beta[nParam]) > fabs(beta_lim)) { … … 93 93 case PM_PAR_SXY: params_min = -5.0; break; 94 94 default: 95 psAbort ("psModules.pmModel_GAUSS","invalid parameter %d for param min test", nParam);95 psAbort("invalid parameter %d for param min test", nParam); 96 96 } 97 97 if (params[nParam] < params_min) { … … 110 110 case PM_PAR_SXY: params_max = +5.0; break; 111 111 default: 112 psAbort ("psModules.pmModel_GAUSS","invalid parameter %d for param max test", nParam);112 psAbort("invalid parameter %d for param max test", nParam); 113 113 } 114 114 if (params[nParam] > params_max) { … … 118 118 return true; 119 119 default: 120 psAbort ("psModules.pmModel_GAUSS","invalid choice for limits");121 } 122 psAbort ("psModules.pmModel_GAUSS","should not reach here");120 psAbort("invalid choice for limits"); 121 } 122 psAbort("should not reach here"); 123 123 return false; 124 124 } … … 201 201 psF64 radius = axes.major * sqrt (2.0 * log(params->data.F32[PM_PAR_I0] / flux)); 202 202 203 if (isnan(radius)) psAbort ("psphot.model","error in code: never return invalid radius");204 if (radius < 0) psAbort ("psphot.model","error in code: never return invalid radius");203 if (isnan(radius)) psAbort("error in code: never return invalid radius"); 204 if (radius < 0) psAbort("error in code: never return invalid radius"); 205 205 206 206 return (radius); -
trunk/psphot/src/psphotBlendFit.c
r11381 r11702 27 27 char *region = psMetadataLookupStr (&status, recipe, "ANALYSIS_REGION"); 28 28 psRegion AnalysisRegion = psRegionForImage (readout->image, psRegionFromString (region)); 29 if (psRegionIsNaN (AnalysisRegion)) psAbort ("psphot","analysis region mis-defined");29 if (psRegionIsNaN (AnalysisRegion)) psAbort("analysis region mis-defined"); 30 30 31 31 for (int i = 0; i < sources->n; i++) { -
trunk/psphot/src/psphotChoosePSF.c
r11306 r11702 15 15 psf = psMetadataLookupPtr (NULL, readout->analysis, "PSPHOT.PSF"); 16 16 if (psf != NULL) { 17 if (!psphotPSFstats (readout, recipe, psf)) psAbort ("psphotChoosePSF","cannot measure PSF shape terms");17 if (!psphotPSFstats (readout, recipe, psf)) psAbort("cannot measure PSF shape terms"); 18 18 return psf; 19 19 } … … 96 96 psList *list = NULL; 97 97 psMetadataItem *mdi = psMetadataLookup (recipe, "PSF_MODEL"); 98 if (mdi == NULL) psAbort ("psphotChoosePSF","missing PSF_MODEL selection");98 if (mdi == NULL) psAbort("missing PSF_MODEL selection"); 99 99 100 100 if (mdi->type == PS_DATA_STRING) { … … 102 102 psListAdd (list, PS_LIST_HEAD, mdi); 103 103 } else { 104 if (mdi->type != PS_DATA_METADATA_MULTI) psAbort ("psphotChoosePSF","missing PSF_MODEL selection");104 if (mdi->type != PS_DATA_METADATA_MULTI) psAbort("missing PSF_MODEL selection"); 105 105 list = psMemIncrRefCounter(mdi->data.list); 106 106 } … … 247 247 psFree (models); 248 248 249 if (!psphotPSFstats (readout, recipe, psf)) psAbort ("psphotChoosePSF","cannot measure PSF shape terms");249 if (!psphotPSFstats (readout, recipe, psf)) psAbort("cannot measure PSF shape terms"); 250 250 251 251 modelName = pmModelGetType (psf->type); -
trunk/psphot/src/psphotEnsemblePSF.c
r11166 r11702 34 34 psRegion AnalysisRegion = psRegionFromString (region); 35 35 AnalysisRegion = psRegionForImage (readout->image, AnalysisRegion); 36 if (psRegionIsNaN (AnalysisRegion)) psAbort ("psphot","analysis region mis-defined");36 if (psRegionIsNaN (AnalysisRegion)) psAbort("analysis region mis-defined"); 37 37 38 38 bool CONSTANT_PHOTOMETRIC_WEIGHTS = 39 39 psMetadataLookupBool(&status, recipe, "CONSTANT_PHOTOMETRIC_WEIGHTS"); 40 40 if (!status) { 41 psAbort( PS_FILE_LINE,"You must provide a value for the BOOL recipe CONSTANT_PHOTOMETRIC_WEIGHTS");41 psAbort("You must provide a value for the BOOL recipe CONSTANT_PHOTOMETRIC_WEIGHTS"); 42 42 } 43 43 int SKY_FIT_ORDER = psMetadataLookupS32(&status, recipe, "SKY_FIT_ORDER"); … … 161 161 162 162 default: 163 psAbort( PS_FILE_LINE,"Invalid SKY_FIT_ORDER %d\n", SKY_FIT_ORDER);163 psAbort("Invalid SKY_FIT_ORDER %d\n", SKY_FIT_ORDER); 164 164 break; 165 165 } … … 211 211 // assign linearly-fitted normalization 212 212 if (isnan(norm->data.F32[i])) { 213 psAbort ("psphot","ensemble source is nan");213 psAbort("ensemble source is nan"); 214 214 } 215 215 model->params->data.F32[PM_PAR_I0] = norm->data.F32[i]; -
trunk/psphot/src/psphotModelTest.c
r11172 r11702 33 33 if (fitMode == PM_SOURCE_FIT_PSF) { 34 34 char *psfFile = psMetadataLookupStr (&status, recipe, "PSF_INPUT_FILE"); 35 if (!status) psAbort ("psphotModelTest","PSF_INPUT_FILE not supplied");35 if (!status) psAbort("PSF_INPUT_FILE not supplied"); 36 36 psMetadata *psfData = psMetadataConfigRead(NULL, &Nfail, psfFile, FALSE); 37 37 psf = pmPSFfromMetadata (psfData); … … 45 45 psList *list = NULL; 46 46 psMetadataItem *mdi = psMetadataLookup (recipe, "PSF_MODEL"); 47 if (mdi == NULL) psAbort ("psphotModelTest","missing PSF_MODEL selection");47 if (mdi == NULL) psAbort("missing PSF_MODEL selection"); 48 48 if (mdi->type == PS_DATA_STRING) { 49 49 list = psListAlloc(NULL); 50 50 psListAdd (list, PS_LIST_HEAD, mdi); 51 51 } else { 52 if (mdi->type != PS_DATA_METADATA_MULTI) psAbort ("psphotChoosePSF","missing PSF_MODEL selection");52 if (mdi->type != PS_DATA_METADATA_MULTI) psAbort("missing PSF_MODEL selection"); 53 53 list = psMemIncrRefCounter(mdi->data.list); 54 54 } … … 59 59 } 60 60 modelType = pmModelSetType (modelName); 61 if (modelType < 0) psAbort ("fitsource","unknown model %s", modelName);61 if (modelType < 0) psAbort("unknown model %s", modelName); 62 62 } 63 63 … … 94 94 // find the local sky 95 95 status = pmSourceLocalSky (source, PS_STAT_SAMPLE_MEDIAN, INNER); 96 if (!status) psAbort ("fitsource","pmSourceLocalSky error");96 if (!status) psAbort("pmSourceLocalSky error"); 97 97 98 98 // get the source moments 99 99 status = pmSourceMoments (source, mRADIUS); 100 if (!status) psAbort ("fitsource","pmSourceLocalSky error");100 if (!status) psAbort("pmSourceLocalSky error"); 101 101 source->peak->value = source->moments->Peak; 102 102 -
trunk/psphot/src/psphotOutput.c
r11583 r11702 51 51 52 52 FILE *f = fopen (name, "w"); 53 if (f == NULL) psAbort ("psphot","can't open file");53 if (f == NULL) psAbort("can't open file"); 54 54 55 55 for (int i = 0; i < source->pixels->numRows; i++) { -
trunk/psphot/src/psphotRadiusChecks.c
r11174 r11702 40 40 model->radiusFit = (RADIUS_TYPE)(radiusFit + PSF_FIT_PADDING); 41 41 42 if (isnan(model->radiusFit)) psAbort ("apply_psf_model","error in radius");42 if (isnan(model->radiusFit)) psAbort("error in radius"); 43 43 44 44 if (source->mode & PM_SOURCE_MODE_SATSTAR) { … … 57 57 // set the fit radius based on the object flux limit and the model 58 58 model->radiusFit = (RADIUS_TYPE) (modelRadiusPSF (model->params, PSF_FIT_NSIGMA*moments->dSky) + dR + PSF_FIT_PADDING); 59 if (isnan(model->radiusFit)) psAbort ("apply_psf_model","error in radius");59 if (isnan(model->radiusFit)) psAbort("error in radius"); 60 60 61 61 if (source->mode & PM_SOURCE_MODE_SATSTAR) { … … 91 91 // set the fit radius based on the object flux limit and the model 92 92 model->radiusFit = (RADIUS_TYPE) (modelRadiusEXT (model->params, EXT_FIT_NSIGMA*moments->dSky) + EXT_FIT_PADDING); 93 if (isnan(model->radiusFit)) psAbort (__func__,"error in radius");93 if (isnan(model->radiusFit)) psAbort("error in radius"); 94 94 95 95 // redefine the pixels if needed -
trunk/psphot/src/psphotSkyReplace.c
r10801 r11702 9 9 // find the currently selected readout 10 10 pmReadout *readout = pmFPAfileThisReadout (config->files, view, "PSPHOT.INPUT"); 11 if (readout == NULL) psAbort ("psphot","input not defined");11 if (readout == NULL) psAbort("input not defined"); 12 12 13 13 // select background pixels, from output background file, or create 14 14 pmReadout *background = pmFPAfileThisReadout (config->files, view, "PSPHOT.BACKGND"); 15 if (background == NULL) psAbort ("psphot","background not defined");15 if (background == NULL) psAbort("background not defined"); 16 16 17 17 // select the corresponding images -
trunk/psphot/src/psphotSourceFits.c
r11381 r11702 34 34 pmModel *PSF = pmModelCopy (source->modelPSF); 35 35 36 if (isnan(PSF->params->data.F32[PM_PAR_I0])) psAbort ("psphot","nan in blend fit primary");36 if (isnan(PSF->params->data.F32[PM_PAR_I0])) psAbort("nan in blend fit primary"); 37 37 38 38 x = PSF->params->data.F32[PM_PAR_XPOS]; … … 67 67 // these should never be invalid values 68 68 // XXX drop these tests eventually 69 if (isnan(model->params->data.F32[PM_PAR_I0])) psAbort ("psphot","nan in blend fit");70 if (isnan(model->params->data.F32[PM_PAR_XPOS])) psAbort ("psphot","nan in blend fit");71 if (isnan(model->params->data.F32[PM_PAR_YPOS])) psAbort ("psphot","nan in blend fit");69 if (isnan(model->params->data.F32[PM_PAR_I0])) psAbort("nan in blend fit"); 70 if (isnan(model->params->data.F32[PM_PAR_XPOS])) psAbort("nan in blend fit"); 71 if (isnan(model->params->data.F32[PM_PAR_YPOS])) psAbort("nan in blend fit"); 72 72 73 73 // add this blend to the list … … 145 145 // save the PSF model from the Ensemble fit 146 146 pmModel *PSF = pmModelCopy (source->modelPSF); 147 if (isnan(PSF->params->data.F32[1])) psAbort ("psphot","nan in psf fit");147 if (isnan(PSF->params->data.F32[1])) psAbort("nan in psf fit"); 148 148 149 149 // extend source radius as needed … … 328 328 PSF = source->modelPSF; 329 329 psphotCheckRadiusPSFBlend (readout, source, PSF, 8.0); 330 if (isnan(PSF->params->data.F32[1])) psAbort ("psphot","nan in dbl fit");330 if (isnan(PSF->params->data.F32[1])) psAbort("nan in dbl fit"); 331 331 332 332 modelSet = psArrayAlloc (2); … … 365 365 assert (EXT != NULL); 366 366 367 // if (isnan(EXT->params->data.F32[1])) psAbort ("psphot","nan in ext fit");367 // if (isnan(EXT->params->data.F32[1])) psAbort("nan in ext fit"); 368 368 369 369 psphotCheckRadiusEXT (readout, source, EXT); -
trunk/psphot/src/psphotTestPSF.c
r10096 r11702 74 74 // for this test, require a single model 75 75 psMetadataItem *mdi = psMetadataLookup (recipe, "PSF_MODEL"); 76 if (mdi == NULL) psAbort ("psphotChoosePSF","missing PSF_MODEL selection");77 if (mdi->type != PS_DATA_STRING) psAbort ("psphotChoosePSF","choose a single PSF_MODEL");76 if (mdi == NULL) psAbort("missing PSF_MODEL selection"); 77 if (mdi->type != PS_DATA_STRING) psAbort("choose a single PSF_MODEL"); 78 78 modelName = mdi->data.V; 79 79 … … 95 95 pmModelType type = pmModelSetType (modelName); 96 96 pmPSF *psf = pmPSFAlloc (type, poissonErrors, psfTrendMask); 97 if (psf == NULL) psAbort ("psphotTestPSF","unknown model");97 if (psf == NULL) psAbort("unknown model"); 98 98 99 99 FILE *f = fopen ("params.dat", "w"); -
trunk/psphot/src/psphotWeightBias.c
r11200 r11702 34 34 char *region = psMetadataLookupStr (&status, recipe, "ANALYSIS_REGION"); 35 35 psRegion AnalysisRegion = psRegionForImage (readout->image, psRegionFromString (region)); 36 if (psRegionIsNaN (AnalysisRegion)) psAbort ("psphot","analysis region mis-defined");36 if (psRegionIsNaN (AnalysisRegion)) psAbort("analysis region mis-defined"); 37 37 38 38 FILE *f = fopen ("bias.dat", "w"); 39 if (f == NULL) psAbort ("psphot","can't open output file");39 if (f == NULL) psAbort("can't open output file"); 40 40 41 41 for (int i = 0; i < sources->n; i++) {
Note:
See TracChangeset
for help on using the changeset viewer.
