IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 37082


Ignore:
Timestamp:
Jul 17, 2014, 2:44:48 PM (12 years ago)
Author:
eugene
Message:

merge changes from trunk (updates from ops tag ipp-20130712)

Location:
tags/ipp-pv3-20140717
Files:
28 edited

Legend:

Unmodified
Added
Removed
  • tags/ipp-pv3-20140717

  • tags/ipp-pv3-20140717/Ohana/src/getstar

  • tags/ipp-pv3-20140717/Ohana/src/opihi/pcontrol/PclientCommand.c

    r27435 r37082  
    2525    return (PCLIENT_DOWN);
    2626  }
    27  
     27
    2828  // prepare host to accept response
    2929  host[0].response_state = response_state;
     
    3535  return (PCLIENT_GOOD);
    3636}
    37  
     37
    3838// check for response; message must end with specified string.
    3939// accumulate the response in the buffer
     
    4747  ASSERT (response != NULL, "response missing");
    4848  ASSERT (buffer != NULL, "buffer missing");
     49
     50  // INITTIME;
    4951
    5052  /* avoid blocking very long on read, test every 100 usec, up to 0.1 sec */
     
    6668    return (PCLIENT_DOWN);
    6769  }
    68   if (line == NULL) return (PCLIENT_HUNG);
    69   if (status == -1) return (PCLIENT_HUNG);
     70  if (line == NULL) {
     71      // MARKTIME ("-- client hung (line NULL): %s : %f sec\n", host[0].hostname, dtime);
     72      return (PCLIENT_HUNG);
     73  }
     74  if (status == -1) {
     75      // MARKTIME ("-- client hung (status -1): %s : %f sec\n", host[0].hostname, dtime);
     76      return (PCLIENT_HUNG);
     77  }
    7078
    7179  // fprintf (stderr, "response: %s\n", buffer[0].buffer);
     
    7583
    7684/* memstr returns a view, not an allocated string : don't free */
    77 /* ReadtoIOBuffer returns : 
     85/* ReadtoIOBuffer returns :
    7886    0 - pipe closed
    7987   -1 - no more data in pipe, data not ready
  • tags/ipp-pv3-20140717/ippScripts/scripts/dist_bundle.pl

    r36555 r37082  
    6767                      );
    6868my %empty_cleaned = ();
    69 
    70 
    7169
    7270# Look for programs we need
     
    496494    } elsif ($stage eq "stack") {
    497495        $type = $stack_cleaned{$rule};
    498     } elsif ($stage eq "sky" or $stage eq 'skycal' or $stage eq 'stack_summary' or $stage eq 'ff') {
     496    } elsif ($stage eq "sky" or $stage eq "skycal" or $stage eq "stack_summary" or $stage eq "ff") {
    499497        $type = $empty_cleaned{$rule};
    500498    } else {
  • tags/ipp-pv3-20140717/ippScripts/scripts/ipp_apply_burntool_single.pl

    r36839 r37082  
    4545    defined $dbname;
    4646
    47 # unless (defined $camera) {
    48 #    $camera = "GPC1";
    49 # }
     47# XXX watch out for TC3 and GPC2 here:
     48unless (defined $camera) {
     49    if ($this_uri =~ /ota/) {
     50        $camera = "GPC1";
     51    }
     52 }
    5053
    5154my $missing_tools;
  • tags/ipp-pv3-20140717/ippScripts/scripts/lap_science.pl

    r36529 r37082  
    189189    $chip_cmd .= " -set_label $exposure->{label} -set_data_group $data_group ";
    190190    $chip_cmd .= " -set_workdir $workdir -set_dist_group $exposure->{dist_group} ";
    191     $chip_cmd .= " -set_reduction LAP_SCIENCE ";
     191#    $chip_cmd .= " -set_reduction LAP_SCIENCE ";
     192    $chip_cmd .= " -set_reduction LAP_POLE ";
    192193
    193194    my ($success, $error_code, $full_buf, $stdout_buf, $stderr_buf ) =
  • tags/ipp-pv3-20140717/ippScripts/scripts/queuestaticsky.pl

  • tags/ipp-pv3-20140717/ippScripts/scripts/register_imfile.pl

    r36498 r37082  
    348348        $apply_command .= " --imfile_state $burntool_data->{imfile_state} ";
    349349        $apply_command .= " --verbose " if $verbose;
     350
     351        # TEMPORARY
     352        $apply_command .= " --camera GPC1";
    350353        print "$apply_command\n";
    351354        unless ($no_update) {
  • tags/ipp-pv3-20140717/ippScripts/scripts/warp_skycell.pl

    r36529 r37082  
    413413                unless ($success) {
    414414                    $error_code = (($error_code >> 8) or $PS_EXIT_PROG_ERROR);
    415                     warn("Unable to perform warptool -addwarped: $error_code\n");
     415                    warn("Unable to perform warptool -tofullskyfile: $error_code\n");
    416416                    exit($error_code) if $try >= 2;
    417417                    sleep 10;
  • tags/ipp-pv3-20140717/ippTasks/diff.pro

    r35916 r37082  
    6161  end
    6262  task diff.revert
     63    active false
     64  end
     65end
     66
     67macro diff.summary.on
     68  task diff.summary.load
     69    active true
     70  end
     71  task diff.summary.run
     72    active true
     73  end
     74end
     75
     76macro diff.summary.off
     77  task diff.summary.load
     78    active false
     79  end
     80  task diff.summary.run
    6381    active false
    6482  end
     
    125143    add_poll_args run
    126144    add_poll_labels run
     145    # increase the poll limit for warp over the default to
     146    # help it keep up with chip processing
     147    # NOTE : it is not a problem for difftool to have multiple
     148    # -limit entries: the last one is used
     149    $run = $run -limit {$POLL_LIMIT * 2}
    127150    command $run
    128151  end
  • tags/ipp-pv3-20140717/ippTasks/ipphosts.mhpcc.config

    r34067 r37082  
    1818ipphosts METADATA
    1919  camera STR skycell
    20   count S32  30
     20  count S32  60
    2121  sky00 STR  stsci00.0
    2222  sky01 STR  stsci00.1
     
    4949  sky28 STR  stsci09.1
    5050  sky29 STR  stsci09.2
     51  sky30 STR  stsci10.0
     52  sky31 STR  stsci10.1
     53  sky32 STR  stsci10.2
     54  sky33 STR  stsci11.0
     55  sky34 STR  stsci11.1
     56  sky35 STR  stsci11.2
     57  sky36 STR  stsci12.0
     58  sky37 STR  stsci12.1
     59  sky38 STR  stsci12.2
     60  sky39 STR  stsci13.0
     61  sky40 STR  stsci13.1
     62  sky41 STR  stsci13.2
     63  sky42 STR  stsci14.0
     64  sky43 STR  stsci14.1
     65  sky44 STR  stsci14.2
     66  sky45 STR  stsci15.0
     67  sky46 STR  stsci15.1
     68  sky47 STR  stsci15.2
     69  sky48 STR  stsci16.0
     70  sky49 STR  stsci16.1
     71  sky50 STR  stsci16.2
     72  sky51 STR  stsci17.0
     73  sky52 STR  stsci17.1
     74  sky53 STR  stsci17.2
     75  sky54 STR  stsci18.0
     76  sky55 STR  stsci18.1
     77  sky56 STR  stsci18.2
     78  sky57 STR  stsci19.0
     79  sky58 STR  stsci19.1
     80  sky59 STR  stsci19.2
    5181END
    5282
  • tags/ipp-pv3-20140717/ippTasks/pantasks.pro

    r36500 r37082  
    645645    host anyhost
    646646  else
     647    # echo host $host
    647648    host $host
    648649  end
     
    655656  end
    656657
    657   local skycellID varname count host skyname skyhash
     658  local skycellID varname count host skyname skyhash fullhost
    658659  $skycellID = $1
    659660
     
    676677
    677678  # missing ipphosts table results in host = NULL
    678   book getword ipphosts skycell $skyname -var host
     679  book getword ipphosts skycell $skyname -var fullhost
     680  list word -splitbychar . $fullhost
     681  $host = $word:0
    679682
    680683  if ("$host" == "NULL")
    681684    host anyhost
    682685  else
     686    # echo host $host
    683687    host $host
    684688  end
  • tags/ipp-pv3-20140717/ippTasks/stack.pro

    r29732 r37082  
    7272    active false
    7373  end
     74  task stack.summary.load
     75    active false
     76  end
     77  task stack.summary.run
     78    active false
     79  end
     80end
     81
     82macro stack.summary.on
     83  task stack.summary.load
     84    active true
     85  end
     86  task stack.summary.run
     87    active true
     88  end
     89end
     90
     91macro stack.summary.off
    7492  task stack.summary.load
    7593    active false
  • tags/ipp-pv3-20140717/ippTasks/summit.copy.pro

    r36501 r37082  
    567567        command pztool -clearcommonfaults -dbname $DB:$pztoolClearFault_DB
    568568
     569        # loop over the multiple databases quickly, then pause for 5 min
    569570        $pztoolClearFault_DB ++
    570         if ($pztoolClearFault_DB >= $DB:n) set pztoolClearFault_DB = 0
     571        if ($pztoolClearFault_DB >= $DB:n)
     572          set pztoolClearFault_DB = 0
     573          periods -exec 300
     574        else
     575          periods -exec 30
     576        end
    571577      end
    572       periods -exec 1800
    573578    end
    574579
  • tags/ipp-pv3-20140717/ippTasks/survey.pro

    r35884 r37082  
    668668    end
    669669   
    670 #    echo $run
    671670    command $run
    672671  end
     
    752751    end
    753752   
    754 #    echo $run
    755753    command $run
    756754  end
     
    838836    end
    839837   
    840     # echo $run
    841838    command $run
    842839  end
     
    14371434  host local
    14381435 
    1439   periods      -poll $SURVEY_POLL
    1440   periods      -exec $SURVEY_EXEC
     1436  # we are going to use a long timeout (900 sec) between passes of the list
     1437  # and a short timeout (10 sec) while we are doing the full list
     1438  periods      -exec 10
     1439  periods      -poll 2
    14411440  periods      -timeout $SURVEY_TIMEOUT
    14421441  npending     1
     
    14491448    book npages SURVEY_PUBLISH -var N
    14501449    if ($N == 0)
    1451     # echo "No labels for processing"
     1450      # echo "No labels for processing"
    14521451      break
    14531452    endif
     1453
     1454    # short timeout while we have something to do
     1455    periods -exec 10
    14541456
    14551457    # survey.publish allows multiple entries per label.
     
    14651467      book getpage SURVEY_PUBLISH 0 -var tag -key STATE NEW
    14661468
    1467       # Select different database
    1468       $SURVEY_PUBLISH ++
    1469       if ($SURVEY_PUBLISH >= $DB:n) set SURVEY_PUBLISH = 0
     1469      # Select different database, set a long timeout
     1470      $SURVEY_PUBLISH_DB ++
     1471      if ($SURVEY_PUBLISH_DB >= $DB:n) set SURVEY_PUBLISH_DB = 0
     1472      periods -exec 900
     1473      date -var mytime
     1474      echo "done with publish list @ $mytime"
    14701475    end
    14711476
     
    14841489      option DEFAULT
    14851490    else
    1486       $run = $run -dbname $DB:$SURVEY_PUBLISH
    1487       option $DB:$SURVEY_PUBLISH
     1491      $run = $run -dbname $DB:$SURVEY_PUBLISH_DB
     1492      option $DB:$SURVEY_PUBLISH_DB
    14881493    end
    14891494   
    14901495    # echo $run
    1491 
    14921496    command $run
    14931497   
     
    18591863    end
    18601864   
    1861      echo $run
    18621865    command $run
    18631866  end
  • tags/ipp-pv3-20140717/ippTasks/warp.pro

    r35916 r37082  
    9999  end
    100100  task warp.revert.overlap
     101    active false
     102  end
     103end
     104
     105macro warp.summary.on
     106  task warp.summary.load
     107    active true
     108  end
     109  task warp.summary.run
     110    active true
     111  end
     112end
     113
     114macro warp.summary.off
     115  task warp.summary.load
     116    active false
     117  end
     118  task warp.summary.run
    101119    active false
    102120  end
     
    261279    add_poll_args run
    262280    add_poll_labels run
     281    # increase the poll limit for warp over the default to
     282    # help it keep up with chip processing
     283    # NOTE : it is not a problem for warptool to have multiple
     284    # -limit entries: the last one is used
     285    $run = $run -limit {$POLL_LIMIT * 2}
    263286    command $run
    264287  end
  • tags/ipp-pv3-20140717/ippTools/share/releasetool_definerelexp.sql

    r35213 r37082  
    1818
    1919WHERE previousrelexp.relexp_id IS NULL
     20    AND camRun.state = 'full'
  • tags/ipp-pv3-20140717/ippTools/src/releasetool.c

    r36046 r37082  
    780780
    781781    if (priority_order) {
    782         psStringAppend(&query, "\nAND priority > 0 order by exp_id, priority DESC");
     782        psStringAppend(&query, "\nAND priority > 0 ORDER BY exp_id, priority DESC");
     783    } else {
     784        psStringAppend(&query, "\nORDER BY exp_id, relexp_id DESC");
    783785    }
    784786
  • tags/ipp-pv3-20140717/ippconfig

  • tags/ipp-pv3-20140717/ippconfig/gpc1/psastro.config

    r37056 r37082  
    388388
    389389POLE_REFCAT METADATA
    390    PSASTRO.CATDIR               STR  SYNTH.GRIZY
     390   PSASTRO.CATDIR               STR  PS1.REF.20140713
    391391   ZERO.POINT.USE.MEAN               BOOL TRUE 
    392392   PSASTRO.GRID.MIN.ANGLE       F32  -20
  • tags/ipp-pv3-20140717/ippconfig/recipes/filerules-split.mdc

    r36838 r37082  
    306306                                                                                                             
    307307PPSUB.OUTPUT                 OUTPUT {OUTPUT}.fits                     IMAGE           NONE       FPA        TRUE      NONE
    308 PPSUB.OUTPUT.MASK            OUTPUT {OUTPUT}.mask.fits                MASK            COMP_MASK  FPA        TRUE      NONE
    309 PPSUB.OUTPUT.VARIANCE        OUTPUT {OUTPUT}.wt.fits                  VARIANCE        COMP_WT    FPA        TRUE      NONE
     308PPSUB.OUTPUT.MASK            OUTPUT {OUTPUT}.mask.fits                MASK            NONE       FPA        TRUE      NONE
     309PPSUB.OUTPUT.VARIANCE        OUTPUT {OUTPUT}.wt.fits                  VARIANCE        NONE       FPA        TRUE      NONE
    310310PPSUB.OUTPUT.SOURCES         OUTPUT {OUTPUT}.cmf                      CMF             NONE       FPA        TRUE      NONE
    311311PPSUB.OUTPUT.KERNELS         OUTPUT {OUTPUT}.subkernel                SUBKERNEL       NONE       FPA        TRUE      NONE
     
    314314PPSUB.OUTPUT.RESID.JPEG      OUTPUT {OUTPUT}.res.jpg                  JPEG            NONE       FPA        TRUE      NONE
    315315PPSUB.INVERSE                OUTPUT {OUTPUT}.inv.fits                 IMAGE           NONE       FPA        TRUE      NONE
    316 PPSUB.INVERSE.MASK           OUTPUT {OUTPUT}.inv.mask.fits            MASK            COMP_MASK  FPA        TRUE      NONE
    317 PPSUB.INVERSE.VARIANCE       OUTPUT {OUTPUT}.inv.wt.fits              VARIANCE        COMP_WT    FPA        TRUE      NONE
     316PPSUB.INVERSE.MASK           OUTPUT {OUTPUT}.inv.mask.fits            MASK            NONE       FPA        TRUE      NONE
     317PPSUB.INVERSE.VARIANCE       OUTPUT {OUTPUT}.inv.wt.fits              VARIANCE        NONE       FPA        TRUE      NONE
    318318PPSUB.INVERSE.SOURCES        OUTPUT {OUTPUT}.inv.cmf                  CMF             NONE       FPA        TRUE      NONE
    319319PPSUB.CONFIG                 OUTPUT {OUTPUT}.ppSub.mdc                TEXT            NONE       FPA        TRUE      NONE
  • tags/ipp-pv3-20140717/ippconfig/recipes/ppSub.config

  • tags/ipp-pv3-20140717/ippconfig/recipes/reductionClasses.mdc

    r37052 r37082  
    244244        ADDSTAR           STR     ADDSTAR
    245245        PSASTRO           STR     LAP_ASTRO
     246        STACKPHOT_PSPHOT  STR     STACKPHOT
     247        STACKPHOT_PPSUB   STR     STACKPHOT
     248        STACKPHOT_PPSTACK STR     STACKPHOT
     249        STACKPHOT_SINGLE_PSPHOT  STR     STACKPHOT_SINGLE
     250        BACKGROUND_PPBACKGROUND STR     BACKGROUND
     251        BACKGROUND_PSWARP       STR     BACKGROUND
     252        FULLFORCE_PSPHOT  STR   FULLFORCE_WARP
     253END
     254LAP_POLE                METADATA
     255        CHIP_PPIMAGE      STR     CHIP
     256        CHIP_PSPHOT       STR     CHIP
     257        WARP_PSWARP       STR     WARP
     258        STACK_PPSTACK     STR     STACK
     259        STACK_PPSUB       STR     STACK
     260        STACK_PSPHOT      STR     STACK
     261        DIFF_PPSUB        STR     DIFF
     262        DIFF_PSPHOT       STR     DIFF
     263        JPEG_BIN1         STR     PPIMAGE_J1
     264        JPEG_BIN2         STR     PPIMAGE_J2
     265        FAKEPHOT          STR     FAKEPHOT
     266        ADDSTAR           STR     ADDSTAR
     267        PSASTRO           STR     POLE_REFCAT
    246268        STACKPHOT_PSPHOT  STR     STACKPHOT
    247269        STACKPHOT_PPSUB   STR     STACKPHOT
     
    11721194
    11731195STS_DATASET_NOCOMPRESS METADATA
     1196        # XXX: don't use this recipe
    11741197   CHIP_PPIMAGE STR CHIP_NOCOMPRESS
    11751198   CHIP_PSPHOT STR CHIP
  • tags/ipp-pv3-20140717/ppSub/src/ppSubMatchPSFs.c

    r36581 r37082  
    167167    }
    168168
    169     // we need to register the FWHM values for use downstream 
     169    // we need to register the FWHM values for use downstream
    170170    pmSubtractionSetFWHMs(inFWHM, refFWHM);
    171171
     
    220220    bool noConvolve = psMetadataLookupBool(&mdok, recipe, "NOCONVOLVE"); // Do not use convolved images.
    221221    if (noConvolve) {
    222         psWarning("not matching PSFs because NOCONVOLVE is TRUE\n");
    223         return true;
     222        psWarning("not matching PSFs because NOCONVOLVE is TRUE\n");
     223        return true;
    224224    }
    225225
     
    235235        pmCell *cell = pmFPAfileThisCell(config->files, view, "PPSUB.INPUT.CONV"); // Cell for convolved input
    236236        inConv = pmReadoutAlloc(cell);
    237         psFree(inConv);
     237        psFree(inConv);
    238238    }
    239239    pmReadout *refConv = pmFPAfileThisReadout(config->files, view, "PPSUB.REF.CONV"); // Reference convolved
     
    241241        pmCell *cell = pmFPAfileThisCell(config->files, view, "PPSUB.REF.CONV"); // Cell for convolved ref.
    242242        refConv = pmReadoutAlloc(cell);
    243         psFree(refConv);
     243        psFree(refConv);
    244244    }
    245245
     
    269269        lists->data[0] = psMemIncrRefCounter(inSources);
    270270        lists->data[1] = psMemIncrRefCounter(refSources);
    271         // XXX MEH changed to get only match (true to cull single), no apparent need of unmatched sources and can cause trouble
     271        // XXX MEH changed to get only match (true to cull single), no apparent need of unmatched sources and can cause trouble
    272272        detections->allSources = pmSourceMatchMerge(lists, radius, true);
    273273        psFree(lists);
     
    365365        subMode = PM_SUBTRACTION_MODE_DUAL;
    366366    } else {
    367         char *convolveName = psMetadataLookupStr(&mdok, recipe, "CONVOLVE.TARGET"); // recipe value for target
     367        char *convolveName = psMetadataLookupStr(&mdok, recipe, "CONVOLVE.TARGET"); // recipe value for target
    368368        int convolve = psMetadataLookupS32(&mdok, config->arguments, "-convolve"); // override with command-line option
    369         switch (convolve) {
    370           case 0:
    371             // convolve is 0 if it is not supplied on the command line
    372             subMode = subModeFromString(convolveName);
    373             break;
    374           case 1:
    375             subMode = PM_SUBTRACTION_MODE_1;
    376             break;
    377           case 2:
    378             subMode = PM_SUBTRACTION_MODE_2;
    379             break;
    380           default:
    381             psError(PPSUB_ERR_ARGUMENTS, false, "Invalid value for -convolve");
    382             return false;
    383         }
     369        switch (convolve) {
     370          case 0:
     371            // convolve is 0 if it is not supplied on the command line
     372            subMode = subModeFromString(convolveName);
     373            break;
     374          case 1:
     375            subMode = PM_SUBTRACTION_MODE_1;
     376            break;
     377          case 2:
     378            subMode = PM_SUBTRACTION_MODE_2;
     379            break;
     380          default:
     381            psError(PPSUB_ERR_ARGUMENTS, false, "Invalid value for -convolve");
     382            return false;
     383        }
    384384    }
    385385
     
    397397        psKernel *truncated = psImageCovarianceTruncate(inRO->covariance, COVAR_FRAC);
    398398        psFree(inRO->covariance);
    399         inRO->covariance = truncated;
     399        inRO->covariance = truncated;
    400400    }
    401401    if (refRO->covariance) {
    402402        psKernel *truncated = psImageCovarianceTruncate(refRO->covariance, COVAR_FRAC);
    403403        psFree(refRO->covariance);
    404         refRO->covariance = truncated;
     404        refRO->covariance = truncated;
    405405    }
    406406
     
    458458            ppSubDataQuality(data, error, PPSUB_FILES_ALL);
    459459            return true;
     460        // XX } else if (error == PM_ERR_DATA) {
     461        // XX     psErrorStackPrint(stderr, "Unable to solve for the kernel to match images");
     462        // XX     psWarning("Failed to find PSF match kernel --- suspect bad data quality.");
     463        // XX     ppSubDataQuality(data, error, PPSUB_FILES_ALL);
     464        // XX     return true;
    460465        } else {
    461466            psError(PPSUB_ERR_DATA, false, "Unable to match images.");
     
    515520        psKernel *truncated = psImageCovarianceTruncate(inConv->covariance, COVAR_FRAC);
    516521        psFree(inConv->covariance);
    517         inConv->covariance = truncated;
     522        inConv->covariance = truncated;
    518523    }
    519524    if (refConv->covariance) {
    520525        psKernel *truncated = psImageCovarianceTruncate(refConv->covariance, COVAR_FRAC);
    521526        psFree(refConv->covariance);
    522         refConv->covariance = truncated;
     527        refConv->covariance = truncated;
    523528    }
    524529
  • tags/ipp-pv3-20140717/pstamp/scripts/pstamp_checkdependent.pl

  • tags/ipp-pv3-20140717/pstamp/scripts/pstamp_finish.pl

  • tags/ipp-pv3-20140717/pstamp/scripts/pstamp_insert_request.pl

    r36594 r37082  
    119119}
    120120
    121 my $datestr = strftime "%Y%m%d", gmtime;
     121# put file in directory for the current date
     122my $datestr = strftime "%Y/%m/%d", gmtime;
    122123my $datedir = "$workdir/webreq/$datestr";
    123124if (! -e $datedir ) {
    124     if (!  mkdir $datedir ) {
    125         print STDERR  "failed to create working directory $datedir";
     125    my $rc = system "mkdir -p $datedir";
     126    if ($rc) {
     127        my $status = $rc >> 8;
     128        print STDERR  "failed to create working directory $datedir: $rc $status";
    126129        exit $PS_EXIT_CONFIG_ERROR;
    127130    }
    128131}
     132
    129133
    130134my $webreq_num = get_webreq_num();
  • tags/ipp-pv3-20140717/pstamp/scripts/pstampparse.pl

Note: See TracChangeset for help on using the changeset viewer.