You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
/opt/hostedtoolcache/Python/3.9.21/x64/lib/python3.9/site-packages/wfdb/io/record.py:1853: in rdheader
record_fields = _header._parse_record_line(header_lines[0])
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
record_line = 'ge_median_beats_wfdb/00001_medians 12 500 600'
def _parse_record_line(record_line: str) -> dict:
"""
Extract fields from a record line string into a dictionary.
Parameters
----------
record_line : str
The record line contained in the header file
Returns
-------
record_fields : dict
The fields for the given record line.
"""
# Dictionary for record fields
record_fields: Dict[str, Any] = {}
# Read string fields from record line
match = rx_record.match(record_line)
if match is None:
> raise HeaderSyntaxError("invalid syntax in record line")
E wfdb.io.header.HeaderSyntaxError: invalid syntax in record line
/opt/hostedtoolcache/Python/3.9.21/x64/lib/python3.9/site-packages/wfdb/io/_header.py:1021: HeaderSyntaxError
I think this is caused by the mismatch of the wfdb.io.header.rx_record with the first line of header file ge_median_beats_wfdb/00001_medians 12 500 600. rx_record is as follows:
It seems that one should not modify rx_record and rx_signal. This would result in FileNotFoundError when calling rdrecord since the ge_median_beats_wfdb folder does not exist. The PTB-XL+ database should be updated.
WFDB version: 4.1.2
header file: https://physionet.org/content/ptb-xl-plus/1.0.1/median_beats/12sl/00000/00001_medians.hea
header file content:
error message:
I think this is caused by the mismatch of the
wfdb.io.header.rx_record
with the first line of header filege_median_beats_wfdb/00001_medians 12 500 600
.rx_record
is as follows:On can resolve this by changing the first line of
rx_record
from[ \t]* (?P<record_name>[-\w]+)
to[ \t]* (?P<record_name>[-\w\/]+)
.@briangow @bemoody
The text was updated successfully, but these errors were encountered: