Attention

From version v0.5, SEGY-SAK has migrated the documentation to https://trhallam.github.io/segysak/latest/.

This documentation will be archived from v0.6.

segysak.segy.put_segy_texthead

segysak.segy.put_segy_texthead(segyfile, ebcidc, line_counter=True, **segyio_kwargs)

Puts a text header (ebcidc) into a segyfile.

Parameters:
  • segyfile (str) – The path to the file to update.

  • ebcidc (str, list, dict, bytes) – A standard string, new lines will be preserved. A list or lines to add. A dict with numeric keys for line numbers e.g. {1: ‘line 1’}. A pre-encoded byte header to add to the segyfile directly.

  • line_counter (bool, opt) – Add a line counter with format “CXX “ to the start of each line. This reduces the maximum content per line to 76 chars.