IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
May 22, 2020, 5:12:02 PM (6 years ago)
Author:
eugene
Message:

initial version with TGroups (for photometric nights)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/eam_branches/relphot.20200519/src/StarOps.c

    r40291 r41362  
    105105  results->Ncal  = 0;
    106106  results->Nmos  = 0;
     107  results->Ngrp  = 0;
    107108  results->Ngrid = 0;
    108109}
     
    264265  summary->Ncal  += results->Ncal ;
    265266  summary->Nmos  += results->Nmos ;
     267  summary->Ngrp  += results->Ngrp ;
    266268  summary->Ngrid += results->Ngrid;
    267269}
     
    313315    SetMrelInfoAccum (&summary, &results);
    314316  }
    315   if (VERBOSE2) fprintf (stderr, "%d stars with no data in photcode, %d stars marked having too few measurements (Nbad: %d, Ncal: %d, Nmos: %d, Ngrid: %d, Nsys: %d)\n", summary.Ncode, summary.Nfew, summary.Nbad, summary.Ncal, summary.Nmos, summary.Ngrid, summary.Nsys);
     317  if (VERBOSE2) fprintf (stderr, "%d stars with no data in photcode, %d stars marked having too few measurements (Nbad: %d, Ncal: %d, Nmos: %d, Ngrp: %d, Ngrid: %d, Nsys: %d)\n", summary.Ncode, summary.Nfew, summary.Nbad, summary.Ncal, summary.Nmos, summary.Ngrp, summary.Ngrid, summary.Nsys);
    316318
    317319  SetMrelInfoFree (&results);
     
    336338    SetMrelInfoAccum (&summary, &results);
    337339  }
    338   if (VERBOSE2) fprintf (stderr, "%d stars with no data in photcode, %d stars marked having too few measurements (Nbad: %d, Ncal: %d, Nmos: %d, Ngrid: %d, Nsys: %d)\n", summary.Ncode, summary.Nfew, summary.Nbad, summary.Ncal, summary.Nmos, summary.Ngrid, summary.Nsys);
     340  if (VERBOSE2) fprintf (stderr, "%d stars with no data in photcode, %d stars marked having too few measurements (Nbad: %d, Ncal: %d, Nmos: %d, Ngrp: %d, Ngrid: %d, Nsys: %d)\n", summary.Ncode, summary.Nfew, summary.Nbad, summary.Ncal, summary.Nmos, summary.Ngrp, summary.Ngrid, summary.Nsys);
    339341
    340342  SetMrelInfoFree (&results);
     
    393395  // report stats & summary from the threads
    394396  for (i = 0; i < NTHREADS; i++) {
    395     if (VERBOSE2) fprintf (stderr, "setMrel thread %d : %d stars with no data in photcode, %d stars marked having too few measurements (Nbad: %d, Ncal: %d, Nmos: %d, Ngrid: %d, Nsys: %d)\n",
     397    if (VERBOSE2) fprintf (stderr, "setMrel thread %d : %d stars with no data in photcode, %d stars marked having too few measurements (Nbad: %d, Ncal: %d, Nmos: %d, Ngrp: %d, Ngrid: %d, Nsys: %d)\n",
    396398             i,
    397399             threadinfo[i].summary.Ncode,
     
    400402             threadinfo[i].summary.Ncal,
    401403             threadinfo[i].summary.Nmos,
     404             threadinfo[i].summary.Ngrp,
    402405             threadinfo[i].summary.Ngrid,
    403406             threadinfo[i].summary.Nsys);
     
    405408    SetMrelInfoFree (&threadinfo[i].summary);
    406409  }
    407   if (VERBOSE2) fprintf (stderr, "total : %d stars with no data in photcode, %d stars marked having too few measurements (Nbad: %d, Ncal: %d, Nmos: %d, Ngrid: %d, Nsys: %d)\n", summary.Ncode, summary.Nfew, summary.Nbad, summary.Ncal, summary.Nmos, summary.Ngrid, summary.Nsys);
     410  if (VERBOSE2) fprintf (stderr, "total : %d stars with no data in photcode, %d stars marked having too few measurements (Nbad: %d, Ncal: %d, Nmos: %d, Ngrp: %d, Ngrid: %d, Nsys: %d)\n", summary.Ncode, summary.Nfew, summary.Nbad, summary.Ncal, summary.Nmos, summary.Ngrp, summary.Ngrid, summary.Nsys);
    408411  free (threadinfo);
    409412
     
    488491        float Mmos  = getMmos  (m, i);
    489492        if (isnan(Mmos)) continue;
     493        float Mgrp  = getMgrp  (m, i);
     494        if (isnan(Mgrp)) continue;
    490495        float Mgrid = getMgrid (m, i);
    491496        if (isnan(Mgrid)) continue;
     
    502507
    503508        // set the output calibration
    504         catalog[i].measure[m].McalPSF  = McalPSF  + Mmos + Mgrid;
    505         catalog[i].measure[m].McalAPER = useStackAper ? McalAPER + Mmos + Mgrid : McalPSF  + Mmos + Mgrid;
     509        float Moff = Mmos + Mgrp + Mgrid;
     510        catalog[i].measure[m].McalPSF  = McalPSF + Moff;
     511        catalog[i].measure[m].McalAPER = useStackAper ? McalAPER + Moff : McalPSF + Moff;
    506512
    507513        if (catalog[i].measureT[m].dbFlags & ID_MEAS_PHOTOM_UBERCAL) {
     
    662668  off_t *ilist;
    663669  double *tlist, *list, *dlist;
    664   float Msys, Mcal, Mmos, Mgrid;
    665   int Ncal, Nmos, Ngrid, Nfew;
     670  float Msys, Mcal, Mmos, Mgrp, Mgrid;
     671  int Ncal, Nmos, Ngrp, Ngrid, Nfew;
    666672
    667673  int Nsecfilt = GetPhotcodeNsecfilt ();
     
    689695
    690696  Ndel = Nave = 0;
    691   Ncal = Nmos = Ngrid = Nfew = 0;
     697  Ncal = Nmos = Ngrp = Ngrid = Nfew = 0;
    692698  for (i = 0; i < Ncatalog; i++) {
    693699    for (j = 0; j < catalog[i].Naverage; j++) {
     
    724730          Mmos  = getMmos  (m, i);
    725731          if (isnan(Mmos)) { Nmos ++; continue; }
     732          Mgrp  = getMgrp  (m, i);
     733          if (isnan(Mgrp)) { Ngrp ++; continue; }
    726734          Mgrid = getMgrid (m, i);
    727735          if (isnan(Mgrid)) { Ngrid ++; continue; }
Note: See TracChangeset for help on using the changeset viewer.