Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2026-04-09 07:49:17

0001 #!/usr/bin/env bash
0002 usage(){ cat << EOU
0003 
0004 ~/o/sysrap/tests/SEvt__createInputGenstep_configuredTest.sh
0005 
0006 EOU
0007 }
0008 
0009 cd $(dirname $(realpath $BASH_SOURCE))
0010 
0011 name=SEvt__createInputGenstep_configuredTest
0012 which $name
0013 
0014 defarg="info_run_ls"
0015 arg=${1:-$defarg}
0016 
0017 vv="BASH_SOURCE PWD defarg arg FOLD"
0018 
0019 
0020 # see cxs_min.sh for source to config examples
0021 export OPTICKS_RUNNING_MODE=SRM_TORCH
0022 export storch_FillGenstep_type=sphere
0023 export storch_FillGenstep_radius=100    # +ve for outwards
0024 export storch_FillGenstep_pos=0,0,0
0025 export storch_FillGenstep_distance=1.00 # frac_twopi control of polarization phase(tangent direction)
0026 
0027 
0028 export OPTICKS_EVENT_MODE=Hit
0029 export OPTICKS_HIT_MASK=EC
0030 export OPTICKS_NUM_PHOTON=M1   ## HUH : NO EFFECT : GETTING 100 photons only
0031 export OPTICKS_NUM_EVENT=1
0032 export OPTICKS_NUM_GENSTEP=1
0033 
0034 
0035 tmp=/tmp/$USER/opticks
0036 TMP=${TMP:-$tmp}
0037 export FOLD=$TMP/SEvt__createInputGenstep_configuredTest
0038 
0039 
0040 if [ "${arg/info}" != "$arg" ]; then
0041    for v in $vv ; do printf "%30s : %s\n" "$v" "${!v}" ; done
0042 fi
0043 
0044 if [ "${arg/run}" != "$arg" ]; then
0045    $name
0046    [ $? -ne 0 ] && echo $BASH_SOURCE - run ERROR && exit 1
0047 fi
0048 
0049 if [ "${arg/dbg}" != "$arg" ]; then
0050    source dbg__.sh
0051    dbg__ $name
0052    [ $? -ne 0 ] && echo $BASH_SOURCE - dbg ERROR && exit 2
0053 fi
0054 
0055 if [ "${arg/ls}" != "$arg" ]; then
0056    ls -alst $FOLD
0057 fi
0058 
0059 exit 0
0060 
0061