Exemplo n.º 1
0
    ns, nt, osciwlet, pthetas, ptimes, dt, att)


# nt = 62
# Plot synthetic traces
# psplot.hseisplot(syndata, ns, nt)
# psplot.vseisplot(syndata, ns, nt)


# Pick and plot first arrival time of microseismic events

# pick arrival times
pics = []
for i in range(nt):
    tr = syndata[:, i]
    pic = pspicker.merpicker(tr, ns, 20, 600, "False")
    pics.append(pic)
pickers = array(pics, dtype='float32')
pickers.shape = (len(pickers), 1)

# plot pickers
# psplot.hseispickplot(syndata, pickers, ns, nt)
# psplot.vseispickplot(syndata, pickers, ns, nt)

if os.path.exists('pdf_961.txt') == True:
    pdfvalues = loadtxt('pdfvalues.txt')
else:
    # Calculate probability density function values
    x1 = 0
    x2 = 6000
    dx = 60
Exemplo n.º 2
0
z1 = 1000
z2 = 3000
vel = 3000

ns = 512
srate = 0.25
win = 20
threshold = 600
N = 12
to = 0
pSigma = 1
pdf = np.zeros((10000, ), dtype=np.float32)
tp = np.zeros((geonum, ), dtype=np.int32)
tmp = np.zeros((geonum, ), dtype=np.int32)
ii = 0
jj = 0
for i in range(x1, x2, 5):
    for j in range(z1, z2, 20):
        for k in range(geonum):
            tp[k] = sqrt(square(i) + square(gz[k] - j)) / vel * 1000 / srate
            # print('%d'%tp[k])
            tmp[k] = merpicker(st.traces[k * 3].data, ns, srate, win,
                               threshold, "false")
            # print('%d'%tmp[k])
        n = ii * 100 + jj
        print('%d' % n)
        pdf[n] = pdftp(N, geonum, tp, tmp, to, pSigma)
        print('%100.99f' % pdf[n])
        jj = jj + 1
    ii = ii + 1
print(pdf)