예제 #1
0
    def __init__(
        self,
        host="cwbpub.cr.usgs.gov",
        port=2060,
        write_port=7981,
        observatory=None,
        channels=None,
        type=None,
        interval=None,
        observatoryMetadata=None,
        locationCode=None,
        cwbhost=None,
        cwbport=0,
        tag="GeomagAlg",
        forceout=False,
    ):
        TimeseriesFactory.__init__(self, observatory, channels, type, interval)
        self.client = earthworm.Client(host, port)

        self.observatoryMetadata = observatoryMetadata or ObservatoryMetadata()
        self.tag = tag
        self.locationCode = locationCode
        self.interval = interval
        self.host = host
        self.port = port
        self.write_port = write_port
        self.cwbhost = cwbhost or ""
        self.cwbport = cwbport
        self.forceout = forceout
예제 #2
0
    def __init__(self, name = 'earthworm waveserver client', host='localhost', port=16022, **kwargs):
        WaveClient.__init__(self, name=name, **kwargs)

        # The Earthworm waveserver host to which the client should connect.
        self.host = host

        # The port on which the Eartworm waveserver is running on host.
        self.port = port

        # The obspy earthworm waveserver client instance.
        self.client = earthworm.Client(self.host,
                                       self.port,
                                       timeout=2)