-
Notifications
You must be signed in to change notification settings - Fork 455
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
Is there API documentation or source code to describe how to save and load Annotation and Segmentation? What Annotation and Segmentation data structure are? #1137
Comments
IO using open source libraries is still a work in progress. Using dcmjs, a library for DICOM manipulation in JavaScript, its possible to interoperate between cornerstoneTools toolState/labelmaps and DICOM representations. There are live examples of writing labelmaps to DICOMSEG and annotations to DICOMSR (sources here). Although DICOMSEG support is relatively good so far, support for all cornerstone annotations in DICOMSR is lacking, see an open issue here. |
Thanks, @JamesAPetts . I think I need to explain my problem specifically. I have some data in nii (NIFTI) format, and I want to convert it into segments, and overlay them on the dicom element. is it possible? Is there any way to help me achieve my goal. Can you give me some advice? |
Here is a solution |
|
can you make your question clearer? if your problem is like mine, here might be the solution |
@longerking yes, I hava a nifti file containing segmentation data,I have seen your example,But I don’t know how to get the required data from nifti and draw it, Can you give me some advice? |
cornerstoneTools load labelMap or segmentation source as an array, so ,the first thing you need to do is convert the nifti(nii or nii.gz) data into numpy array. You could do it via python module NiBabel |
@longerking Thank you for your reply,I will try. A digression, are you from China? |
Yes and hope my answer will help you.
Yes and hope my answer will help you. |
@longerking 你好,能加个联系方式吗, 想请教下具体实现,谢谢 |
可以,这是我的邮箱: [email protected] |
Prerequisites
Description
Steps to Reproduce the issue
Expected behavior: (What you expected to happen)
Actual behavior: (What actually happened)
CodeSandbox With Reproduction of Issue:
I've added FreehandScissorsTool,but I'm confused about what to do next of saving the Segmentation.
The text was updated successfully, but these errors were encountered: