IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 35708


Ignore:
Timestamp:
Jun 24, 2013, 8:44:02 PM (13 years ago)
Author:
eugene
Message:

save duplicates to text files

Location:
branches/eam_branches/ipp-20130509/Ohana/src/uniphot
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • branches/eam_branches/ipp-20130509/Ohana/src/uniphot/include/ckids.h

    r35706 r35708  
    3333int           update_dvo_ckids_parallel         PROTO((SkyList *sky));
    3434                                                   
    35 void          update_catalog_ckids              PROTO((Catalog *catalog));
     35void          update_catalog_ckids              PROTO((Catalog *catalog, FILE *foutput));
  • branches/eam_branches/ipp-20130509/Ohana/src/uniphot/src/initialize_ckids.c

    r35706 r35708  
    108108
    109109  UPDATE = FALSE;
    110   if ((N = get_argument (argc, argv, "-update"))) {
    111     remove_argument (N, &argc, argv);
    112     UPDATE = TRUE;
    113   }
     110  // XXX do not allow update until we have added a modification concept
     111  // if ((N = get_argument (argc, argv, "-update"))) {
     112  //   remove_argument (N, &argc, argv);
     113  //   UPDATE = TRUE;
     114  // }
    114115
    115116  if (argc != 1) usage_ckids();
     
    164165
    165166  UPDATE = FALSE;
    166   if ((N = get_argument (argc, argv, "-update"))) {
    167     remove_argument (N, &argc, argv);
    168     UPDATE = TRUE;
    169   }
     167  // if ((N = get_argument (argc, argv, "-update"))) {
     168  //   remove_argument (N, &argc, argv);
     169  //   UPDATE = TRUE;
     170  // }
    170171
    171172  SINGLE_CPT = NULL;
  • branches/eam_branches/ipp-20130509/Ohana/src/uniphot/src/update_catalog_ckids.c

    r35706 r35708  
    22void sort_fullIDs (uint64_t *I, int *S, off_t N);
    33
    4 void update_catalog_ckids (Catalog *catalog) {
     4void update_catalog_ckids (Catalog *catalog, FILE *foutput) {
    55
    66  // I am looking for duplicate detections based on the image ID + detection ID values
     
    5858    off_t j = seq[i];
    5959    off_t N = measure[j].averef;
    60     fprintf (stderr, "duplicate entry "OFF_T_FMT" : 0x%08x 0x%08x : 0x%08x : %10.6f %10.6f\n", j, measure[j].imageID, measure[j].detID, measure[j].objID, average[N].R, average[N].D);
     60    fprintf (foutput, "0x%08x 0x%08x %8.4f %8.4f %5d\n", measure[j].imageID, measure[j].detID, average[N].R, average[N].D, measure[j].photcode);
    6161  }
     62  free (fullID);
     63  free (seq);
     64  free (duplicates);
    6265
    6366  return;
  • branches/eam_branches/ipp-20130509/Ohana/src/uniphot/src/update_dvo_ckids.c

    r35706 r35708  
    2323    update_dvo_ckids_parallel (skylist);
    2424    return TRUE;
     25  }
     26
     27  char filename[256];
     28  snprintf (filename, 256, "dvo.ckimids.%02d.dat", HOST_ID);
     29  FILE *foutput = fopen (filename, "w");
     30  if (!foutput) {
     31    fprintf (stderr, "failed to open output file %s\n", filename);
     32    exit (3);
    2533  }
    2634
     
    5260    }
    5361
    54     update_catalog_ckids (&catalog);
     62    update_catalog_ckids (&catalog, foutput);
    5563
    5664    if (!UPDATE) {
     
    6674    dvo_catalog_free (&catalog);
    6775  }
     76  fclose (foutput);
    6877
    6978  return (TRUE);
Note: See TracChangeset for help on using the changeset viewer.