obspy.taup.tau_model.TauModel

class TauModel(s_mod, radius_of_planet, is_spherical=True, cache=None, debug=False, skip_calc=False)[source]

Bases: object

Provides storage of all the TauBranches comprising a model.

Public Methods

calc_tau_inc_from

Calculates tau for each branch within a slowness model.

depth_correct

Called in TauPTime.

deserialize

Deserialize model from numpy npz binary file.

find_branch

Finds the branch that either has the depth as its top boundary, or strictly contains the depth.

from_file

get_branch_depths

Return an array of the depths that are boundaries between branches.

get_tau_branch

load_from_depth_cache

serialize

Serialize model to numpy npz binary file.

split_branch

Returns a new TauModel with the branches containing depth split at depth.

validate

Private Methods

Warning

Private methods are mainly for internal/developer use and their API might change without notice.

TauModel._load_from_depth_cache(depth)[source]

Special Methods

TauModel.__delattr__(name, /)

Implement delattr(self, name).

TauModel.__dir__()

Default dir() implementation.

TauModel.__eq__(value, /)

Return self==value.

TauModel.__format__(format_spec, /)

Default object formatter.

TauModel.__ge__(value, /)

Return self>=value.

TauModel.__getattribute__(name, /)

Return getattr(self, name).

TauModel.__gt__(value, /)

Return self>value.

TauModel.__hash__()

Return hash(self).

TauModel.__init__(s_mod, radius_of_planet, is_spherical=True, cache=None, debug=False, skip_calc=False)[source]
TauModel.__init_subclass__()

This method is called when a class is subclassed.

The default implementation does nothing. It may be overridden to extend subclasses.

TauModel.__le__(value, /)

Return self<=value.

TauModel.__lt__(value, /)

Return self<value.

TauModel.__ne__(value, /)

Return self!=value.

TauModel.__new__(**kwargs)
TauModel.__reduce__()

Helper for pickle.

TauModel.__reduce_ex__(protocol, /)

Helper for pickle.

TauModel.__repr__()

Return repr(self).

TauModel.__setattr__(name, value, /)

Implement setattr(self, name, value).

TauModel.__sizeof__()

Size of object in memory, in bytes.

TauModel.__str__()[source]
TauModel.__subclasshook__()

Abstract classes can override this to customize issubclass().

This is invoked early on by abc.ABCMeta.__subclasscheck__(). It should return True, False or NotImplemented. If it returns NotImplemented, the normal algorithm is used. Otherwise, it overrides the normal algorithm (and the outcome is cached).