Medical-Event-Data-Standard / Medical-Event-Data-Standard/MEDS-DEV

Unit conversion with the existing tasks

Open
#265 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Datasets Tasks
Dominant language
Python
Stars
43
Forks
10
PR merge metrics
No merged PRs in 30d

Description

Hi, @mmcdermott @gkondas

I am looking to fit the tasks in different datasets to the following tasks:


"abnormal_lab/vital/hypotension/first_24h"
"abnormal_lab/blood_chemistry/metabolic_acidosis/first_24h"
"abnormal_lab/blood_chemistry/hyponatremia/first_24h"
"abnormal_lab/blood_chemistry/elevated_creatinine/first_24h"
"abnormal_lab/cbc/leukocytosis/first_24h"
"abnormal_lab/cbc/thrombocytopenia/first_24h"
"abnormal_lab/cbc/anemia/first_24h"

The issue is that several datasets report mmol/L instead of g/dL. Firstly, this is non-trivial, as we need to know the molecular mass (although we can use common conversions, such as those for hemoglobin).

Second: currently, the thresholds are in both the predicates.yaml and the task.yaml: see https://github.com/Medical-Event-Data-Standard/MEDS-DEV/blob/main/src/MEDS_DEV/tasks/abnormal_lab/blood_chemistry/elevated_creatinine/first_24h.yaml. I would think the preferred place to put them is in the predicates only, such that the unit can be dataset-agnostic. Is this a bug? Why is this redundancy here?

Contributor guide

Open the contributing guide

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 with src/MEDS_DEV/tasks/abnormal_lab/blood_chemistry/elevated_creatinine/first_24h.yaml and compare its thresholds with the predicates.yaml and task.yaml files mentioned in the issue. Trace how the existing tasks map measurements and units across datasets, including the listed abnormal-lab tasks. Done means the required unit conversions and the intended threshold location are established clearly enough to support dataset-agnostic task definitions.

Written by the indexing model from the issue text.

Assessment

Tech stack
python, yaml
Domain
data, machine-learning
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.