예제 #1
0
#%% (4) Plot

from rtm import (plot_time_slice, plot_record_section, get_peak_coordinates,
                 plot_st)
import numpy as np

fig_st = plot_st(st,
                 filt=[FREQ_MIN, FREQ_MAX],
                 equal_scale=False,
                 remove_response=True,
                 label_waveforms=True)

fig_slice = plot_time_slice(S,
                            st_proc,
                            label_stations=True,
                            dem=dem,
                            plot_peak=True)

time_max, y_max, x_max, peaks, props = get_peak_coordinates(S,
                                                            global_max=False,
                                                            height=3,
                                                            min_time=2,
                                                            unproject=S.UTM)

peak_ind = np.argmax(props['peak_heights'])

fig = plot_record_section(st_proc,
                          origin_time=time_max[peak_ind],
                          source_location=(y_max[peak_ind], x_max[peak_ind]),
                          plot_celerity=S.celerity,
예제 #2
0
STACK_METHOD = 'sum'  # Choose either 'sum', 'product', or 'semblance'
TIME_METHOD = 'celerity'  # Choose either 'celerity' or 'fdtd'
CELERITY = 320  # [m/s]

S = grid_search(processed_st=st_proc,
                grid=grid,
                time_method=TIME_METHOD,
                starttime=STARTTIME,
                endtime=ENDTIME,
                stack_method=STACK_METHOD,
                celerity=CELERITY)

#%% (4) Plot

from rtm import plot_time_slice, plot_record_section, get_peak_coordinates

fig_slice = plot_time_slice(S,
                            st_proc,
                            label_stations=False,
                            hires=False,
                            plot_peak=True)

time_max, y_max, x_max, _, _ = get_peak_coordinates(S, unproject=S.UTM)

fig = plot_record_section(st_proc,
                          origin_time=time_max,
                          source_location=(y_max, x_max),
                          plot_celerity='range',
                          label_waveforms=False)
fig.axes[0].set_ylim(bottom=1100)  # Start at this distance (km) from source
예제 #3
0
STACK_METHOD = 'sum'  # Choose either 'sum', 'product', or 'semblance'
TIME_METHOD = 'celerity'  # Choose either 'celerity' or 'fdtd'
CELERITY = 320  # [m/s]

S = grid_search(processed_st=st_proc,
                grid=grid,
                time_method=TIME_METHOD,
                starttime=STARTTIME,
                endtime=ENDTIME,
                stack_method=STACK_METHOD,
                celerity=CELERITY)

#%% (4) Plot

from rtm import (plot_time_slice, plot_record_section, get_peak_coordinates,
                 plot_stack_peak)

plot_time_slice(S, st_proc, label_stations=False, hires=True)

time_max, y_max, x_max, _, _ = get_peak_coordinates(S, unproject=S.UTM)

fig = plot_record_section(st_proc,
                          origin_time=time_max,
                          source_location=(y_max, x_max),
                          plot_celerity='range',
                          label_waveforms=False)
fig.axes[0].set_ylim(bottom=1100)  # Start at this distance (km) from source

fig_peak = plot_stack_peak(S, plot_max=True)