-
Notifications
You must be signed in to change notification settings - Fork 24
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added README file and image files it references #541
Merged
Merged
Changes from 59 commits
Commits
Show all changes
62 commits
Select commit
Hold shift + click to select a range
8a6eed7
Added README file and image files it references
Ian-Erickson d77e834
Testing if subscript implementation is correct before using it further.
Ian-Erickson 850b0f3
Implemented proper subscript in instances of ML4Hseg and ML4Hreg
Ian-Erickson 5fdca9c
Changed the title of the README in Deep learning to estimate cardiac …
Ian-Erickson 651ba9f
Removed "attachment" tag to images and added .png to Lreg.
Ian-Erickson f6632db
Added additional line breaks so that the loss functions appeared on t…
Ian-Erickson 851c231
Added line detailing the optimization of the models through the Adam …
Ian-Erickson 4207d3b
Added link to Model architectures, trained weights, and more metrics
Ian-Erickson 67daa1c
Moved location of model architectures, and other useful data to the f…
Ian-Erickson 4422ce9
Added image comparing the three models and their results.
Ian-Erickson 7c10e66
Added Results Section with images from the study.
Ian-Erickson ce09733
Removed the word "then".
Ian-Erickson 903f373
Changed title of liver fat model into link.
Ian-Erickson df597e3
Added link to paper in the README of "Deep Learning to Predict Cardia…
Ian-Erickson a768e90
Made the title of "Estimating body fat distribution from silhouette i…
Ian-Erickson 6cf664f
Fixed link in README of "Estimating body fat distribution from silhou…
Ian-Erickson d3e070a
Made the citation in the README of mi_feature_selection link to the p…
Ian-Erickson de2e4db
Made the link in the README of silhouette_IRL go to the article cited.
Ian-Erickson 8a41145
Changed the link in the liver_fat_from_mri_ubk README to the correct …
Ian-Erickson 5c02e4f
Did some minor edits in the README of left_ventricular_mass_from_ecg_…
Ian-Erickson ed37d9e
Did minor edits on the README of model_zoo/cardiac_mri_derived_left_v…
Ian-Erickson da0c1de
Added some info on the LVM-AI model.
Ian-Erickson de995a8
Changed the image link in Left_Ventricular_Mass....
Ian-Erickson 5b86c12
Added image file depicting the training and Test Sets of LVM-AI. Had …
Ian-Erickson ee118a3
Attempted to decrease the size of the image in left_ventricular_mass_…
Ian-Erickson 987dbc4
Undid previous changes.
Ian-Erickson 81104fc
Updated readme to not use "we" as it does in the report. Also trimmed…
Ian-Erickson 7d4c953
Further fixed grammar of README
Ian-Erickson 17aa78f
Inserted Image of the model's layers into README
Ian-Erickson eabbc34
Changed link in cardiac_mri... README to be in HTML rather than Markdown
Ian-Erickson 04d7ae7
Removed link in the title from silhouette_mri
Ian-Erickson 652c750
Added sentence containing link to the paper on the model to several R…
Ian-Erickson 40421a4
Fixed Links to original paper.
Ian-Erickson 12361c6
Changed link to original paper in liver_fat README.
Ian-Erickson 1128e92
Removed quotes in ecg_student README for consistency
Ian-Erickson 5aa20b5
Added Git LFS tracking for images in cardiac_mri_derived...
Ian-Erickson 4b4f3a4
Git removed files
Ian-Erickson 86a90ba
Tried to revert changes
Ian-Erickson b82778f
Merge branch 'READMEs' of https://github.com/broadinstitute/ml4h into…
Ian-Erickson f7a62d9
renamed LSeg to Lseg
Ian-Erickson a326041
Updated Lseg reference in README
Ian-Erickson 00d9c67
Having problems. One of the deleted images won't come back.
Ian-Erickson cfbe63f
Merge branch 'READMEs' of https://github.com/broadinstitute/ml4h into…
Ian-Erickson d98bde4
renamed Lseg again.
Ian-Erickson fe61378
Removed image as it no longer seems to exist.
Ian-Erickson cc9b8aa
Added git lfs tracking to loss function images
Ian-Erickson ae9cf1f
Added TrainingAndTestSets.jpg to git lfs
Ian-Erickson 5340608
Adding test image to be removed using git rm.
Ian-Erickson 92c2a25
Renamed test image so it's targetable with command.
Ian-Erickson bc145b8
Deleted TestImage.png
Ian-Erickson 8a469b0
Attempted to get the loss of ML4Hseg displaying again.
Ian-Erickson 154e268
Changed alt text of Lreg image
Ian-Erickson c02a68a
Changed the README to use LSeg.png
Ian-Erickson bb21c8e
Added lines between text and loss functions.
Ian-Erickson 53b3c5f
Running git rm on LSeg.png.
Ian-Erickson d056cdb
Adding Lseg back in.
Ian-Erickson 7585b2b
Updating Readme to use proper Lseg.png
Ian-Erickson e0161d3
Added git lfs tracking to images in liver_fat...
Ian-Erickson 2800a66
Added lfs tracking to some images not already in .gitattributes.
Ian-Erickson bcc5911
fix
lucidtronix 0ff7f89
fix
lucidtronix 8adedf9
fix
lucidtronix File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
26 changes: 26 additions & 0 deletions
26
model_zoo/cardiac_mri_derived_left_ventricular_mass/README.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
# Deep learning to estimate cardiac magnetic resonance–derived left ventricular mass | ||
This folder contains models and code supporting the work described in <a href= "https://www.sciencedirect.com/science/article/pii/S2666693621000232?ref=pdf_download&fr=RR-2&rr=80df2c704c374cd4">this paper</a> published in the Cardiovascular Digital Health Journal. | ||
|
||
Within participants of the UK Biobank prospective cohort undergoing CMR, 2 convolutional neural networks were trained to estimate LV mass. The first (ML4H<sub>reg</sub>) performed regression informed by manually labeled LV mass (available in 5065 individuals), while the second (ML4Hseg) performed LV segmentation informed by InlineVF (version D13A) contours. All models were optimized using the Adam variant of stochastic gradient descent with initial learning rate 1 × 10-3, exponential learning rate decay, and batch size of 4 on K80 graphical processing units. | ||
# ML4H<sub>reg</sub> | ||
The first model is a 3D convolutional neural network regressor ML4H<sub>reg</sub> trained with the manually annotated LV mass estimates provided by Petersen and colleagues to optimize the log cosh loss function, which behaves like L2 loss for small values and L1 loss for larger values: | ||
|
||
![Loss of ML4Hregs](Lreg.png) | ||
|
||
Here batch size, N, was 4 random samples from the training set of 3178 after excluding testing and validation samples from the total 5065 CMR images with LV mass values included in P. | ||
# ML4H<sub>seg</sub> | ||
ML4H<sub>seg</sub>, is a 3D semantic | ||
segmenter. To facilitate model development in the absence of hand-labeled segmentations, the models were trained with the InlineVF contours to minimize Lseg; the per-pixel cross-entropy between the label and the model’s prediction. | ||
|
||
![Loss of ML4Hseg](Lseg.png) | ||
|
||
Here the batch size, N, was 4 from the total set of 33,071. Height, H, and width, W, are 256 voxels and there was a maximum of 13 Z slices along the short axis. There is a channel for each of the 3 labels, which were one-hot encoded in the training data, InlineVF (IVF), and probabilistic values from the softmax layer of ML4H<sub>seg</sub>. Segmentation architectures used U-Net-style long-range connections between early convolutional layers and deeper layers. Since not all CMR images used the same pixel dimensions, models were built to incorporate pixel size values with their fully connected layers before making predictions. | ||
# Results | ||
The accuracy of both deep learning approaches wwere compared to LV mass obtained using InlineVF within an independent holdout set using manually labeled LV mass as the gold standard. | ||
![Overview of left ventricular (LV) mass algorithms.](https://ars.els-cdn.com/content/image/1-s2.0-S2666693621000232-gr1.jpg) | ||
|
||
Within 33,071 individuals who underwent CMR, models were trained to derive CMR-based LV mass using deep learning regression (ML4Hreg) and segmentation (ML4Hseg). | ||
![Distributions of cardiac magnetic resonance (CMR)-derived left ventricular (LV) mass obtained using each estimation method.](https://ars.els-cdn.com/content/image/1-s2.0-S2666693621000232-gr2.jpg) | ||
|
||
In an independent holdout set of 891 individuals with manually labeled LV mass estimates available, ML4Hseg had favorable correlation with manually labeled LV mass (r = 0.864, 95% confidence interval 0.847–0.880; MAE 10.41 g, 95% CI 9.82–10.99) as compared to ML4Hreg (r = 0.843, 95% confidence interval 0.823–0.861; MAE 10.51, 95% CI 9.86–11.15, P = .01) and centered InlineVF (r = 0.795, 95% confidence interval 0.770–0.818; MAE 14.30, 95% CI 13.46–11.01, P < .01) | ||
![Correlation between manually labeled left ventricular (LV) mass and derived left ventricular mass estimated using each model. ](https://ars.els-cdn.com/content/image/1-s2.0-S2666693621000232-gr3.jpg) |
3 changes: 0 additions & 3 deletions
3
...rived_left_ventricular_mass/architecture_graph_sax_diastole_segment_no_flat.png
This file was deleted.
Oops, something went wrong.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
18 changes: 15 additions & 3 deletions
18
model_zoo/left_ventricular_mass_from_ecg_student_and_mri_teacher/README.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,16 @@ | ||
# Deep Learning to Predict Cardiac Magnetic Resonance-Derived Left Ventricular Mass and Hypertrophy from 12-Lead Electrocardiograms | ||
Three pre-trained models are included here. The model `ecg_rest_raw_age_sex_bmi_lvm_asymmetric_loss.h5` takes as input a 12 Lead resting ECG, as well as age, sex and BMI and has two outputs: one which regresses the left ventricular mass, and a second which gives a probability of left ventricular hypertrophy. | ||
This model was trained with the asymmetric loss described in the paper. The model `ecg_rest_raw_lvm_asymmetric_loss.h5` takes only an ECG as input and regresses left ventricular mass, this model was also trained with the asymmetric loss. | ||
The third model, `ecg_rest_raw_lvm_symmetric_loss.h5` takes only an ECG as input and regresses left ventricular mass, this model was trained with the symmetric logcosh loss. The raw voltage values from the ECG are normalized by dividing by 2000 prior to being input to the model. | ||
|
||
This folder contains models and code supporting the work described in [this paper](https://www.ahajournals.org/doi/10.1161/CIRCIMAGING.120.012281?url_ver=Z39.88-2003&rfr_id=ori:rid:crossref.org&rfr_dat=cr_pub%20%200pubmed) published in the journal Circulation: Cardiovascular Imaging. | ||
|
||
# LVM-AI | ||
Left Ventricular Mass-Artificial Intelligence (LVM-AI) is a one-dimensional convolutional neural network trained to predict CMR-derived LV mass using 12-lead ECGs. LVM-AI was trained within 32239 individuals from the UK Biobank with paired CMR and 12-lead ECG. It was provided with the entire 10 seconds of the 12-lead ECG waveform as well as participant age, sex, and BMI. | ||
LVM-AI was evaluated in a UK Biobank test set as well as an external health care–based Mass General Brigham (MGB) dataset. In both test sets, LVM-AI was compared to with traditional ECG-based rules for diagnosing CMR-derived left ventricular hypertrophy. Associations between LVM-AI predicted LV mass index and incident cardiovascular events were tested in the UK Biobank and a separate MGB-based ambulatory cohort (MGB outcomes) | ||
![Overview of the training and test samples](TrainingAndTestSets.jpg) | ||
When compared with any ECG rule, LVM-AI demonstrated similar LVH discrimination in the UK Biobank (LVM-AI c-statistic 0.653 [95% CI, 0.608 -0.698] versus any ECG rule c-statistic 0.618 [95% CI, 0.574 -0.663], P=0.11) and superior discrimination in MGB (0.621; 95% CI, 0.592 -0.649 versus 0.588; 95% CI, 0.564 -0.611, P=0.02). | ||
|
||
|
||
# Models | ||
Three pre-trained models are included here: | ||
The model `ecg_rest_raw_age_sex_bmi_lvm_asymmetric_loss.h5` takes as input a 12 Lead resting ECG, as well as age, sex and BMI and has two outputs: one which regresses the left ventricular mass, and a second which gives a probability of left ventricular hypertrophy. This model was trained with the asymmetric loss described in the paper. | ||
The model `ecg_rest_raw_lvm_asymmetric_loss.h5` takes only an ECG as input and regresses left ventricular mass. This model was also trained with the asymmetric loss. | ||
The third model, `ecg_rest_raw_lvm_symmetric_loss.h5` takes only an ECG as input and regresses left ventricular mass. This model was trained with the symmetric logcosh loss. The raw voltage values from the ECG are normalized by dividing by 2000 prior to being input to the model. |
3 changes: 3 additions & 0 deletions
3
.../left_ventricular_mass_from_ecg_student_and_mri_teacher/TrainingAndTestSets.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file modified
BIN
-371 KB
(0.034%)
model_zoo/liver_fat_from_mri_ukb/liver_fat_from_echo_teacher_model.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
-423 KB
(0.030%)
model_zoo/liver_fat_from_mri_ukb/liver_fat_from_ideal_student_model.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
link to https://www.sciencedirect.com/science/article/pii/S2666979X21000823