IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Jan 20, 2008, 3:52:51 PM (18 years ago)
Author:
eugene
Message:

adding nebulous and chip/host relationships

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/eam_branch_20080109/ippTasks/summit.copy.pro

    r16149 r16171  
    77# pztool -adddatastore -inst allskycam -telescope ps1 -uri  http://otis1.ifa.hawaii.edu/ds/allskycam/index.txt
    88
    9 # XXX these things below need to be set in pantasks.pro, perhaps with a site-dependent call.
     9# the templates are used if we have a class_id/host relationship; if none is found, the default values are used
    1010# XXX not sure how to handle the .N value if we need to use more than one
    11 $workdir_template = /data/@HOST@.0/
     11if ($NEBULOUS)
     12 $workdir_default  = neb://
     13 $workdir_template = neb://
     14 $volume_default  = ipp004-v0
     15 $volume_template = @HOST@-v0
     16else
     17 $workdir_default  = /data/ipp004.0/
     18 $workdir_template = /data/@HOST@.0/
     19end
    1220
    1321$VERBOSE = 1
     
    267275
    268276        # we need to set the workdir based on 1) nebulous or not? 2) chip/host relationship
    269         set.workdir.by.camera $CAMERA $CLASS_ID /data/@HOST@.0
     277        # this function uses workdir_template, workdir_default, volume_template, volume_default,
     278        # it sets workdir and volume
     279        set.workdir.by.camera $CAMERA $CLASS_ID
    270280
    271281        # figure out filename
    272282        # XXXX this filename needs to use nebulous names
    273283        $FILENAME = $workdir/$CAMERA/$YEAR/$MONTH/$DAY/$EXP_NAME/$EXP_NAME.$CLASS_ID.fits
     284        $FILEROOT = $workdir/$CAMERA/$YEAR/$MONTH/$DAY/$EXP_NAME/$EXP_NAME.$CLASS_ID
    274285
    275286        book setword pzPendingImfile $pageName filename $FILENAME
     
    280291        # store the pageName with this job
    281292        options $pageName
    282 
    283         if ($MD5SUM == 0)
    284             $run = dsget --uri $URI --filename $FILENAME --bytes $BYTES
    285         else
    286             $run = dsget --uri $URI --filename $FILENAME --bytes $BYTES --md5 $MD5SUM
     293        options $FILEROOT
     294
     295        $run = dsget --uri $URI --filename $FILENAME --bytes $BYTES
     296        if ($MD5SUM)
     297            $run = $run --md5 $MD5SUM
     298        end
     299        if ($NEBULOUS && ("$volname" != "NULL"))
     300            $run = $run --volume $volume
    287301        end
    288302
     
    304318        book getword pzPendingImfile $options:0 filename -var FILENAME
    305319
     320        # we need to set the values of tess_id, dvodb, end_stage, workdir here
     321        # these are functions of (at least) EXP_TYPE and SURVEY_ID, both of which should come from the data store
     322
    306323        # update the database with the success
    307         $run = pztool -copydone -exp_name $EXP_NAME -inst $CAMERA -telescope $TELESCOPE -class $CLASS -class_id $CLASS_ID -uri $FILENAME
     324        $run = pztool -copydone -exp_name $EXP_NAME -inst $CAMERA -telescope $TELESCOPE -class $CLASS -class_id $CLASS_ID -uri $FILENAME -workdir $options:1
     325        # tess_id, dvodb, workdir, end_stage
    308326
    309327        # create the command line
Note: See TracChangeset for help on using the changeset viewer.