Can't read specific, but seemingly valid SEG-Y file #577
Open
Description
I can't read specific, but seemingly valid SEG-Y file. What in segyio is triggering this (and is it an issue with the file or code)?
The file can be reached here: https://drive.google.com/file/d/1MXw_5dqoSYJlMoXWB7BJvqSY75GQnCsQ/view?usp=sharing
from pathlib import Path
path = r"/path/to/AN-A401.sgy"
a = Path(path).stat().st_size - 3600
trace_lenth = 2560
b = trace_lenth * 4 + 240
assert (a % b == 0)
# asserting that the file length is exactly as it should be
import segyio
segyio.open(path, ignore_geometry=True, mode="r", endian='big')
# yields error: RuntimeError: trace count inconsistent with file size, trace lengths possibly of non-uniform
# Other programs do work, including seisee and obspy.
from obspy.io.segy.core import _read_segy
st = _read_segy(path, format="SEGY")
Metadata
Assignees
Labels
No labels