MIT-LCP / MIT-LCP/wfdb-python

Change approach for allowing `seg_name` and `seg_len` to be lists

Open
#516 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Jupyter Notebook
Stars
853
Forks
322
PR merge metrics
No merged PRs in 30d

Description

In https://github.com/MIT-LCP/wfdb-python/pull/514 an update was made to allow seg_name and seg_len to be lists. This is needed for writing a MultiSegmentRecord.

@bemoody , suggested an alternate approach:

But I think what we really want is, rather than changing the types in SEGMENT_SPECS, we want to add "seg_name" and "seg_len" to LIST_FIELDS (wfdb/io/record.py, line 1675.)

This issue is being opened to track implementing this alternate approach.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by inspecting LIST_FIELDS in wfdb/io/record.py around line 1675, along with the current SEGMENT_SPECS handling. The change is complete when seg_name and seg_len are handled through LIST_FIELDS and writing a MultiSegmentRecord continues to support them.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
data
Issue type
Refactor
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.