Changeset 8560


Ignore:
Timestamp:
06/15/07 13:08:49 (17 years ago)
Author:
Daniela Dorner
Message:
*** empty log message ***
Location:
trunk/MagicSoft/Mars
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/Changelog

    r8557 r8560  
    1818
    1919                                                 -*-*- END OF LINE -*-*-
     20
     21 2007/06/15 Daniela Dorner
     22
     23   * datacenter/db/index-footer.html:
     24     - adapted path of validator picture
     25
     26   * scripts/processsequence:
     27     - added sequence number (get it from sequence file) to path name
     28       in case only a sequence file is given
     29     - added two new command line options: the callisto and star rc can
     30       be given now
     31
     32
    2033
    2134 2007/06/14 Daniela Dorner
  • trunk/MagicSoft/Mars/scripts/processsequence

    r8557 r8560  
    4242#to be set by the user (if you don't use the command-line options)
    4343#path of your output directory
    44 #outpath=/home/dorner/ToO
    45 outpath=
     44outpath=""
    4645#give either sequence number or sequence file (including path)
    47 sequence=
     46sequence=""
    4847sequfile=""
    4948
     
    6059   echo -n "  -cal                   "
    6160   echo " running only calibration"
    62    echo -n "  --cal-rc                   "
    63    echo " giving the rc-file used for the calibration "
     61   echo -n "  --cal-rc               "
     62   echo " giving a differnt callisto rc file"
     63   echo -n "  --star-rc              "
     64   echo " giving a differnt star rc file"
    6465   echo -n "  -b                     "
    6566   echo " running in non-interactive mode (i.e. you are not asked if the paths are ok)"
     
    105106interactive="yes"
    106107
     108# get options from the command line
    107109while [ "$1" ]
    108110do
     
    111113                    sequence=$1
    112114                    ;;
    113          --cal-rc)  shift
    114                     calrc="--config="$1
    115                     ;;
    116115            --out)  shift
    117116                    outpath=$1
     
    126125                    sequfile=$1
    127126                    ;;
     127        --star-rc)  shift
     128                    starrc=$1
     129                    ;;
     130         --cal-rc)  shift
     131                    calrc=$1
     132                    ;;
    128133               -h)  usage
    129134                    ;;
    130       *)      echo "unknown option $1 "
    131               usage
    132               exit
    133               ;;
     135                *)  echo "unknown option $1 "
     136                    usage
     137                    ;;
    134138   esac
    135139   shift
     
    154158echo " outpath:  "$outpath
    155159
     160# get sequence file and number
    156161if [ "$sequfile" = "" ]
    157162then
     
    166171   echo " sequence: "$sequence
    167172   echo " sequfile: "$sequfile
    168 #   if ! [ "$star" = "yes" ] || [ "$cal" = "yes" ]
    169 #   then
    170       calpath=$outpath"/callisto/$n8"
    171       echo " path where calibration files are stored : "$calpath
    172 #   fi
    173    if ! [ "$cal" = "yes" ] || [ "$star" = "yes" ]
    174    then
    175       starpath=$outpath"/star/$n8"
    176       echo " path where star files are stored        : "$starpath
    177    fi
    178173else
    179174   echo " sequfile: "$sequfile
    180 #   if ! [ "$star" = "yes" ] || [ "$cal" = "yes" ]
    181 #   then
    182       calpath=$outpath"/callisto"
    183       echo " path where calibration files are stored : "$calpath
    184 #   fi
    185    if ! [ "$cal" = "yes" ] || [ "$star" = "yes" ]
    186    then
    187       starpath=$outpath"/star"
    188       echo " path where star files are stored        : "$starpath
    189    fi
    190 fi
     175   # get sequence number from file (for path and log names)
     176   array=( `grep "Sequence: " $sequfile` )
     177   n8=`printf %08d ${array[1]}`
     178fi
     179
     180# define outpaths for callisto and star
     181calpath=$outpath"/callisto/$n8"
     182echo " path where calibration files are stored : "$calpath
     183if ! [ "$cal" = "yes" ] || [ "$star" = "yes" ]
     184then
     185   starpath=$outpath"/star/$n8"
     186   echo " path where star files are stored        : "$starpath
     187fi
     188
     189# rcfiles
    191190if ! [ "$calrc" = "" ]
    192 then
    193    echo "using $calrc for calibration"
    194 fi
    195 
    196 
     191then
     192   echo "You chose a different callisto rc file: $calrc "
     193fi
     194if ! [ "$starrc" = "" ]
     195then
     196   echo "You chose a different star rc file: $starrc "
     197fi
     198
     199# interactive mode
     200#  user is asked if paths are correct
    197201if [ "$interactive" = "yes" ]
    198202then
     
    214218fi
    215219
    216 
     220# calibrate sequence
    217221if ! [ "$star" = "yes" ] || [ "$cal" = "yes" ]
    218222then
     
    221225   program=callisto
    222226   echo "run $program..."
    223    logfile=$calpath/$program$sequence.log
    224    command="./$program -b -q -f -v5 --log=$logfile --out=$calpath $calrc $sequfile "
     227   logfile=$calpath/$program$n8.log
     228   command="./$program -b -q -f --log=$logfile --out=$calpath "
     229   if ! [ "$calrc" = "" ]
     230   then
     231      command=$command" --config=$calrc "
     232   fi
     233   command=$command" $sequfile "
    225234   echo $command
    226235   $command
     
    280289      program=merppccupdate
    281290      logfile=$merpplogpath/$program$runno.log
    282       command="./merpp -u -v5 --log=$logfile --runfile=$runno $ccfile $calfile "
     291      command="./merpp -u --log=$logfile --runfile=$runno $ccfile $calfile "
    283292      echo $command
    284293      $command
     
    288297      program=merppcacoupdate
    289298      logfile=$merpplogpath/$program$runno.log
    290       command="./merpp -u -v5 --log=$logfile --auto-time $cacofile $calfile"
     299      command="./merpp -u --log=$logfile --auto-time $cacofile $calfile"
    291300      echo $command
    292301      $command
     
    299308fi
    300309
     310# run star for sequence
    301311if ! [ "$cal" = "yes" ] || [ "$star" = "yes" ]
    302312then
     
    305315   program=star
    306316   echo "run $program..."
    307    logfile=$starpath/$program$sequence.log
    308    if ! ls $calpath
     317   logfile=$starpath/$program$n8.log
     318   command="./$program -b -q -f --log=$logfile --out=$starpath "
     319   if ls $calpath >/dev/null 2>&1
    309320   then
    310       echo "couldn't find $calpath => taking standard inpath for $program"
    311       command="./$program -b -q -f -v5 --log=$logfile --out=$starpath $sequfile"
    312       echo $command
    313       $command
    314    else
    315       command="./$program -b -q -f -v5 --log=$logfile --ind=$calpath --out=$starpath $sequfile"
    316       echo $command
    317       $command
     321      command=$command"--ind=$calpath "
    318322   fi
     323   if ! [ "$starrc" = "" ]
     324   then
     325      command=$command" --config=$starrc "
     326   fi
     327   command=$command" $sequfile"
     328   echo $command
     329   $command
    319330   check=$?
    320331   checkreturncode
Note: See TracChangeset for help on using the changeset viewer.