obspy.io.nlloc.util.read_nlloc_scatter

read_nlloc_scatter(filename, coordinate_converter=None)[source]

Read a NonLinLoc Scatter file into a Numpy array.

Note

Coordinate conversion from coordinate frame of NonLinLoc model files / location run to WGS84 has to be specified explicitly by the user if necessary.

Parameters:
  • filename (str) – Filename with NonLinLoc scatter.

  • coordinate_converter (callable) – Function to convert (x, y, z) coordinates of NonLinLoc output to geographical coordinates and depth in meters (longitude, latitude, depth in kilometers). If left None, NonLinLoc (x, y, z) output is left unchanged (e.g. if it is in geographical coordinates already like for NonLinLoc in global mode). The function should accept three arguments x, y, z (each of type numpy.ndarray) and return a tuple of three numpy.ndarray (lon, lat, depth in kilometers).

Returns:

NonLinLoc scatter information as structured numpy array (fields: “x”, “y”, “z”, “pdf”).