Stream.simulate(paz_remove=None, paz_simulate=None, remove_sensitivity=True, simulate_sensitivity=True, **kwargs)[source]

Correct for instrument response / Simulate new instrument response.

  • paz_remove (dict, None) Dictionary containing keys 'poles', 'zeros', 'gain' (A0 normalization factor). Poles and zeros must be a list of complex floating point numbers, gain must be of type float. Poles and Zeros are assumed to correct to m/s, SEED convention. Use None for no inverse filtering. Use 'self' to use paz AttribDict in trace.stats for every trace in stream.
  • paz_simulate (dict, None) Dictionary containing keys 'poles', 'zeros', 'gain'. Poles and zeros must be a list of complex floating point numbers, gain must be of type float. Or None for no simulation.
  • remove_sensitivity (bool) Determines if data is divided by paz_remove['sensitivity'] to correct for overall sensitivity of recording instrument (seismometer/digitizer) during instrument correction.
  • simulate_sensitivity (bool) Determines if data is multiplied with paz_simulate['sensitivity'] to simulate overall sensitivity of new instrument (seismometer/digitizer) during instrument simulation.

This function corrects for the original instrument response given by paz_remove and/or simulates a new instrument response given by paz_simulate.

For additional information and more options to control the instrument correction/simulation (e.g. water level, demeaning, tapering, ...) see simulate_seismometer().

The keywords paz_remove and paz_simulate are expected to be dictionaries containing information on poles, zeros and gain (and usually also sensitivity).

If both paz_remove and paz_simulate are specified, both steps are performed in one go in the frequency domain, otherwise only the specified step is performed.


Instead of the builtin deconvolution based on Poles and Zeros information, the deconvolution can be performed using evalresp instead by using the option seedresp (see documentation of simulate_seismometer() and the ObsPy Tutorial.


This operation is performed in place on the actual data arrays. The raw data is not accessible anymore afterwards. To keep your original data, use copy() to create a copy of your stream object. This also makes an entry with information on the applied processing in stats.processing of every trace.


>>> from obspy import read
>>> from obspy.signal.invsim import corn_freq_2_paz
>>> st = read()
>>> paz_sts2 = {'poles': [-0.037004+0.037016j, -0.037004-0.037016j,
...                       -251.33+0j,
...                       -131.04-467.29j, -131.04+467.29j],
...             'zeros': [0j, 0j],
...             'gain': 60077000.0,
...             'sensitivity': 2516778400.0}
>>> paz_1hz = corn_freq_2_paz(1.0, damp=0.707)
>>> st.simulate(paz_remove=paz_sts2, paz_simulate=paz_1hz)
<...Stream object at 0x...>
>>> st.plot()  

(Source code, png, hires.png)