コード例 #1
0
    def from_obspy_inventory_object(cls,
                                    obspy_inventory,
                                    xy_from_lat_lon=False,
                                    input_projection=4326,
                                    output_projection=None):

        source = ns  # Network ID of the institution sending
        # the message.

        inv = cls([], ns)
        inv.networks = []
        for network in obspy_inventory.networks:
            inv.networks.append(
                Network.from_obspy_network(
                    network,
                    xy_from_lat_lon=xy_from_lat_lon,
                    input_projection=input_projection,
                    output_projection=output_projection))

        return inv