Closed likueimo closed 8 years ago
It is not yet documented, but you can use every station file format, that ObsPy can read into an Inventory object. At the moment that are StationXML, Stationtxt (FDSNWS), SeiscompXML, and CSS. SACPZ is not supported. Anyway, you'd need station coordinates in the station file.
One option would be to remove instrument response beforehand with your sacpz file (or leave it out completely). You can then use the rf Python module directly (without batch module and conf.json). You won't need any StationXML file, but just the coordinates of the stations.
Here is a small code example
from obspy import read_events
from obspy.io.sac import attach_paz
from rf import read_rf, rfstats
stream = read_rf() # use your 3 component data
for tr in stream:
attach_paz(tr, 'sacpz.txt') # use your sacpz file
stream.simulate('self')
station = {'latitude': 0, 'longitude': 0, 'elevation': 0}
event = read_events()[0] # use your event file
stats = rfstats(station=station, event=event, phase='P', dist_range=(30, 90))
for tr in stream:
tr.stats.update(stats)
stream.filter('bandpass', freqmin=0.05, freqmax=1.)
stream.rf()
Sorry I am new in python and never deal with Station XML format If I do not have any Station XML format Only have sacpz file like this
Is it possible to use this rf repository ?Or how to rewrite conf.json ? Thank you a lot to develop this useful rf project !