annotate Tests/CheckScuTranscoding.py @ 660:2f6686a3cd16

conditional test
author Alain Mazy <am@orthanc.team>
date Mon, 24 Jun 2024 18:32:13 +0200
parents 5d7b6e43ab7d
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
610
ec657d1a62a6 fix compatibility with python3
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 511
diff changeset
1 #!/usr/bin/env python3
371
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
2
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
3 # Orthanc - A Lightweight, RESTful DICOM Store
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
4 # Copyright (C) 2012-2016 Sebastien Jodogne, Medical Physics
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
5 # Department, University Hospital of Liege, Belgium
649
5d7b6e43ab7d updated copyright, as Orthanc Team now replaces Osimis
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 640
diff changeset
6 # Copyright (C) 2017-2023 Osimis S.A., Belgium
5d7b6e43ab7d updated copyright, as Orthanc Team now replaces Osimis
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 640
diff changeset
7 # Copyright (C) 2024-2024 Orthanc Team SRL, Belgium
640
9f8276ac1cdd update year to 2024
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 610
diff changeset
8 # Copyright (C) 2021-2024 Sebastien Jodogne, ICTEAM UCLouvain, Belgium
371
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
9 #
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
10 # This program is free software: you can redistribute it and/or
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
11 # modify it under the terms of the GNU General Public License as
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
12 # published by the Free Software Foundation, either version 3 of the
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
13 # License, or (at your option) any later version.
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
14 #
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
15 # This program is distributed in the hope that it will be useful, but
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
16 # WITHOUT ANY WARRANTY; without even the implied warranty of
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
17 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
18 # General Public License for more details.
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
19 #
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
20 # You should have received a copy of the GNU General Public License
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
21 # along with this program. If not, see <http://www.gnu.org/licenses/>.
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
22
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
23
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
24 import json
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
25 import os
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
26 import subprocess
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
27 import sys
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
28 import time
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
29 import Toolbox
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
30
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
31
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
32 if len(sys.argv) < 2:
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
33 print('Must provide a path to Orthanc binaries')
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
34 exit(-1)
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
35
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
36
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
37 TMP = '/tmp/OrthancTest'
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
38 TMP_ORTHANC = os.path.join(TMP, 'orthanc')
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
39 TMP_STORESCP = os.path.join(TMP, 'storescp')
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
40
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
41 CONFIG = os.path.join(TMP, 'orthanc', 'Configuration.json')
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
42 ORTHANC = Toolbox.DefineOrthanc()
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
43
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
44 if os.path.exists(TMP):
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
45 print('Temporary path already exists: %s' % TMP)
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
46 exit(-1)
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
47
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
48 os.mkdir(TMP)
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
49 os.mkdir(TMP_ORTHANC)
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
50 os.mkdir(TMP_STORESCP)
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
51
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
52
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
53 def DropOrthanc():
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
54 while True:
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
55 try:
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
56 instances = Toolbox.DoGet(ORTHANC, '/instances')
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
57 if len(instances) == 0:
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
58 break
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
59 else:
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
60 for i in instances:
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
61 Toolbox.DoDelete(ORTHANC, '/instances/%s' % i)
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
62 except:
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
63 # Orthanc is still in its startup process, wait for it to
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
64 # become available
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
65 time.sleep(0.05)
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
66
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
67
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
68 def CreateStorescpConfiguration(acceptedSyntaxes):
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
69 with open(os.path.join(TMP_STORESCP, 'config'), 'w') as f:
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
70 f.write('[[TransferSyntaxes]]\n')
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
71
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
72 f.write('[Accepted]\n')
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
73 for i in range(len(acceptedSyntaxes)):
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
74 f.write('TransferSyntax%d = %s\n' % (i + 1, acceptedSyntaxes[i]))
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
75
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
76 f.write('[[PresentationContexts]]\n')
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
77 f.write('[StorageSCP]\n')
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
78
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
79 # These strings correspond to the SOP class UIDs of the DICOM
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
80 # instances in folder "../Database/TransferSyntaxes/"
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
81 SOP_CLASS_UIDS = [
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
82 '1.2.840.10008.5.1.4.1.1.2',
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
83 '1.2.840.10008.5.1.4.1.1.4',
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
84 '1.2.840.10008.5.1.4.1.1.6',
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
85 '1.2.840.10008.5.1.4.1.1.6.1',
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
86 '1.2.840.10008.5.1.4.1.1.7',
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
87 ]
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
88
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
89 for i in range(len(SOP_CLASS_UIDS)):
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
90 f.write('PresentationContext%d = %s\\Accepted\n' % (i + 1, SOP_CLASS_UIDS[i]))
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
91
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
92 f.write('[[Profiles]]\n')
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
93 f.write('[Default]\n')
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
94 f.write('PresentationContexts = StorageSCP\n')
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
95
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
96
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
97 def TestStore(config, storescpArgs, tests):
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
98 config['DicomModalities'] = {
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
99 'storescp' : [ 'STORESCP', 'localhost', 2000 ]
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
100 }
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
101
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
102 with open(CONFIG, 'w') as f:
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
103 f.write(json.dumps(config))
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
104
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
105 FNULL = open(os.devnull, 'w') # Emulates "subprocess.DEVNULL" on Python 2.7
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
106 process1 = subprocess.Popen(
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
107 sys.argv[1:] + [ CONFIG, '--no-jobs' ], #, '--trace-dicom' ],
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
108 cwd = TMP_ORTHANC,
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
109 #stdout=FNULL,
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
110 stderr=FNULL,
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
111 #shell=True
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
112 )
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
113
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
114 process2 = subprocess.Popen(
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
115 [ 'storescp', '-p', '2000' ] + storescpArgs,
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
116 cwd = TMP_STORESCP,
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
117 #stdout=FNULL,
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
118 #stderr=FNULL,
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
119 #shell=True
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
120 )
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
121
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
122 success = True
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
123
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
124 try:
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
125 for test in tests:
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
126 DropOrthanc()
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
127 for f in os.listdir(TMP_STORESCP):
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
128 os.remove(os.path.join(TMP_STORESCP, f))
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
129
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
130 i = Toolbox.UploadInstance(ORTHANC, test[0]) ['ID']
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
131
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
132 try:
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
133 Toolbox.DoPost(ORTHANC, '/modalities/storescp/store', {
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
134 'Resources' : [ i ],
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
135 'Synchronous' : True,
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
136 })
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
137 except:
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
138 if test[1] != None:
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
139 print('INTERNAL ERROR on: %s' % test[0])
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
140 success = False
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
141 continue
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
142
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
143 f = os.listdir(TMP_STORESCP)
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
144 if len(f) > 1:
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
145 print('INTERNAL ERROR')
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
146 success = False
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
147 elif len(f) == 0:
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
148 if test[1] != None:
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
149 print('No file was received by storescp! %s' % test[0])
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
150 success = False
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
151 else:
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
152 if test[1] == None:
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
153 print('No file should have been received by storescp! %s' % test[0])
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
154 success = False
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
155 else:
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
156 with open(os.path.join(TMP_STORESCP, f[0]), 'rb') as f:
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
157 ts = Toolbox.GetTransferSyntax(f.read())
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
158
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
159 if ts != test[1]:
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
160 print('TRANSFER SYNTAX MISMATCH: observed %s vs. expected %s' % (ts, test[1]))
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
161 success = False
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
162
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
163 except Exception as e:
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
164 print('EXCEPTION: %s' % e)
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
165 success = False
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
166
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
167 process1.terminate()
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
168 process2.terminate()
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
169
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
170 process1.wait()
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
171 process2.wait()
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
172
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
173 return success
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
174
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
175
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
176 def Assert(b):
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
177 if not b:
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
178 raise Exception('Bad result')
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
179
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
180
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
181
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
182 ##
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
183 ## Each test specifies: The input DICOM instance, and the expected
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
184 ## transfer syntax as received by storescp
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
185 ##
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
186
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
187
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
188 print('==== TEST 1 ====')
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
189 Assert(TestStore(
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
190 {
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
191 'DicomScuPreferredTransferSyntax' : '1.2.840.10008.1.2.1', # Little Endian Explicit
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
192 },
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
193 [ '+xa' ], # storescp accepts any transfer syntax
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
194 # (DicomScuPreferredTransferSyntax has no effect)
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
195 [
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
196 ('TransferSyntaxes/1.2.840.10008.1.2.dcm', '1.2.840.10008.1.2'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
197 ('TransferSyntaxes/1.2.840.10008.1.2.1.dcm', '1.2.840.10008.1.2.1'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
198 ('TransferSyntaxes/1.2.840.10008.1.2.2.dcm', '1.2.840.10008.1.2.2'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
199 ('TransferSyntaxes/1.2.840.10008.1.2.4.51.dcm', '1.2.840.10008.1.2.4.51'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
200 ('TransferSyntaxes/1.2.840.10008.1.2.4.70.dcm', '1.2.840.10008.1.2.4.70'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
201 ]))
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
202
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
203
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
204 print('==== TEST 2 ====')
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
205 Assert(TestStore(
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
206 {
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
207 'DicomScuPreferredTransferSyntax' : '1.2.840.10008.1.2.2', # Big Endian
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
208 },
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
209 [ '+xa' ], # storescp accepts any transfer syntax
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
210 # (DicomScuPreferredTransferSyntax has no effect)
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
211 [
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
212 ('TransferSyntaxes/1.2.840.10008.1.2.dcm', '1.2.840.10008.1.2'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
213 ('TransferSyntaxes/1.2.840.10008.1.2.1.dcm', '1.2.840.10008.1.2.1'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
214 ('TransferSyntaxes/1.2.840.10008.1.2.2.dcm', '1.2.840.10008.1.2.2'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
215 ('TransferSyntaxes/1.2.840.10008.1.2.4.51.dcm', '1.2.840.10008.1.2.4.51'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
216 ('TransferSyntaxes/1.2.840.10008.1.2.4.70.dcm', '1.2.840.10008.1.2.4.70'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
217 ]))
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
218
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
219
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
220 print('==== TEST 3 ====')
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
221 Assert(TestStore(
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
222 {
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
223 'DicomScuPreferredTransferSyntax' : '1.2.840.10008.1.2.4.70', # JPEG baseline 12bpp
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
224 },
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
225 [ '+xa' ], # storescp accepts any transfer syntax
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
226 # (DicomScuPreferredTransferSyntax has no effect)
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
227 [
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
228 ('TransferSyntaxes/1.2.840.10008.1.2.dcm', '1.2.840.10008.1.2'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
229 ('TransferSyntaxes/1.2.840.10008.1.2.1.dcm', '1.2.840.10008.1.2.1'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
230 ('TransferSyntaxes/1.2.840.10008.1.2.2.dcm', '1.2.840.10008.1.2.2'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
231 ('TransferSyntaxes/1.2.840.10008.1.2.4.51.dcm', '1.2.840.10008.1.2.4.51'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
232 ('TransferSyntaxes/1.2.840.10008.1.2.4.70.dcm', '1.2.840.10008.1.2.4.70'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
233 ]))
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
234
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
235
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
236 print('==== TEST 4 ====')
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
237 Assert(TestStore(
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
238 {
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
239 'DicomScuPreferredTransferSyntax' : '1.2.840.10008.1.2.1', # Little Endian Explicit
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
240 },
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
241 [ ], # storescp only accepts uncompressed transfer syntaxes
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
242 [
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
243 ('TransferSyntaxes/1.2.840.10008.1.2.dcm', '1.2.840.10008.1.2'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
244 ('TransferSyntaxes/1.2.840.10008.1.2.1.dcm', '1.2.840.10008.1.2.1'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
245 ('TransferSyntaxes/1.2.840.10008.1.2.2.dcm', '1.2.840.10008.1.2.2'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
246 ('TransferSyntaxes/1.2.840.10008.1.2.4.51.dcm', '1.2.840.10008.1.2.1'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
247 ('TransferSyntaxes/1.2.840.10008.1.2.4.70.dcm', '1.2.840.10008.1.2.1'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
248 ]))
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
249
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
250
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
251 print('==== TEST 5 ====')
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
252 Assert(TestStore(
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
253 {
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
254 # Defaults to "1.2.840.10008.1.2.1", Little Endian Explicit
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
255 # (was Little Endian Implicit in Orthanc between 1.7.0 and 1.8.2)
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
256 },
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
257 [ ], # storescp only accepts uncompressed transfer syntaxes
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
258 [
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
259 ('TransferSyntaxes/1.2.840.10008.1.2.dcm', '1.2.840.10008.1.2'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
260 ('TransferSyntaxes/1.2.840.10008.1.2.1.dcm', '1.2.840.10008.1.2.1'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
261 ('TransferSyntaxes/1.2.840.10008.1.2.2.dcm', '1.2.840.10008.1.2.2'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
262 ('TransferSyntaxes/1.2.840.10008.1.2.4.51.dcm', '1.2.840.10008.1.2.1'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
263 ('TransferSyntaxes/1.2.840.10008.1.2.4.70.dcm', '1.2.840.10008.1.2.1'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
264 ]))
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
265
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
266
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
267 print('==== TEST 6 ====')
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
268 Assert(TestStore(
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
269 {
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
270 'DicomScuPreferredTransferSyntax' : '1.2.840.10008.1.2', # Little Endian Implicit
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
271 },
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
272 [ ], # storescp only accepts uncompressed transfer syntaxes
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
273 [
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
274 ('TransferSyntaxes/1.2.840.10008.1.2.dcm', '1.2.840.10008.1.2'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
275 ('TransferSyntaxes/1.2.840.10008.1.2.1.dcm', '1.2.840.10008.1.2.1'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
276 ('TransferSyntaxes/1.2.840.10008.1.2.2.dcm', '1.2.840.10008.1.2.2'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
277 ('TransferSyntaxes/1.2.840.10008.1.2.4.51.dcm', '1.2.840.10008.1.2'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
278 ('TransferSyntaxes/1.2.840.10008.1.2.4.70.dcm', '1.2.840.10008.1.2'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
279 ]))
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
280
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
281
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
282 print('==== TEST 7 ====')
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
283 Assert(TestStore(
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
284 {
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
285 'DicomScuPreferredTransferSyntax' : '1.2.840.10008.1.2.2', # Big Endian
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
286 },
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
287 [ ], # storescp only accepts uncompressed transfer syntaxes
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
288 [
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
289 ('TransferSyntaxes/1.2.840.10008.1.2.dcm', '1.2.840.10008.1.2'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
290 ('TransferSyntaxes/1.2.840.10008.1.2.1.dcm', '1.2.840.10008.1.2.1'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
291 ('TransferSyntaxes/1.2.840.10008.1.2.2.dcm', '1.2.840.10008.1.2.2'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
292 ('TransferSyntaxes/1.2.840.10008.1.2.4.51.dcm', '1.2.840.10008.1.2.2'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
293 ('TransferSyntaxes/1.2.840.10008.1.2.4.70.dcm', '1.2.840.10008.1.2.2'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
294 ]))
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
295
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
296
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
297 print('==== TEST 8 ====')
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
298 Assert(TestStore(
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
299 {
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
300 'DicomScuPreferredTransferSyntax' : '1.2.840.10008.1.2.4.70'
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
301 },
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
302 [ ], # storescp only accepts uncompressed transfer syntaxes,
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
303 # Little Endian Explicit will be chosed by Orthanc (was
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
304 # Little Endian Implicit in Orthanc between 1.7.0 and 1.8.2)
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
305 [
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
306 ('TransferSyntaxes/1.2.840.10008.1.2.dcm', '1.2.840.10008.1.2'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
307 ('TransferSyntaxes/1.2.840.10008.1.2.1.dcm', '1.2.840.10008.1.2.1'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
308 ('TransferSyntaxes/1.2.840.10008.1.2.2.dcm', '1.2.840.10008.1.2.2'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
309 ('TransferSyntaxes/1.2.840.10008.1.2.4.51.dcm', '1.2.840.10008.1.2.1'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
310 ('TransferSyntaxes/1.2.840.10008.1.2.4.70.dcm', '1.2.840.10008.1.2.1'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
311 ]))
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
312
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
313
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
314 print('==== TEST 9 ====')
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
315 Assert(TestStore(
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
316 {
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
317 'DicomScuPreferredTransferSyntax' : '1.2.840.10008.1.2.4.70'
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
318 },
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
319 [ '+xi' ], # storescp only accepts Little Endian Implicit (1.2.840.10008.1.2)
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
320 [
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
321 ('TransferSyntaxes/1.2.840.10008.1.2.dcm', '1.2.840.10008.1.2'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
322 ('TransferSyntaxes/1.2.840.10008.1.2.1.dcm', '1.2.840.10008.1.2'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
323 ('TransferSyntaxes/1.2.840.10008.1.2.2.dcm', '1.2.840.10008.1.2'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
324 ('TransferSyntaxes/1.2.840.10008.1.2.4.51.dcm', '1.2.840.10008.1.2'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
325 ('TransferSyntaxes/1.2.840.10008.1.2.4.70.dcm', '1.2.840.10008.1.2'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
326 ]))
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
327
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
328
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
329 print('==== TEST 10 ====')
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
330 CreateStorescpConfiguration([
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
331 '1.2.840.10008.1.2.4.70',
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
332 ])
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
333 Assert(TestStore(
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
334 {
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
335 'DicomScuPreferredTransferSyntax' : '1.2.840.10008.1.2.4.70'
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
336 },
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
337 [ '-xf', 'config', 'Default' ], # storescp only accepts "1.2.840.10008.1.2.4.70"
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
338 [
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
339 ('TransferSyntaxes/1.2.840.10008.1.2.dcm', '1.2.840.10008.1.2.4.70'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
340 ('TransferSyntaxes/1.2.840.10008.1.2.1.dcm', '1.2.840.10008.1.2.4.70'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
341 ('TransferSyntaxes/1.2.840.10008.1.2.2.dcm', '1.2.840.10008.1.2.4.70'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
342 ('TransferSyntaxes/1.2.840.10008.1.2.4.51.dcm', '1.2.840.10008.1.2.4.70'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
343 ('TransferSyntaxes/1.2.840.10008.1.2.4.70.dcm', '1.2.840.10008.1.2.4.70'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
344 ]))
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
345
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
346
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
347 print('==== TEST 11 ====')
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
348 CreateStorescpConfiguration([
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
349 '1.2.840.10008.1.2.4.57',
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
350 ])
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
351 Assert(TestStore(
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
352 {
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
353 'DicomScuPreferredTransferSyntax' : '1.2.840.10008.1.2.4.70'
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
354 },
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
355 [ '-xf', 'config', 'Default' ],
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
356 [
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
357 ('TransferSyntaxes/1.2.840.10008.1.2.4.57.dcm', '1.2.840.10008.1.2.4.57'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
358
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
359 # All the transfers below will be rejected by storescp
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
360 ('TransferSyntaxes/1.2.840.10008.1.2.dcm', None),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
361 ('TransferSyntaxes/1.2.840.10008.1.2.1.dcm', None),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
362 ('TransferSyntaxes/1.2.840.10008.1.2.2.dcm', None),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
363 ('TransferSyntaxes/1.2.840.10008.1.2.4.51.dcm', None),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
364 ('TransferSyntaxes/1.2.840.10008.1.2.4.70.dcm', None),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
365 ]))
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
366
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
367
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
368 print('==== TEST 12 ====')
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
369 CreateStorescpConfiguration([
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
370 '1.2.840.10008.1.2.4.70',
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
371 '1.2.840.10008.1.2.1',
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
372 ])
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
373 Assert(TestStore(
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
374 {
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
375 'DicomScuPreferredTransferSyntax' : '1.2.840.10008.1.2.4.70'
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
376 },
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
377 [ '-xf', 'config', 'Default' ],
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
378 [
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
379 ('TransferSyntaxes/1.2.840.10008.1.2.dcm', '1.2.840.10008.1.2.4.70'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
380 ('TransferSyntaxes/1.2.840.10008.1.2.1.dcm', '1.2.840.10008.1.2.1'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
381 ('TransferSyntaxes/1.2.840.10008.1.2.2.dcm', '1.2.840.10008.1.2.4.70'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
382 ('TransferSyntaxes/1.2.840.10008.1.2.4.51.dcm', '1.2.840.10008.1.2.4.70'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
383 ('TransferSyntaxes/1.2.840.10008.1.2.4.70.dcm', '1.2.840.10008.1.2.4.70'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
384 ]))
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
385
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
386
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
387 print('==== TEST 13 ====')
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
388 CreateStorescpConfiguration([
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
389 '1.2.840.10008.1.2.4.90',
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
390 '1.2.840.10008.1.2.1',
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
391 ])
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
392 Assert(TestStore(
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
393 {
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
394 # The built-in DCMTK transcoder of Orthanc cannot transcode to
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
395 # JPEG2k, so the fallback "1.2.840.10008.1.2.1" transfer
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
396 # syntax will be used if transcoding is needed
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
397 'DicomScuPreferredTransferSyntax' : '1.2.840.10008.1.2.4.90'
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
398 },
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
399 [ '-xf', 'config', 'Default' ],
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
400 [
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
401 ('TransferSyntaxes/1.2.840.10008.1.2.dcm', '1.2.840.10008.1.2.1'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
402 ('TransferSyntaxes/1.2.840.10008.1.2.1.dcm', '1.2.840.10008.1.2.1'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
403 ('TransferSyntaxes/1.2.840.10008.1.2.2.dcm', '1.2.840.10008.1.2.1'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
404 ('TransferSyntaxes/1.2.840.10008.1.2.4.51.dcm', '1.2.840.10008.1.2.1'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
405 ('TransferSyntaxes/1.2.840.10008.1.2.4.90.dcm', '1.2.840.10008.1.2.4.90'),
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
406 ]))
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
407
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
408
6941a4f449cc CheckScuTranscoding.py
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
409 print('Success!')