IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 36530


Ignore:
Timestamp:
Feb 18, 2014, 2:45:31 PM (12 years ago)
Author:
eugene
Message:

fixing some run-time errors in relphot parallel

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

Legend:

Unmodified
Added
Removed
  • branches/eam_branches/ipp-20140206/Ohana/src/libdvo/src/RegionHostTable.c

    r36520 r36530  
    124124   
    125125    table->Rmin = MIN(Rmin, table->Rmin);
    126     table->Rmax = MIN(Rmax, table->Rmax);
     126    table->Rmax = MAX(Rmax, table->Rmax);
    127127    table->Dmin = MIN(Dmin, table->Dmin);
    128     table->Dmax = MIN(Dmax, table->Dmax);
     128    table->Dmax = MAX(Dmax, table->Dmax);
    129129
    130130    // InitIOBuffer (&hosts[Nhosts].stdout, 1000);
  • branches/eam_branches/ipp-20140206/Ohana/src/relphot/src/args.c

    r36519 r36530  
    381381  }
    382382
    383   if ((mode == UPDATE_AVERAGES) && (argc != 1)) relphot_usage ();
    384   if (mode == UPDATE_IMAGES) {
    385     PhotcodeList = strcreate (argv[1]);
    386     photcodes = ParsePhotcodeList (PhotcodeList, &Nphotcodes, TRUE); // require SEC photcodes
    387     remove_argument (1, &argc, argv);
     383  switch (mode) {
     384    case UPDATE_AVERAGES:
     385      if (argc != 1) relphot_usage();
     386      break;
     387     
     388    case UPDATE_IMAGES:
     389    case PARALLEL_IMAGES:
     390    case PARALLEL_REGIONS:
     391      PhotcodeList = strcreate (argv[1]);
     392      photcodes = ParsePhotcodeList (PhotcodeList, &Nphotcodes, TRUE); // require SEC photcodes
     393      remove_argument (1, &argc, argv);
     394      break;
     395
     396    default:
     397      fprintf (stderr, "no valid mode selected\n");
     398      relphot_usage();
     399      break;
    388400  }
    389401  if (argc != 1) relphot_usage ();
  • branches/eam_branches/ipp-20140206/Ohana/src/relphot/src/assign_images.c

    r36520 r36530  
    6565   
    6666    // this adds 1.3 sec for 3M images
    67     if (!FindMosaicForImage (image, Nimage, i)) {
     67    if (!FindMosaicForImage (image, Nimage, j)) {
    6868      if (VERBOSE2) fprintf (stderr, "cannot find mosaic for "OFF_T_FMT"\n", i);
    6969      continue;
     
    8686
    8787    i = find_host_for_coords (regionHosts, Rc, Dc);
     88
    8889    if (i == -1) continue;
    8990
     
    100101    }
    101102  }
     103
    102104  return TRUE;
    103105}
  • branches/eam_branches/ipp-20140206/Ohana/src/relphot/src/launch_region_hosts.c

    r36519 r36530  
    2727    // subset images per host : CATDIR/Image.HOSTNAME.fits
    2828    char filename[1024];
    29     snprintf (filename, 1024, "%s/Image.%s.fits", CATDIR, host->hostname);
     29    snprintf (filename, 1024, "%s/Image.%d.fits", CATDIR, host->hostID);
    3030
    3131    // write the image subset for this host
     
    3333
    3434    char command[1024];
    35     snprintf (command, 1024, "relphot -parallel-images %s -region-hosts %s -region-hostID %d -D CATDIR %s -region %f %f %f %f -statmode %s -D CAMERA %s -D STAR_TOOFEW %d -minerror %f",
    36               filename, REGION_FILE, host->hostID, CATDIR, host->Rmin, host->Rmax, host->Dmin, host->Dmax, STATMODE, CAMERA, STAR_TOOFEW, MIN_ERROR);
     35    snprintf (command, 1024, "relphot %s -parallel-images %s -region-hosts %s -region-hostID %d -D CATDIR %s -region %f %f %f %f -statmode %s -D CAMERA %s -D STAR_TOOFEW %d -minerror %f",
     36              PhotcodeList, filename, REGION_FILE, host->hostID, CATDIR, host->Rmin, host->Rmax, host->Dmin, host->Dmax, STATMODE, CAMERA, STAR_TOOFEW, MIN_ERROR);
    3737
    3838    if (VERBOSE)       strextend (command, "-v");
Note: See TracChangeset for help on using the changeset viewer.