Go to the list of seismic processes.
Go to SIOSEIS introduction.
The first time through, I tested the script by typing:
vpick gathers.day068-0000z 1000
#! /bin/csh -f
setenv DISPLAY sioseis:0.0 # CHANGE THIS FOR YOUR MACHINE!
#setenv DISPLAY 137.110.27.105:0.0
if( $#argv < 2 ) then
echo "Usage: vpick filename start_rpnum [ rpnum_inc end_rpnum]"
exit 1
endif
set FILE = $1
set MATFILE = vpick.mat # must terminate with .mat for Matlab
set VPICKFILE = $FILE.vpick
set START_RPNUM = $2
if( $#argv < 3 ) then
set RPNUM_INC = 1
else
set RPNUM_INC = $3
endif
if( $#argv < 4 ) then
set END_RPNUM = $START_RPNUM
else
set END_RPNUM = $4
endif
set rpnum = $START_RPNUM
while ( $rpnum <= $END_RPNUM )
sioseis << eof
noecho procs diskin agc plot velan prout END
diskin
secs 3 fno $rpnum lno $rpnum forgat 1 # make shot num = rp num
ipath $FILE END END
agc
winlen .5 END END
prout
fno 0 lno 99999 ftr 0 ltr 99999 END
END
velan
vels 1400 20 3000 nrp 1 type spec winlen .048 opath $MATFILE
END
END
plot
nibs 75 nsecs 3 scalar -1 trpin 10 vscale 2.5 def 0.06
srpath sunfil ftag 1 taginc 1000 ann fanno fanno $rpnum END
END
END
eof
xloadimage -r 90 sunfil &
# Use Matlab Version 4.2c (Nov 23 1994) or newer or else change
# getline to ginput, which does not have a line connecting the picks.
matlab5.1 << eof1
load vpick;
n = size(vel);nt = n(1);nv = n(2);
rpno = vel(1,1);st = vel(2,1);dt = vel(3,1);sv = vel(4,1);dv = vel(5,1);
vel(1,1) = 0;vel(2,1) = 0;vel(3,1) = 0;vel(4,1) = 0;vel(5,1) = 0;
x = sv:dv:sv+nv*dv-dv;
y = -st:-dt:-(st+nt*dt-dt);
contour(x,y,vel,10)
title 'rp $rpnum';
[x,y] = getline;
pause
n = size(x);
fprintf('$VPICKFILE',' fno %.0f vtp ',$rpnum)
for i = 1:n(1)
fprintf('$VPICKFILE','%.0f %.3f ',x(i),-y(i))
end
fprintf('$VPICKFILE','end\n')
quit
eof1
@ rpnum = $rpnum + $RPNUM_INC
end
#rm $MATFILE