Is there a convenient way to plot a slice from a patient volume?
See original GitHub issueIs there any convenient way to display for example nth-slice of subject image
of subjects_dataset[0]
?
I want to visualize slices as I apply tranforms to them, the only thing I came up with is converting the the 3D Tensor back to .nii image and from that plotting the slice.
Can you suggest any convenient method ?
Thankyou and much appreciated.
Faraz
Issue Analytics
- State:
- Created 3 years ago
- Comments:25 (20 by maintainers)
Top Results From Across the Web
Robust Super-resolution Volume Reconstruction from Slice ...
Slice sequential acquisitions do not enable 3D volume representation. In this study, we have developed a novel technique based on a slice acquisition...
Read more >Plotting an axial slice from a Nifti image? - Community Chat
I'd like to understand how to plot a slice of the Nifti array in a certain orientation, specifically axial. I thought that the...
Read more >User Interface - 3D Slicer documentation - Read the Docs
Slicer stores all loaded data in a data repository, called the “scene” (or Slicer scene or MRML scene). Each data set, such as...
Read more >Essential Chart Types for Data Visualization | Tutorial by Chartio
Charts are an essential part of working with data, as they are a way to condense large amounts of data into an easy...
Read more >Slice timing correction - Matthew Brett on github
But — it would be convenient if all the voxels in one volume correspond to the same time. Otherwise we would need to...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
It depends on what plane you want to visualize. You can just plot
data[..., n_slice]
. Here’s some code that might be helpful:https://github.com/fepegar/miccai-educational-challenge-2019/blob/94067cdb99830ea21e51964ac9c20a34c28aaea4/visualization.py#L113-L173
It will look like this:
You just need to slice your 3D volume along the third axis, which is the one that goes from inferior (slice 0) to superior (slice 55), if your image is RAS.