-
Notifications
You must be signed in to change notification settings - Fork 14
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
Adding model to segment bones #134
Open
gattia
wants to merge
69
commits into
ad12:master
Choose a base branch
from
gattia:bone_seg
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Conversation
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
- qdess bone seg returns each individual tissue - Added map of combined maps.
- qdess bone seg returns each individual tissue - Added map of combined maps.
@gattia thanks for the PR! could you lint your files and provide some same screenshots of the segmentations |
Looks like it's getting hungup during CI because Python 3.6 isn't available anymore? Performed lint on my side + added a photo of the current segs. I'd love to add the two remaining things I have listed on my PR comments, but they're not necessary for this PR and maybe I can do at a later date. |
- if pd > 1.2 then use the new .close syntax. If older, then use old .save syntax. https://stackoverflow.com/questions/76090979/xlsxwriter-object-has-no-attribute-save-did-you-mean-save
- using non-tuple for multidimensional indexing was deprecated. - also remove debug print statements
- if scipy >= 2.0.0 then import center_of_mass from scipy.ndimage - else, if earlier then import from scipy.ndimage.measurements.
- This is only available in python>3.10, therefore removing the requirement in flake8
- Dont need docs for each specific version...
- Number was due to an error in a specifc version (that numba is now past) - SITK was due to change in basis (don't accept non-orthonormal) - but this hasnt been an issue running tests upto now.
- np.complex is deprecated.
- Different versions of tensorflow/keras were returning `tuple` or `tf.TensorShape`. - Create new function to handle both - refactor utils to create this function and the current model loading util functions.
- Codecoverage was throwing rate limiting errors and thus failing CI. -https://github.com/ad12/DOSMA/actions/runs/10459944994/job/28965177349#step:7:83 - Therefore, add if statement to no push codecov under these circumstances.
The current implementation worked somewhat to fix errors with specific image acquisitions, but was somewhat specific to sagittal images. It has now been updated to reformat and then export images to sitk as would be expected for a specific image acquisition type (e.g., sagittal, coronal, axial). Essentially, based on if its sag, ax, or coral, the `mv` will be reformatted. Then, this reformatted image along with the affine/spacing information a new sitk Image will be created. Finally, if the dicom was not collected in this standard orientation, the user can still choose to flip the volume along any of the three axes using boolean flags. New tests were also written to ensure the reformatting is such that the image is roughly what it would be like if SITK itself loaded it.
This is based on a simplification of equations 6/7 of the original Sveinsson et al. paper "A Simple Analytic Method for Estimating T2 in the Knee from DESS". This is required because the new Mensa product sequence does not store these header fields.
This is based on a simplification of equations 6/7 of the original Sveinsson et al. paper "A Simple Analytic Method for Estimating T2 in the Knee from DESS". This is required because the new Mensa product sequence does not store these header fields.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Starting a pull request while working on this to get feedback. A few things are done differently than other models.
connected_only
tomodel.generate_mask
this is because the bones produced a few spurious points in tests. This is on by default for all tissues.The main things I see myself wanting to do/add are:
stanford_qdess.py
models - I think the segmentation performance on this model vs. that are pretty much the same.