PyHealth
PyHealth copied to clipboard
[Bounty] Deepr PyHealth 2.0 ver.
Contributor Information
- Name: Joshua Steier
- Contribution Type: Model
Description
Updated the Deepr model to align with PyHealth 2.0 conventions:
- Migrated from
BaseEHRDatasettoSampleDataset - Replaced manual tokenization with
EmbeddingModel - Updated label handling to use
get_output_size()and direct tensor access - Added learnable gap embedding for nested sequence flattening
- Supports both 3D and 4D input tensors
Files to Review
pyhealth/models/deepr.pytests/core/test_deepr.py
Testing
python -m pytest -q tests/core/test_deepr.py -s
# Result: 5 passed
Could you also provide a example notebook in the examples folder to demonstrate how to use this model? thank you.
@jhnwu3, @LogicFan, I added an example notebook in addition to the changes above, thank you.