IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Nov 27, 2019, 11:22:02 AM (7 years ago)
Author:
eugene
Message:

extend cut function to apply alternate stats to the output vector; extend extract to allow source region to fall beyond bounds of input image; add commands antialias, kapamemory, match1d, mgaussdev, vsigmoid (fit a sigmoid), virls (irls on vector), vwtmean (weighted mean), vtransitions; extend medimage to report variance; fix error in rotate; update some tests; add vgauss -apply option

File:
1 edited

Legend:

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

    r40574 r41164  
    3232  }
    3333
    34   /* option generate a FITS output table */
     34  // option generate a FITS output table (FITS holds the filename)
     35  // in FITS output context, -header is interpretted as a buffer containing
     36  // header keywords to supplement the FITS table header
    3537  char *FITS = NULL;
     38  Header *fitsheader = NULL;
     39  Buffer *headbuffer = NULL;
    3640  if ((N = get_argument (argc, argv, "-fits"))) {
    3741    remove_argument (N, &argc, argv);
    3842    FITS = strcreate (argv[N]);
    3943    remove_argument (N, &argc, argv);
    40   }
    41 
     44
     45    if ((N = get_argument (argc, argv, "-header"))) {
     46      remove_argument (N, &argc, argv);
     47      if ((headbuffer = SelectBuffer (argv[N], OLDBUFFER, TRUE)) == NULL) return (FALSE);
     48      fitsheader = &headbuffer->header;
     49      remove_argument (N, &argc, argv);
     50    }
     51  }
     52 
    4253  /* option generate a FITS output table */
    4354  int CSV = FALSE;
     
    124135
    125136  if (FITS) {
    126     int status = WriteVectorTableFITS (argv[1], FITS, vec, Nvec, append, compress, format, Ntile);
     137    int status = WriteVectorTableFITS (argv[1], FITS, fitsheader, vec, Nvec, append, compress, format, Ntile);
    127138    free (vec);
    128139    return status;
     
    260271    gprint (GP_ERR, "  -append : write to the end of the existing file\n");
    261272    gprint (GP_ERR, "  -fits NAME : write a fits table (extention name is NAME, column names match vector names)\n");
     273    gprint (GP_ERR, "     in FITS output context, -header takes an additional argument which is interpretted\n");
     274    gprint (GP_ERR, "     as a buffer containing header keywords to supplement the FITS table header\n");
    262275    gprint (GP_ERR, "  -csv : write a comma-separated values file (eg, to read in excel)\n");
    263276    gprint (GP_ERR, "  -f \"format\" : provide formatting codes for output:\n");
Note: See TracChangeset for help on using the changeset viewer.