Skip to content
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

fill_contour does not exist #8

Open
wantinghuang opened this issue Jun 30, 2020 · 3 comments
Open

fill_contour does not exist #8

wantinghuang opened this issue Jun 30, 2020 · 3 comments

Comments

@wantinghuang
Copy link

Hi,
in tutorial.ipynb, it mentioned fill_contour in FILLING CONTOUR ARRAYS section. This function does not exist in dicom_contour.contour. Is there any alternative function to achieve the same goal?
Thanks in advance.

@marcelvanherk
Copy link
Contributor

marcelvanherk commented Sep 26, 2020

Hi,

I updated the source to no longer need fill_contour. Use get_mask instead that does all the work. It would be great if the original author updated the documentation and would release the python package. This is my sample code:

    roi = dyc.get_mask(image_path, contour_filename, 0)

This will get all masks for the first contour, contour_filename is a full path+filename

Marcel

@TG-Unit
Copy link

TG-Unit commented Nov 1, 2020

Hello @marcelvanherk, i tried your workaround but if I do, I get the error:

AttributeError: 'FileMetaDataset' object has no attribute 'TransferSyntaxUID'

I know this error, usually it can be avoided with setting the metadata yourself by using:

contour_file.TransferSyntaxUID = pydicom.uid.ImplicitVRLittleEndian

This does not seem to work here, would you happen to know a workaround?

BR

@marcelvanherk
Copy link
Contributor

marcelvanherk commented Nov 1, 2020 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants