Small changes to detection thresholds
Hi @dwilson ,
In snooping through your code I found a few things that we might want to double check. I just put them here in one issue. I can make a pull-request with the changes but it might be better that you make the changes so I don't mess anything up.
Incorrect integration: integration I believe you want this to be a constant band-width like 1-octave using (2**(0.5)-2**(-0.5))
Do all calculations in displacement: spot you then want to convolve with a Wood-Anderson
paz_wa = {'sensitivity': 1, 'zeros': [0 + 0j,0 + 0j], 'gain': 1.0028,
'poles': [-5.49779 - 5.60886j, -5.49779 + 5.60886j]}
This is a x2080 magnification but that gets put into the attenuation formula. The above shapes the noise right around the corner of the instrument.
Need to convert to ptop from rms: code spot
I believe to convert from an rms to a peak-to-peak you need to multiply by a factor of 2*np.sqrt(2)
. You then probably want zero to peak, so half of this.
Making the above changes should make it, that upon recalculation, your attenuation models can be compared to the more classic ones. I might be missing some spots where these corrections/changes get done.
I don't know how to deal with the fact that PSDs are usually smoothed but the variance in the data limits the comparison. I think your std calculation on real data might be more realistic.
Feel free to ignore these if I am out to lunch.
Best,