_read_su(filename, headonly=False, byteorder=None, unpack_trace_headers=False, **kwargs)[source]

Reads a Seismic Unix (SU) file and returns an ObsPy Stream object.


This function should NOT be called directly, it registers via the ObsPy read() function, call this instead.

  • filename (str) SU file to be read.
  • headonly (bool, optional) If set to True, read only the header and omit the waveform data.
  • byteorder (str or None) Determines the endianness of the file. Either '>' for big endian or '<' for little endian. If it is None, it will try to autodetect the endianness. The endianness is always valid for the whole file. Defaults to None.
  • unpack_trace_headers (bool, optional) Determines whether or not all trace header values will be unpacked during reading. If False it will greatly enhance performance and especially memory usage with large files. The header values can still be accessed and will be calculated on the fly but tab completion will no longer work. Look in the headers.py for a list of all possible trace header values. Defaults to False.

A ObsPy Stream object.


>>> from obspy import read
>>> st = read("/path/to/1.su_first_trace")
>>> st 
<obspy.core.stream.Stream object at 0x...>
>>> print(st)  
1 Trace(s) in Stream:
... | 2005-12-19T15:07:54.000000Z - ... | 4000.0 Hz, 8000 samples