Пример #1
0
for iev in range(start_itemp, stop_itemp):
    inplist = tempinp_dir + str(
        iev) + ".??" + "." + "*" + "..???" + "." + "mseed"
    print("inplist == ...", inplist)
    st.clear()

    for filename in glob.glob(inplist):
        csize = os.path.getsize(filename)

        if csize > 0:
            print("filename ..", filename)
            st += read(filename)

    nst = len(st)
    # print nst
    print(st.__str__(extended=True))
    refT = min([tr.stats.starttime for tr in st])
    Tshift = np.empty(nst)
    arrP = np.empty(nst)
    arrS = np.empty(nst)
    origin_time_shift = np.empty(1)
    fout1 = tempout_dir + str(iev) + ".ttimes"
    fileout = open(fout1, "w+")

    for it, tr in enumerate(st):
        Tshift[it] = tr.stats.starttime - refT

        if Tshift[it] == 0:
            # define epicenter closest station
            ref_sta = tr.stats.station
            # event details
Пример #2
0
        tmp = client.waveform.getWaveform(NET, station, "", CHANNEL, T1 - 180,
                                          T2 + 180, getPAZ=True,
                                          getCoordinates=True)
    except Exception, e:
        exceptions.append("%s: %s" % (e.__class__.__name__, e))
        continue
    st.extend(tmp)
    num_stations += 1
st.merge(-1)
st.sort()

summary = []
summary.append("#" * 79)
summary.append("######## %s  ---  %s ########" % (T1, T2))
summary.append("#" * 79)
summary.append(st.__str__(extended=True))
if exceptions:
    summary.append("#" * 33 + " Exceptions  " + "#" * 33)
    summary += exceptions
summary.append("#" * 79)

trig = []
mutt = []
if st:
    # preprocessing, backup original data for plotting at end
    st.merge(0)
    st.detrend("linear")
    for tr in st:
        tr.data = tr.data * cosTaper(len(tr), 0.01)
    #st.simulate(paz_remove="self", paz_simulate=cornFreq2Paz(1.0), remove_sensitivity=False)
    st.sort()
Пример #3
0
        tmp = client.waveform.getWaveform(NET, station, "", CHANNEL, T1 - 180,
                                          T2 + 180, getPAZ=True,
                                          getCoordinates=True)
    except Exception, e:
        exceptions.append("%s: %s" % (e.__class__.__name__, e))
        continue
    st.extend(tmp)
    num_stations += 1
st.merge(-1)
st.sort()

summary = []
summary.append("#" * 79)
summary.append("######## %s  ---  %s ########" % (T1, T2))
summary.append("#" * 79)
summary.append(st.__str__(extended=True))
if exceptions:
    summary.append("#" * 33 + " Exceptions  " + "#" * 33)
    summary += exceptions
summary.append("#" * 79)

trig = []
mutt = []
if st:
    # preprocessing, backup original data for plotting at end
    st.merge(0)
    st.detrend("linear")
    for tr in st:
        tr.data = tr.data * cosTaper(len(tr), 0.01)
    #st.simulate(paz_remove="self", paz_simulate=cornFreq2Paz(1.0), remove_sensitivity=False)
    st.sort()