IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Nov 8, 2010, 6:20:37 PM (16 years ago)
Author:
eugene
Message:

add the ability to read a broken fits table (pad the missing areas); adjust dvorepair to count missing detections per image

Location:
branches/eam_branches/ipp-20101103/Ohana/src/opihi/cmd.data
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/eam_branches/ipp-20101103/Ohana/src/opihi/cmd.data/rd.c

    r28241 r29714  
    184184    ftable.header[0].buffer = NULL;
    185185    gfits_copy_header (&buf[0].header, ftable.header);
    186     status = gfits_fread_ftable_data (f, &ftable);  // this just reads the bytes (not even a SWAP)
     186    status = gfits_fread_ftable_data (f, &ftable, FALSE);  // this just reads the bytes (not even a SWAP)
    187187    status = gfits_uncompress_image (&buf[0].header, &buf[0].matrix, &ftable);
    188188    // uncompressing the image leaves the format as an extension
  • branches/eam_branches/ipp-20101103/Ohana/src/opihi/cmd.data/read_vectors.c

    r29540 r29714  
    160160
    161161  off_t Nbytes;
    162   int i, j, k, N, Nextend, Ny, Binary, vecType;
     162  int i, j, k, N, Nextend, Ny, Binary, vecType, padIfShort;
    163163  char type[16], ID[80], *CCDKeyword;
    164164  FTable table;
     
    174174    CCDKeyword = strcreate (argv[N]);
    175175    remove_argument (N, &argc, argv);
     176  }
     177
     178  padIfShort = FALSE;
     179  if ((N = get_argument (argc, argv, "-pad-if-short"))) {
     180    remove_argument (N, &argc, argv);
     181    padIfShort = TRUE;
    176182  }
    177183
     
    205211    }
    206212    if (!gfits_load_header (f, &header)) ESCAPE ("error reading header for extension");
    207     if (!gfits_fread_ftable_data (f, &table)) ESCAPE ("error reading table for extension");
     213    if (!gfits_fread_ftable_data (f, &table, padIfShort)) ESCAPE ("error reading table for extension");
    208214
    209215  } else {
     
    236242        continue;
    237243      }
    238       if (!gfits_fread_ftable_data (f, &table)) ESCAPE ("error reading table for extension");
     244      if (!gfits_fread_ftable_data (f, &table, padIfShort)) ESCAPE ("error reading table for extension");
    239245      break;
    240246    }
Note: See TracChangeset for help on using the changeset viewer.