IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
May 5, 2011, 10:43:45 AM (15 years ago)
Author:
eugene
Message:

various improvements to relphot, related support

Location:
trunk/Ohana/src/opihi
Files:
6 edited
2 copied

Legend:

Unmodified
Added
Removed
  • trunk/Ohana/src/opihi/cmd.data/Makefile

    r29938 r31450  
    141141$(SRC)/vpop.$(ARCH).o              \
    142142$(SRC)/vroll.$(ARCH).o             \
     143$(SRC)/vshift.$(ARCH).o            \
    143144$(SRC)/vsmooth.$(ARCH).o           \
    144145$(SRC)/vstats.$(ARCH).o            \
  • trunk/Ohana/src/opihi/cmd.data/gridify.c

    r20936 r31450  
    44
    55  int i, Nx, Ny, Xb, Yb, Normalize, N;
    6   float Xmin, Xmax, dX, Ymin, Ymax, dY;
     6  float Xmin, Xmax, dX, Ymin, Ymax, dY, initValue;
    77  float *buf, *val;
    88  int *Nval;
     
    1515    remove_argument (N, &argc, argv);
    1616    Normalize = FALSE;
     17  }
     18
     19  initValue = 0.0;
     20  if ((N = get_argument (argc, argv, "-init-value"))) {
     21    remove_argument (N, &argc, argv);
     22    initValue = atof(argv[N]);
     23    remove_argument (N, &argc, argv);
    1724  }
    1825
     
    6976  buf = (float *) bf[0].matrix.buffer;
    7077  for (i = 0; i < Nx*Ny; i++) {
     78    buf[i] = initValue;
    7179    if (Normalize) {
    7280      if (Nval[i] == 0) {
    73         buf[i] = 0;
    7481        continue;
    7582      }
  • trunk/Ohana/src/opihi/cmd.data/init.c

    r29938 r31450  
    130130int vstats           PROTO((int, char **));
    131131int vroll            PROTO((int, char **));
     132int vshift           PROTO((int, char **));
    132133int vpop             PROTO((int, char **));
    133134int vsmooth          PROTO((int, char **));
     
    274275  {1, "vmaxwell",     vmaxwell,         "fit a Maxwellian to a vector"},
    275276  {1, "vpop",         vpop,             "remove first element of a vector"},
    276   {1, "vroll",        vroll,            "roll vector elements"},
     277  {1, "vroll",        vroll,            "roll vector elements by 1 entry"},
     278  {1, "vshift",       vshift,           "shift vector elements by arbitrary amount"},
    277279  {1, "vsmooth",      vsmooth,          "Gaussian smooth of a vector"},
    278280  {1, "vstats",       vstats,           "statistics on a vector"},
  • trunk/Ohana/src/opihi/dvo/Makefile

    r27594 r31450  
    8080$(SRC)/mextract.$(ARCH).o               \
    8181$(SRC)/mmextract.$(ARCH).o              \
     82$(SRC)/objectcoverage.$(ARCH).o         \
    8283$(SRC)/photcodes.$(ARCH).o              \
    8384$(SRC)/pmeasure.$(ARCH).o               \
  • trunk/Ohana/src/opihi/dvo/avextract.c

    r30612 r31450  
    55  off_t i, j, n, m;
    66  int N, Npts, NPTS, last, next, state, Nfields, Nreturn, Ncstack, Nstack;
    7   int Nsecfilt, mode, VERBOSE;
     7  int Nsecfilt, mode, VERBOSE, needMeasures;
    88  char **cstack, name[1024];
    99  void *Signal;
     
    101101  }
    102102
     103  // check the requested fields : are all average/secfilt entries, or do we need measures?
     104  needMeasures = FALSE;
     105  for (i = 0; !needMeasures && (i < Nfields); i++) {
     106    if (fields[i].magMode == MAG_NONE) continue;
     107    if (fields[i].photcode == NULL) continue; // assert this?
     108    if (fields[i].photcode[0].type == PHOT_REF) needMeasures = TRUE;
     109    if (fields[i].photcode[0].type == PHOT_DEP) needMeasures = TRUE;
     110  }
     111
    103112  // grab data from all selected sky regions
    104113  Signal = signal (SIGINT, handle_interrupt);
     
    107116    /* lock, load, unlock catalog */
    108117    catalog.filename = skylist[0].filename[i];
    109     catalog.catflags = LOAD_AVES | LOAD_MEAS | LOAD_SECF;
     118    catalog.catflags = LOAD_AVES | LOAD_SECF;
     119    if (needMeasures) {
     120      catalog.catflags |= LOAD_MEAS;
     121    }
    110122    catalog.Nsecfilt = 0;
    111123
  • trunk/Ohana/src/opihi/dvo/init.c

    r27594 r31450  
    4040int lightcurve      PROTO((int, char **));
    4141int mextract        PROTO((int, char **));
    42 int mmextract        PROTO((int, char **));
     42int mmextract       PROTO((int, char **));
     43int objectcoverage  PROTO((int, char **));
    4344int pcat            PROTO((int, char **));
    4445int photcodes       PROTO((int, char **));
     
    9293  {1, "mextract",    mextract,     "extract measure data values"},
    9394  {1, "mmextract",   mmextract,    "extract joined measurements"},
     95  {1, "objectcoverage", objectcoverage, "plot catalog boundaries"},
    9496  {1, "pcat",        skycat,       "plot catalog boundaries"},
    9597  {1, "photcodes",   photcodes,    "list photometry codes"},
Note: See TracChangeset for help on using the changeset viewer.