Error when calling rdedfann(): read_edf() got an unexpected keyword argument 'delete_file'
未关闭
还没有人认领这个 Issue。
- 主要语言
- Jupyter Notebook
- 星标
- 853
- 派生
- 322
- PR 合并指标
- 30 天内没有已合并 PR
描述
Hi!
I just encounter strange error. It seems for me like function rdedfann doesn't work at all. I confused, because it seems it doesn't represent any specific use case, just ordinary edf file. So, seems strange to me.
I just installed new 4.0.0 version and got this bug.
wfdb: 4.0.0
When calling on edf file:
from wfdb.io.convert.edf import rdedfann
rdedfann(f"data/{folder}/{filename}")
---------------------------------------------------------------------------
TypeError Traceback (most recent call last)
Input In [6], in <cell line: 2>()
1 from wfdb.io.convert.edf import rdedfann
----> 2 rdedfann(f"data/{folder}/{filename}")
File ~/.venv/fecg/lib/python3.8/site-packages/wfdb/io/convert/edf.py:1096, in rdedfann(record_name, pn_dir, delete_file, info_only, record_only, verbose)
1087 raise Exception(
1088 "Both `info_only` and `record_only` are set. Only one "
1089 "can be set at a time."
1090 )
1092 # According to the EDF+ docs:
1093 # "The coding is EDF compatible in the sense that old EDF software would
1094 # simply treat this 'EDF Annotations' signal as if it were a (strange-
1095 # looking) ordinary signal"
-> 1096 rec = read_edf(
1097 record_name,
1098 pn_dir=pn_dir,
1099 delete_file=delete_file,
1100 record_only=True,
1101 rdedfann_flag=True,
1102 )
1104 # Convert from array of integers to ASCII strings
1105 annotation_string = ""
TypeError: read_edf() got an unexpected keyword argument 'delete_file'
贡献指南
这个仓库没有索引到贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
调研方向
从 wfdb/io/convert/edf.py 第 1096 行附近的 rdedfann 开始,然后检查 read_edf 调用及其接受的参数。使用 wfdb 4.0.0 重现报告中的 rdedfann 调用;当该调用不再引发 unexpected keyword argument 错误时,即表示完成。
由索引模型根据 Issue 内容生成。
评估
- 技术栈
- python
- 领域
- data
- Issue 类型
- 缺陷
- 难度
- 2/5
- 预计耗时
- 1-3 小时
- 活跃度
- 停滞
- 描述清晰度
- 基本清楚
- 新手友好度
- 45/100