-
Notifications
You must be signed in to change notification settings - Fork 21
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Redundant check in calculate_preliminiaries
#12
Comments
Hmm...I think it has to stay there but you are partially right: It should be moved into a common routine that can be shared with I think that removing this might slow down the code down quite a bit as this here actually removes peaks and troughs before the windows are selected. The next steps creates windows as (if I remember correctly) full permutations of peaks and troughs so removing only a subset of peaks and troughs has the potential to eliminate a crazy amount of windows before they are even created. |
Suppose you want to select |
If you are concerned about the speed issues, I think we may put the For example, the window should be in signal region instead of noise region. If we check so, we can reject quite a lot of windows at the beginning of the seismograms. But users still have the flexibility to customize it... |
True but the The current logic as actually not particularly good for picking reflected phases for stations close to event precisely for the reason you mentioned. This could be solved by making the shared core for both methods a bit smarter. Instead of just relying on first arrival and a minimal surface wave velocity it could rely on first arrival (for beginning of allowed time window) and max(some core reflected phase time, min surface wave velocity). This should work for almost every case I believe. |
This smarter version could also replace the whole noise index stuff. It would just create a signal start and a signal end index. Everything before the signal start index will be considered noise. |
Not so in my code. In my code, I replace the I agree with your opinion that the travel time should be used in a smarter way. I will think about and let you know later... |
Oh, I got one more question for you, just to make sure... In this line
We should consider offset right? Otherwise, the |
Hi Lion,
I am revisiting the pyflex code and found that in the
calculate_preliminiaries
, you have such checks:Which I think for current design of pyflex, this part shouldn't be here, because it works the same as function
reject_on_traveltimes
. It is also very limited since it reject all the windows after surface waves.The text was updated successfully, but these errors were encountered: