I am trying to pull images from a server. I am interested in pulling CT images for a specific patient. I am executing the following DCMTK commands from the command prompt (windows):
1) I get the Study Instance UID of my Patient ID (0020,000D)
findscu -v -aet DCMTK -aec VMSDBD 10.196.XX.XXX 51XXX -S -k PatientID=303XXXXX -k QueryRetrieveLevel=STUDY -k 0020,000D
OUTPUT:
....
I: (0010,0020) LO [303XXXXX] # 8, 1 PatientID
I: (0020,000d) UI [1.2.840.113619.2.278.3.346865037.482.15052672XX.XXX ] # 52, 1 StudyInstanceUID
....
2) I get the Series Instance UIDs of the CT modalities present in the study (0020,000E):
findscu -aet DCMTK -aec VMSDBD 10.196.XX.XXX 51XXX -S -k PatientID=3038XXXX -k QueryRetrieveLevel=SERIES -k "0020,000D=1.2.840.113619.2.278.3.346865037.482.1505267XXXX.XXX" -k "0008,0060=CT" -k 0020,000E
OUTPUT:
...
Serie 1: Manufacturer 1
I: (0008,0060) CS [CT] # 2, 1 Modality
I: (0010,0020) LO [3038XXXX] # 8, 1 PatientID
I: (0020,000d) UI [1.2.840.113619.2.278.3.346865037.388.15390421XX.XXX ] # 52, 1 StudyInstanceUID
I: (0020,000e) UI [1.2.246.352.62.2.4715824891563742196.178434434465388XXXX ] # 56, 1 SeriesInstanceUID
I: (0020,0011) IS [2 ] # 2, 1 SeriesNumber
...
Serie 2 : Manufacturer 2
I: (0008,0060) CS [CT] # 2, 1 Modality
I: (0010,0020) LO [3038XXXX] # 8, 1 PatientID
I: (0020,000d) UI [1.2.840.113619.2.278.3.346865037.388.15390421XX.XXX ] # 52, 1 StudyInstanceUID
I: (0020,000e) UI [1.2.840.113619.2.278.3.346865037.388.15390421XX.XXX ] # 56, 1 SeriesInstanceUID
I: (0020,0011) IS [3 ] # 2, 1 SeriesNumber
...
3) I can now just use the Series Instance UIDs to pull the CT images from the server:
movescu –aet DCMTK –aec VMSDBD -aem VMSFSD-OUT –S -k 0008,0052=SERIES -k 0020,000E=1.2.840.113619.2.278.3.346865037.388.15390421XX.XXX 10.196.XX.XXX 51XXX
OUTPUT
...
I: (0020,000e) UI [1.2.840.113619.2.278.3.346865037.388.15390421XX.XXX] # 54, 1 SeriesInstanceUID
I: Received Move Response 1 (Pending)
...
The problem is that the patients have two types of CT series: "ConeBeam CT" and "CT:
But the Modality tag (0008,0060) for both types of CT series is "CT". I just want to pull the "ConeBeam" CT series. With the previous commands I am pulling everything (both of them). i.e. I cannot distinguish "ConeBeam CT" from "CT".
So, Is there any way to differentiate the "ConeBeam CT" series from the "CT" series using the DCMTK commands?
Following is the dump for "ConeBeam CT" header:
(0002,0000) Group Length VR: UL Length: 4 Value: 188
(0002,0001) File Meta Information Version VR: OB Length: 2 Value: 0
(0002,0002) Media Storage SOP Class UID VR: UI Length: 26 Value:
(0002,0003) Media Storage SOP Instance UID VR: UI Length: 58 Value:
(0002,0010) Transfer Syntax UID VR: UI Length: 18 Value:
(0002,0012) Implementation Class UID VR: UI Length: 24 Value:
(0002,0013) Implementation Version Name VR: SH Length: 8 Value: DCIE 2.2
(0008,0005) Specific Character Set VR: CS Length: 10 Value: ISO_IR 192
(0008,0008) Image Type VR: CS Length: 22 Value: ORIGINAL\PRIMARY\AXIAL
(0008,0012) Instance Creation Date VR: DA Length: 8 Value: 20181115
(0008,0013) Instance Creation Time VR: TM Length: 6 Value: 150640
(0008,0016) SOP Class UID VR: UI Length: 26 Value:
(0008,0018) SOP Instance UID VR: UI Length: 58 Value: 1.2.246.352.62.1.4658378903620750311.171271252736726XXXXX
(0008,0020) Study Date VR: DA Length: 8 Value: 20181009
(0008,0021) Series Date VR: DA Length: 8 Value: 20181101
(0008,0022) Acquisition Date VR: DA Length: 8 Value: 20181101
(0008,0023) Image Date VR: DA Length: 8 Value: 20181101
(0008,0030) Study Time VR: TM Length: 6 Value: 111141
(0008,0031) Series Time VR: TM Length: 10 Value: 114125.627
(0008,0032) Acquisition Time VR: TM Length: 10 Value: 114048.727
(0008,0033) Image Time VR: TM Length: 10 Value: 114048.727
(0008,0050) Accession Number VR: SH Length: 0
(0008,0060) Modality VR: CS Length: 2 Value: CT
(0008,0070) Manufacturer VR: LO Length: 22 Value: Varian Medical Systems
(0008,0090) Referring Physician's Name VR: PN Length: 8 Value:
(0008,1010) Station Name VR: SH Length: 10 Value:
(0008,1030) Study Description VR: LO Length: 2 Value: HN
(0008,1048) Physician(s) of Record VR: PN Length: 14 Value:
(0008,1070) Operators' Name VR: PN Length: 14 Value: DICOM Service
(0008,1090) Manufacturer's Model Name VR: LO Length: 10 Value: RDS - PVA
(0008,114A) Referenced Instance Sequence VR: SQ Length: 222
(FFFE,E000)
(0008,1150) Referenced SOP Class UID VR: UI Length: 20 Value:
(0008,1155) Referenced SOP Instance UID VR: UI Length: 52 Value:
(0040,A170) Purpose of Reference Code Sequence VR: SQ Length: 118
(FFFE,E000)
(0008,0100) Code Value VR: SH Length: 4 Value: 1000
(0008,0102) Coding Scheme Designator VR: SH Length: 16 Value: 99VMS_PURPREFOBJ
(0008,0103) Coding Scheme Version VR: SH Length: 4 Value: 1.0
(0008,0104) Code Meaning VR: LO Length: 54 Value: RT Plan or RT Ion Plan or Radiation Set to be verified
(0008,3010) Irradiation Event UID VR: UI Length: 56 Value:
(0010,0010) Patient's Name VR: PN Length: 14 Value:
(0010,0020) Patient ID VR: LO Length: 8 Value: XXXXX
(0010,0030) Patient's Birth Date VR: DA Length: 8 Value:
(0010,0032) Patient's Birth Time VR: TM Length: 6 Value:
(0010,0040) Patient's Sex VR: CS Length: 2 Value:
(0018,0022) Scan Options VR: CS Length: 8 Value: STANDARD
(0018,0050) Slice Thickness VR: DS Length: 16 Value: 1.99621475530568
(0018,0060) KVP VR: DS Length: 4 Value: 100
(0018,0090) Data Collection Diameter VR: DS Length: 16 Value: 492.365501391455
(0018,1000) Device Serial Number VR: LO Length: 4 Value:
(0018,1020) Software Version(s) VR: LO Length: 8 Value:
(0018,1100) Reconstruction Diameter VR: DS Length: 6 Value: 281.6
(0018,1110) Distance Source to Detector VR: DS Length: 4 Value: 1540
(0018,1111) Distance Source to Patient VR: DS Length: 4 Value: 1000
(0018,1120) Gantry/Detector Tilt VR: DS Length: 2 Value: 0
(0018,1130) Table Height VR: DS Length: 6 Value: 166.51
(0018,1140) Rotation Direction VR: CS Length: 2 Value: CC
(0018,1150) Exposure Time VR: IS Length: 4 Value: 4630
(0018,1151) X-Ray Tube Current VR: IS Length: 2 Value: 30
(0018,1152) Exposure VR: IS Length: 4 Value: 138
(0018,1160) Filter Type VR: SH Length: 12 Value: Tit V2,HF V2
(0018,1190) Focal Spot(s) VR: DS Length: 2 Value: 1
(0018,1210) Convolution Kernel VR: SH Length: 4 Value: None
(0018,5100) Patient Position VR: CS Length: 4 Value: HFS
(0018,9345) CTDIvol VR: FD Length: 8 Value: 3.666960
(0018,9346) CTDI Phantom Type Code Sequence VR: SQ Length: 84
(FFFE,E000)
(0008,0100) Code Value VR: SH Length: 6 Value: 113690
(0008,0102) Coding Scheme Designator VR: SH Length: 4 Value: DCM
(0008,0103) Coding Scheme Version VR: SH Length: 8 Value: 20061023
(0008,0104) Code Meaning VR: LO Length: 26 Value: IEC Head Dosimetry Phantom
(0020,000D) Study Instance UID VR: UI Length: 52 Value: 1.2.840.113619.2.278.3.346865037.388.15390421XX.XXX
(0020,000E) Series Instance UID VR: UI Length: 58 Value: 1.2.246.352.62.2.4715824891563742196.178434434465388XXXXX
(0020,0010) Study ID VR: SH Length: 6 Value: XXXXX
(0020,0011) Series Number VR: IS Length: 2 Value: 2
(0020,0012) Acquisition Number VR: IS Length: 2 Value: 1
(0020,0013) Image Number VR: IS Length: 2 Value: 19
(0020,0032) Image Position (Patient) VR: DS Length: 34 Value: -140.525\-140.525\-61.882657414476
(0020,0037) Image Orientation (Patient) VR: DS Length: 12 Value: 1\0\0\0\1\0
(0020,0052) Frame of Reference UID VR: UI Length: 58 Value:
(0020,1040) Position Reference Indicator VR: LO Length: 0
(0020,4000) Image Comments VR: LT Length: 72 Value: Reconstruction Mode THREE_D
Filter STANDARD
Ring Suppression MEDIUM
(0028,0002) Samples per Pixel VR: US Length: 2 Value: 1
(0028,0004) Photometric Interpretation VR: CS Length: 12 Value: MONOCHROME2
(0028,0010) Rows VR: US Length: 2 Value: 512
(0028,0011) Columns VR: US Length: 2 Value: 512
(0028,0030) Pixel Spacing VR: DS Length: 10 Value: 0.55\0.55
(0028,0100) Bits Allocated VR: US Length: 2 Value: 16
(0028,0101) Bits Stored VR: US Length: 2 Value: 16
(0028,0102) High Bit VR: US Length: 2 Value: 15
(0028,0103) Pixel Representation VR: US Length: 2 Value: 0
(0028,1050) Window Center VR: DS Length: 4 Value: -50
(0028,1051) Window Width VR: DS Length: 4 Value: 670
(0028,1052) Rescale Intercept VR: DS Length: 6 Value: -1000
(0028,1053) Rescale Slope VR: DS Length: 2 Value: 1
(0028,1054) Rescale Type VR: LO Length: 2 Value: HU
(300A,0122) Patient Support Angle VR: DS Length: 2 Value: 0
(300A,0129) Table Top Longitudinal Position VR: DS Length: 16 Value: 1518.00350447863
(300A,012A) Table Top Lateral Position VR: DS Length: 16 Value: 9.67474747474753
(3253,0010) VR: LO Length: 34 Value: Varian Medical Systems VISION 3253
(3253,1000) VR: ST Length: 484 Value: (Long Size Data)
(3253,1001) VR: IS Length: 2 Value: 0
(3253,1002) VR: CS Length: 16 Value: ImageProcessing
Following is the dump for CT header:
(0002,0000) Group Length VR: UL Length: 4 Value: 184
(0002,0001) File Meta Information Version VR: OB Length: 2 Value: 0
(0002,0002) Media Storage SOP Class UID VR: UI Length: 26 Value:
(0002,0003) Media Storage SOP Instance UID VR: UI Length: 54 Value:
(0002,0010) Transfer Syntax UID VR: UI Length: 18 Value:
(0002,0012) Implementation Class UID VR: UI Length: 24 Value:
(0002,0013) Implementation Version Name VR: SH Length: 8 Value: DCIE 2.2
(0008,0005) Specific Character Set VR: CS Length: 10 Value: ISO_IR 192
(0008,0008) Image Type VR: CS Length: 22 Value: ORIGINAL\PRIMARY\AXIAL
(0008,0012) Instance Creation Date VR: DA Length: 8 Value: 20181115
(0008,0013) Instance Creation Time VR: TM Length: 6 Value: 151330
(0008,0016) SOP Class UID VR: UI Length: 26 Value:
(0008,0018) SOP Instance UID VR: UI Length: 54 Value: 1.2.840.113619.2.278.3.346865037.388.1539042181.XXX.XX
(0008,0020) Study Date VR: DA Length: 8 Value: 20181009
(0008,0021) Series Date VR: DA Length: 8 Value: 20181009
(0008,0022) Acquisition Date VR: DA Length: 8 Value: 20181009
(0008,0023) Image Date VR: DA Length: 8 Value: 20181009
(0008,0030) Study Time VR: TM Length: 6 Value: 111141
(0008,0031) Series Time VR: TM Length: 6 Value: 111308
(0008,0032) Acquisition Time VR: TM Length: 10 Value: 111515.407
(0008,0033) Image Time VR: TM Length: 6 Value: 111520
(0008,0050) Accession Number VR: SH Length: 0
(0008,0060) Modality VR: CS Length: 2 Value: CT
(0008,0070) Manufacturer VR: LO Length: 18 Value: GE MEDICAL SYSTEMS
(0008,0080) Institution Name VR: LO Length: 26 Value:
(0008,0090) Referring Physician's Name VR: PN Length: 8 Value:
(0008,1010) Station Name VR: SH Length: 4 Value: rtct
(0008,1030) Study Description VR: LO Length: 2 Value: HN
(0008,103E) Series Description VR: LO Length: 12 Value: CHEST 2.5 MM
(0008,1048) Physician(s) of Record VR: PN Length: 14 Value:
(0008,1070) Operators' Name VR: PN Length: 14 Value:
(0008,1090) Manufacturer's Model Name VR: LO Length: 18 Value: Discovery CT590 RT
(0008,1140) Referenced Image Sequence VR: SQ Length: 104
(FFFE,E000)
(0008,1150) Referenced SOP Class UID VR: UI Length: 26 Value:
(0008,1155) Referenced SOP Instance UID VR: UI Length: 54 Value:
(0008,3010) Irradiation Event UID VR: UI Length: 52 Value:
(0010,0010) Patient's Name VR: PN Length: 14 Value:
(0010,0020) Patient ID VR: LO Length: 8 Value: XXXXX
(0010,0030) Patient's Birth Date VR: DA Length: 8 Value:
(0010,0032) Patient's Birth Time VR: TM Length: 6 Value:
(0010,0040) Patient's Sex VR: CS Length: 2 Value:
(0018,0022) Scan Options VR: CS Length: 12 Value: HELICAL MODE
(0018,0050) Slice Thickness VR: DS Length: 4 Value: 2.5
(0018,0060) KVP VR: DS Length: 4 Value: 120
(0018,0090) Data Collection Diameter VR: DS Length: 4 Value: 500
(0018,1000) Device Serial Number VR: LO Length: 2 Value: *
(0018,1020) Software Version(s) VR: LO Length: 10 Value: rt_bjcl.35
(0018,1100) Reconstruction Diameter VR: DS Length: 4 Value: 650
(0018,1110) Distance Source to Detector VR: DS Length: 8 Value: 1062.55
(0018,1111) Distance Source to Patient VR: DS Length: 8 Value: 605.945
(0018,1120) Gantry/Detector Tilt VR: DS Length: 2 Value: 0
(0018,1130) Table Height VR: DS Length: 4 Value: 174
(0018,1140) Rotation Direction VR: CS Length: 2 Value: CW
(0018,1150) Exposure Time VR: IS Length: 4 Value: 856
(0018,1151) X-Ray Tube Current VR: IS Length: 2 Value: 99
(0018,1152) Exposure VR: IS Length: 2 Value: 13
(0018,1160) Filter Type VR: SH Length: 12 Value: BODY FILTER
(0018,1170) Generator Power VR: IS Length: 6 Value: 84000
(0018,1190) Focal Spot(s) VR: DS Length: 4 Value: 1.2
(0018,1210) Convolution Kernel VR: SH Length: 8 Value: STANDARD
(0018,5100) Patient Position VR: CS Length: 4 Value: HFS
(0020,000D) Study Instance UID VR: UI Length: 52 Value: 1.2.840.113619.2.278.3.346865037.388.15390421XX.XXX
(0020,000E) Series Instance UID VR: UI Length: 52 Value: 1.2.840.113619.2.278.3.346865037.388.15390421XX.XXX
(0020,0010) Study ID VR: SH Length: 6 Value: XXXXX
(0020,0011) Series Number VR: IS Length: 2 Value: 2
(0020,0012) Acquisition Number VR: IS Length: 2 Value: 1
(0020,0013) Image Number VR: IS Length: 2 Value: 19
(0020,0032) Image Position (Patient) VR: DS Length: 16 Value: -325\-325\157.5
(0020,0037) Image Orientation (Patient) VR: DS Length: 12 Value: 1\0\0\0\1\0
(0020,0052) Frame of Reference UID VR: UI Length: 60 Value:
(0020,1040) Position Reference Indicator VR: LO Length: 0
(0020,1041) Slice Location VR: DS Length: 6 Value: 157.5
(0028,0002) Samples per Pixel VR: US Length: 2 Value: 1
(0028,0004) Photometric Interpretation VR: CS Length: 12 Value: MONOCHROME2
(0028,0010) Rows VR: US Length: 2 Value: 512
(0028,0011) Columns VR: US Length: 2 Value: 512
(0028,0030) Pixel Spacing VR: DS Length: 18 Value: 1.269531\1.269531
(0028,0100) Bits Allocated VR: US Length: 2 Value: 16
(0028,0101) Bits Stored VR: US Length: 2 Value: 16
(0028,0102) High Bit VR: US Length: 2 Value: 15
(0028,0103) Pixel Representation VR: US Length: 2 Value: 1
(0028,1050) Window Center VR: DS Length: 2 Value: 40
(0028,1051) Window Width VR: DS Length: 4 Value: 400
(0028,1052) Rescale Intercept VR: DS Length: 6 Value: -1000
(0028,1053) Rescale Slope VR: DS Length: 2 Value: 1
(0028,1054) Rescale Type VR: LO Length: 2 Value: HU
One obvious way to achieve this is to filter (while C-FIND) on tag that differentiates the instances. This is what you are trying to achieve. Problem is that, commonly used filters do not include such tag.
As you are working on Series level, there is no such a tag in C-FIND response as well. I am not sure if such a tag is available in Image level C-FIND response; but even if it is, it is not reliable way as many PACS implementations may not return it.
So this is not possible/reliable through C-FIND.
You have to go one step ahead.
You should retrieve the instances (C-MOVE/C-GET) and filter those on your C-STORE SCP.
In that case also, you need to find the tag that differentiates the instances. In your particular case
(0008,0070) Manufacturer
and/or(0008,1090) Manufacturer's Model Name
can be considered.Of-course, this is not generalized or standard solution.