Relative to my last post, is there a simple structure that can attach to the trace with just the poles, zeros and sensitivity? Maybe already existing within the SAC code? As a second thought can just portions of the inventory related to response be forced into the stream without the entire structure? I found it easy to extend trace.stats using AttribDict() so maybe something similar could be accomplished. Randy
remove_response() method “only” expects a Response object in the trace.stats dictionary.
Then ObsPy takes that structure and creates a complex C struct from it that we more or less force-feed to evalresp which then calculates the actual response. So if you want to keep using that it is about as simple as it gets.
An option would be to create a function that takes a dictionary akin to this:
and converts it to a response object. That should be very easy to do and would make that much easier. Please submit a pull request on Github if someone ends up implementing that! Lion
Would that response object format be the same format in the inventory object? Also, I looked at the SAC code and found a section that will attach response to the trace. I think the code essentially does what we need if the format of the trace stats created is usable in the response correction. I don’t know if it is just added as a stat or if it can be directly used for the response correction.