A Python implementation of the DICOM networking protocol based on pydicom. Available at PyPi and GitHub. Provides a library to write DICOM networking applications, and example applications for the supported DICOM Service Class Users (SCUs) and Service Class Providers (SCPs), such as FindSCU/FindSCP, MoveSCP/MoveSCU etc.
More information is available in the official documentation.
Questions tagged [pynetdicom]
21 questions
4
votes
1 answer
C-FIND Study by patient-ID and date
I would like to download the chest x-ray file which matches a specified Patient ID and a Study Date from PACS.
If I specify the date in the C-FIND-Request, I can't get any matched result.
Could you suggest what's wrong with my query?
Thank you very…

annsonic
- 43
- 6
4
votes
1 answer
How to get a list of all SOP instances that were not successfully retrieved during a C-MOVE call?
I'm using PyNetDicom to download (C-MOVE) images from a PACS server. I've implemented a SCU that sends C-MOVE requests to PACS, and a SCP that receives the C-STORE requests.
I download entire studies, meaning a few thousand DICOM images at a time.…

LidiaLu
- 43
- 5
3
votes
3 answers
How does the SCU receive dcm images from Dicom Server with C-GET?
I've seen the official pynetdicom documentation but I've not got the proper event handlers (for the SCU) on receiving images.
First I've created the required .dcm files Dataset and used the C-GET command, which should actually give me the .dcm files…

Sagar Kulkarni
- 483
- 4
- 15
2
votes
1 answer
How to display Series data from DICOM C-FIND results?
I'm new to DICOM and was wondering how I would be able to return results of a C-FIND similar to how applications like Osirix display them after a query.
I'm doing this strictly in Python with pynetdicom and displaying results back in a GUI. At the…

Sun B
- 25
- 1
- 7
2
votes
1 answer
Issue with Setting the Command Set in N_CREATE Response, pydicom
I'm working on a MPPS SCP as described here: MPPS SCP as a basic framework.
I've been able to test it a bit with DVTk, with some tools that are available here: DVTk
Most of it seems to be working correctly, but the issue I seem to be having is…

SScotti
- 2,158
- 4
- 23
- 41
2
votes
1 answer
pynetdicom C_GET failing with No presentation context for 'CT Image Storage' has been accepted by the peer for the SCP role
I am trying to use pynetdicom for the first time. I have it and the ConQuest DICOM server installed on my PC. I am able to get the pynetdicom echo example working, but when I try the pynetdicom Storage SCU example…

wdtj
- 4,554
- 3
- 17
- 20
1
vote
1 answer
Add item to asyncio queue from a request handler
I have a TCP server running and have a handler function which needs to take the contents of the request, add it to an asyncio queue and reply with an OK status.
On the background I have an async coroutine running that detects when a new item is…

Guillermo
- 13
- 4
1
vote
1 answer
Python is crashing due to libdispatch crashing child thread
I am using the pynetdicom library to receive and process medical dicom images. The processing is performed in the callback function "on_association_released". However, when receiving certain studies, it will cause Python to crash due to what appears…

Haris
- 77
- 10
1
vote
1 answer
pynetdicom qyuery/retrive using study date and time
I'm trying the query/retrieve example (qrscu.py) from pynetdicom but
it is working good with the patient name when we search.
But I need to search the study on the basis of studyDate and studyTime.
Note: here some SOP's for DICOM, are available. So…

Jeenit khatri
- 318
- 4
- 19
0
votes
0 answers
pynetdicom failed to acquire patient information from Orthanc
I want to acquire all patient name from a SCP with pynetdicom, but it failed. In my computer, the Orthanc is used as the SCP.
Currently, I have successfully connect Orthanc with pynetdicom by:
from pydicom.dataset import Dataset
from pynetdicom…

Qiang Zhang
- 820
- 8
- 32
0
votes
1 answer
pynetdicom on_association_requested() get request type (C_FIND, C_ECHO etc)
I'm not able to find the variable that holds the Message Type in event name, "on_association_requested" and "on_association_released" methods. If we give event.event.name it results in "EVT_REQUESTED" or "EVT_RELEASED".
INCOMING DIMSE MESSAGE
D:…
0
votes
1 answer
Pynetdicom: Compiled app (exe) can't connect to the PACS-server
I've created an application, that connect to PACS server and Downloaded Studies. Application perfectly work, when i run it from python. But when i create an exe, using pyinstaller - created exe loses the ability to connect to server. log:"Unable to…

boundless power
- 1
- 1
0
votes
0 answers
Pass argument into a function called within a function python
I am trying to pass an event argument from a function to another. The example code that I have now is:
def handle_store(event):
ds = event.dataset
save(ds,event)
def save(ds,event):
ds.file_meta = event.file_meta
…
0
votes
1 answer
Get called_/calling_ae_title
I'm implementing SCP and I'm not sure how to get calling_/called_ae_title correctly.
I'd like to get called_/calling_ae_title during connection(client sending DICOM image) on the server side. I don't enforce called_ae_title(ae.require_called_aet =…

peep
- 15
- 4
0
votes
1 answer
pynetdicom not working correctly with Windows Task Scheduler
I am using a modified version of this pynetdicom script (the second example on this page) to download DICOM images to an office computer. Here is what the script does:
Opens a connection with PACS
Searches for DICOM images that match the current…

bullFrog51
- 1
- 1