yetinam / pyocto

PyOcto: A high-throughput seismic phase associator
MIT License
40 stars 1 forks source link

Can PyOcto associate picks to an event when few picks available? #18

Closed Cthuulhaa closed 2 weeks ago

Cthuulhaa commented 2 weeks ago

Hi,

I tried to associate automatically predicted picks for an event in Austria. Picks were detected on 6 stations (although two of them are extremely close to each other). This is the station distribution around the epicenter:

event_austria

Through visual inspection I can regard the picks as correct. Following the tutorials, these are the picks and stations dataframes, respectively:

 station     phase  time        peak_value        peak_time
0    ARSA     P  1.686001e+09    0.982685 2023-06-05 21:40:21.010
1    ARSA     S  1.686001e+09    0.853941 2023-06-05 21:40:25.750
2     MOA     P  1.686001e+09    0.943732 2023-06-05 21:40:27.240
3     MOA     S  1.686001e+09    0.112382 2023-06-05 21:40:38.270
4    CSNA     P  1.686001e+09    0.921284 2023-06-05 21:40:29.630
5    SOKA     P  1.686001e+09    0.982909 2023-06-05 21:40:26.640
6    PERS     P  1.686001e+09    0.979253 2023-06-05 21:40:27.490
7    CONA     P  1.686001e+09    0.927418 2023-06-05 21:40:29.660
8    CONA     S  1.686001e+09    0.169142 2023-06-05 21:40:41.980
     id   longitude      latitude    elevation       x          y         z
0  ARSA    15.5232   47.2505      577.0  41.574279 -12.138718 -0.5770
1   MOA    14.2659   47.8495      572.0 -52.995588  54.555512 -0.5720
2  CSNA    15.8588   47.9282     1039.0  66.119815  63.442213 -1.0390
3  SOKA    15.0327   46.6780     1008.5   4.491238 -75.928270 -1.0085
4  PERS    15.1139   46.6365      795.0  10.712181 -80.533748 -0.7950
5  CONA    15.8618   47.9282     1046.0  66.343999  63.444788 -1.0460

I describe the 1D velocity model (2 layers):

pyocto.VelocityModel1D.create_model(layers, 1., 100, 100, velmod_path)
velocity_model = pyocto.VelocityModel1D(velmod_path, tolerance=3.5, association_cutoff_distance=200.)

and use the associator:

   associator = pyocto.OctoAssociator.from_area(lat=(ev_lat - 1, ev_lat + 1), lon=(ev_lon - 1, ev_lon + 1), zlim=(0, 100), time_before=400, velocity_model=velocity_model, n_p_picks=2, n_s_picks=2, n_picks=6, n_p_and_s_picks=2, pick_match_tolerance=3.)
   associator.transform_stations(stations)
   events, assignments = associator.associate(picks, stations)
   associator.transform_events(events)

however, the events output is empty. I have tested with different minimal picks required by the associator and the picks are still not associated to the event. I have only 9 picks distributed on the 6 stations, but I don't know if the picks are enough to be associated to the event. Any ideas?

Cheers!

yetinam commented 2 weeks ago

Hi @Cthuulhaa ,

thanks for the detailed report. In principle, there is no reason why PyOcto should not be able to associate these picks. Your parameters also seem reasonable. On thing that might be causing the issue is a quirk with the velocity model. Could you extend the horizontal extent of the velocity model to maybe 300 km and try associating again?

If that still doesn't work, could you upload the station and pick dataframes and your velocity model? Then I'll have a look myself and see if I can figure out the issue.

Cthuulhaa commented 2 weeks ago

@yetinam whoa! Worked like a charm. Thanks!

yetinam commented 2 weeks ago

Great! As an explanation (and if anyone stumbled across this later), this is a problem on how missing travel times are treated in the location routine. I should probably look into an actual fix to avoid this problem altogether.