Skip to content

pyesapi 16.1 issue with volume, DVH, ... calculation #29

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

Closed
TmnGitHub opened this issue Jun 29, 2024 · 8 comments
Closed

pyesapi 16.1 issue with volume, DVH, ... calculation #29

TmnGitHub opened this issue Jun 29, 2024 · 8 comments

Comments

@TmnGitHub
Copy link

Hello,

I am encountering some strange issues while executing my script. I have been following "Chapter 6. PyESAPI: The Python Interface to ESAPI" and this GitHub page. I am working on Eclipse 16.1

I am able to print the patient ID, last name, and first name for all patients. I can also print C1, but courses dose not show up. Additionally, I can print structure ID and DicomType, as well as ct.XSize and ct.YSize. However, I cannot retrieve the Image.np_array_like(), Volume, or DVH. When I attempt to run these, the process takes a long time and doesn't return any values.

Could you please recommend how I can resolve this issue? My goal is to successfully run Code 6.19 from "Chapter 6. PyESAPI: The Python Interface to ESAPI." which dose the Bulk Extraction of volume, DVH, ...

Thank you in advance for your time and help.

@TmnGitHub TmnGitHub changed the title pyesapi 16.1 issue with volume, DVH calculation pyesapi 16.1 issue with volume, DVH, ... calculation Jun 29, 2024
@TmnGitHub
Copy link
Author

@fizxmike I would appreciate any response on this. Thanks

@fizxmike
Copy link
Member

Hi @TmnGitHub,
Just some quick questions:

  1. Can you share the code you are trying to run?
  2. Are there any popup messages happening (with reference to a logfile)?
  3. Have you tried the code from this notebook?

@TmnGitHub
Copy link
Author

TmnGitHub commented Jul 29, 2024

Hi @fizxmike,

Thank you for taking the time to help me. I am using similar code. There were no pop-up messages. It kept running without any output for hours, so I had to terminate it.

I also tried running it from C#, and the problem occurred at the same stage. However, this time I received a pop-up message in C#. Please see the attached details.
esapi

@fizxmike
Copy link
Member

fizxmike commented Jul 29, 2024

Sometimes the popup will be hiding behind some windows. You can check the windows taskbar to see if python created a new window when you find things are taking too long.

Is your script creating the file in the error message? If not, what type of file is it and where is it trying to write?

@TmnGitHub
Copy link
Author

TmnGitHub commented Jul 29, 2024

Hi @fizxmike,

Thank you for the reply. I ran the same exact code on my patient (3.Have you tried the code from this notebook?). Please find the error attached.

Thanks
pyesapi_error

@fizxmike
Copy link
Member

Ok, since you are getting the same error in C#, I'd say this is not a PyESAPI-specific issue. You can check the ESAPI subreddit to see if some people have seen this error before, if not, try emailing [email protected].

@TmnGitHub
Copy link
Author

Hi @fizxmike,

Thank you very much; I greatly appreciate your help. I will follow your suggestion. On a separate note, I was wondering if we could use pyesapi similarly to how it's done in DICOM_Communication_101. Do you have any Python references for this? Alternatively, I suppose we could retrieve the image using pyesapi and save it locally with ITK for processing.

Thanks a lot for your views.

@fizxmike
Copy link
Member

sure, it is possible. See here: #31

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

2 participants