obspy.taup.velocity_model.VelocityModel.read_tvel_file
- classmethod VelocityModel.read_tvel_file(filename)[source]
Read in a velocity model from a “tvel” ASCII text file.
The name of the model file for model “modelname” should be “modelname.tvel”. The format of the file is:
comment line - generally info about the P velocity model comment line - generally info about the S velocity model depth pVel sVel Density depth pVel sVel Density
The velocities are assumed to be linear between sample points. Because this type of model file doesn’t give complete information we make the following assumptions:
modelname
- from the filename, with “.tvel” dropped if presentradius_of_planet
- the largest depth in the modelmeanDensity
- 5517.0G
- 6.67e-11
Comments using
#
are also allowed.- Parameters
filename (str) – The name of the file to read.
- Raises
ValueError – If model file is in error.