In [7]:
using Seismic, PyPlot
# Shows patching and unpatching untility. It breaks data into windows (Patches) and then puts them
# back without altering the orignal data. It is used for window-based processing such as FX deconv, SSA denoising
# and presstack interpolation/reconstriction.
In [8]:
param2 = Dict(:style=>"mxmyhaz", :min_imx=>10,:max_imx=>100, :min_imy=>35, :max_imy=>45,
:min_ih=>1, :max_ih=>6, :min_iaz=>0, :max_iaz=>7);
param3 = Dict( :ix1_WL=>30,:ix1_WO=>5);
In [22]:
# *******
file_bin="section_bin" # Run first Demo_Utils_1_Binning.ipynb
patch_out="patch" # will make files patch1, patch2,....
file_final ="section_bin_final" # file put back from patches via code SeisUnPatch
# *******
patch_out,npatch=SeisPatch(file_bin,"patch"; param2...,param3... );
In [14]:
SeisUnPatch(patch_out,file_final; param2...,param3...,nt=251);
In [19]:
#Plot for QC
db,hb,eb=SeisRead(file_bin);
In [18]:
SeisPlot(db[:,:,5,4,5],xlabel="Trace",ylabel="Time(s)", dy=0.002,oy=0.3,title="Binned data")
Out[18]:
In [20]:
df,hf,ef=SeisRead(file_final);
In [4]:
SeisPlot(df[:,:,5,4,5],xlabel="Trace",ylabel="Time(s)",title="Unpatched result",dy=0.002,oy=0.3)
Out[4]:
In [21]:
dp1,h1,e1=SeisRead("patch_1");
dp2,h2,e2=SeisRead("patch_2");
dp3,h3,e3=SeisRead("patch_3");
dp4,h4,e4=SeisRead("patch_4");
size(dp1)
Out[21]:
In [4]:
SeisPlot(hcat(dp1[:,:,5,4,5],dp2[:,6:end,5,4,5],dp3[:,6:end,5,4,5],dp4[:,6:end,5,4,5]),xlabel="Trace",ylabel="Time(s)", dy=0.002,oy=0.3,title="Overlapping patches")
Out[4]:
In [ ]: