pysep icon indicating copy to clipboard operation
pysep copied to clipboard

appending taup based phase arrival times to synthetics

Open aakash10gupta opened this issue 3 months ago • 2 comments

The SAC headers generated on the fly by recsec for synthetic seismograms do not contain the taup based phase arrival times, and hence the seismograms cannot be aligned on a particular arrival while plotting. pysep already seems to have the machinery to do this. Appending arrival time headers to ALL sets of synthetics will also enable arrival window based post-processing of synthetics exported from recsec as SAC files.

aakash10gupta avatar Sep 19 '25 00:09 aakash10gupta

Thanks @aakash10gupta. Just thinking about this more, it might be useful to have a PySEP command line function just for appending SAC headers + TauP traveltimes. This will be nice for data collected outside of PySEP, for when you want to adjust the underlying TauP model used, or for SPECFEM synthetics. I think it could look something like:

pysep  --pysep_path ./ --inventory ./inv.xml --source ./cat.xml --append_sac_headers --append_taup_traveltimes

That way we also avoid running TauP on the fly each time a new record section is made, if we were to put this directly into RecSec.

I'll think on it more, just leaving this here as note.

bch0w avatar Sep 19 '25 00:09 bch0w

@bch0w, I think what you are suggesting will be very useful, if I understand it correctly. In research mode, I end up plotting specfem3D_cartesian synthetics hundreds of times using recsec just changing a recsec parameter or two each time. This leads to the synthetic seismogram metadata being linked to the corresponding seismogram each time on the fly. It will be way more efficient and faster to have the ability to convert the raw ASCII files to SAC files with all associated metadata including taup phase arrival times once at the beginning of any analysis. These SAC files would ideally also contain raw data i.e. unprocessed / unfiltered data just with all metadata added for faster post-processing. I think this aligns with what you were suggesting.

aakash10gupta avatar Sep 19 '25 15:09 aakash10gupta