From: jpr Date: Fri, 2 Apr 2004 15:47:23 +0000 (+0000) Subject: added shell scripts for various Dicom file checking purpose X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=commitdiff_plain;h=9a657e0f3300ea8b9adb5af74ed06298fb9d813c;p=gdcmData.git added shell scripts for various Dicom file checking purpose --- diff --git a/checkRead.sh b/checkRead.sh index 38625ba..8ab7f09 100644 --- a/checkRead.sh +++ b/checkRead.sh @@ -8,108 +8,109 @@ #No Swap Info #------------ testWrite mr176621.dcm r; -affim filein=mr176621.dcm.raw DIMX=512 DIMY=512 nbit=16 +affim filein=mr176621.dcm.RAW DIMX=512 DIMY=512 nbit=16 # No Transfert Syntax #-------------------- +#Big Endian testWrite cr172241.dcm r; -affim filein=cr172241.dcm.raw DIMX=1792 DIMY=2392 nbit=16 zoom=-4 +affim filein=cr172241.dcm.RAW DIMX=1792 DIMY=2392 nbit=16 zoom=-4 +#0008,0200 (image location) wrongly stored +#0028,3006 (LUT Data) has a CTX VR -testWrite cr_45031.dcm r -affim filein=cr_45031.dcm.raw DIMX=1670 DIMY=2010 nbit=16 zoom=-4 +testWrite cr_45031.dcm r; +affim filein=cr_45031.dcm.RAW DIMX=1670 DIMY=2010 nbit=16 zoom=-4 -testWrite CR-MONO1-10-chest.dcm r -affim filein=CR-MONO1-10-chest.dcm.raw DIMX=440 DIMY=440 nbit=16 +testWrite CR-MONO1-10-chest.dcm r; +affim filein=CR-MONO1-10-chest.dcm.RAW DIMX=440 DIMY=440 nbit=16 -testWrite CT-MONO2-12-lomb-an2.acr2 r -affim filein=CT-MONO2-12-lomb-an2.acr2.raw DIM=512 nbit=16 +testWrite CT-MONO2-12-lomb-an2.acr2 r; +affim filein=CT-MONO2-12-lomb-an2.acr2.RAW DIM=512 nbit=16 -testWrite gdcm-MR-SIEMENS-16.acr1 r -affim filein=gdcm-MR-SIEMENS-16.acr1.raw DIMX=256 DIMY=256 nbit=16 +testWrite gdcm-MR-SIEMENS-16.acr1 r; +affim filein=gdcm-MR-SIEMENS-16.acr1.RAW DIMX=256 DIMY=256 nbit=16 -testWrite gdcm-MR-SIEMENS-16.acr2 r -affim filein=gdcm-MR-SIEMENS-16.acr2.raw DIMX=512 DIMY=512 nbit=16 +testWrite gdcm-MR-SIEMENS-16.acr2 r; +affim filein=gdcm-MR-SIEMENS-16.acr2.RAW DIMX=512 DIMY=512 nbit=16 -testWrite MR-MONO2-12-an2.acr2 r -affim filein=MR-MONO2-12-an2.acr2.raw DIMX=256 DIMY=256 nbit=16 +testWrite MR-MONO2-12-an2.acr2 r; +affim filein=MR-MONO2-12-an2.acr2.RAW DIMX=256 DIMY=256 nbit=16 -testWrite newACR1000.nema r # == gdcmMR-SIEMENS-16.acr2 -affim filein=newACR1000.nema.raw DIMX=512 DIMY=512 nbit=16 +testWrite newACR1000.nema r; # == gdcmMR-SIEMENS-16.acr2 +affim filein=newACR1000.nema.RAW DIMX=512 DIMY=512 nbit=16 -testWrite oldACR00001.ima r # == gdcm-MR-SIEMENS.16.acr1 -affim filein=oldACR00001.ima.raw DIMX=256 DIMY=256 nbit=16 +testWrite oldACR00001.ima r; # == gdcm-MR-SIEMENS.16.acr1 +affim filein=oldACR00001.ima.RAW DIMX=256 DIMY=256 nbit=16 -testWrite OT-MONO2-8-a7.dcm r -affim filein=OT-MONO2-8-a7.dcm.raw DIMX=512 DIMY=512 +testWrite OT-MONO2-8-a7.dcm r; +affim filein=OT-MONO2-8-a7.dcm.RAW DIMX=512 DIMY=512 #No Samples Per Pixel #-------------------- -testWrite gdcm-CR-DCMTK-16-NonSamplePerPix.dcm r -affim filein=gdcm-CR-DCMTK-16-NonSamplePerPix.dcm dim=750 nbit=8 +testWrite gdcm-CR-DCMTK-16-NonSamplePerPix.dcm r; +affim filein=gdcm-CR-DCMTK-16-NonSamplePerPix.dcm.RAW dim=750 nbit=8 #Unnormalized Rectangular LibIDO format image #-------------------------------------------- -testWrite gdcm-ACR-LibIDO.acr r -affim filein=gdcm-ACR-LibIDO.acr.raw dimx=512 dimy=301 +testWrite gdcm-ACR-LibIDO.acr r; +affim filein=gdcm-ACR-LibIDO.acr.RAW dimx=512 dimy=301 #Bits Allocated =12, Bits Stored=12 #---------------------------------- #MR Philips (once upon a time in Lyon-Sud) -testWrite MR-MONO2-12-angio-an1.acr1 r -affim filein=MR-MONO2-12-angio-an1.acr1.raw dim=256 nbit=16 +testWrite MR-MONO2-12-angio-an1.acr1 r; +affim filein=MR-MONO2-12-angio-an1.acr1.RAW dim=256 nbit=16 #RGB #--- -testWrite US.3405.1.dcm r +testWrite US.3405.1.dcm r; echo "expected pixelType=8U SamplesPerPixel=1 PlanarConfiguration=0" echo " PhotometricInterpretation=RGB" -affim filein=US.3405.1.dcm.raw DIMX=768 DIMY=576 nbit=24 +affim filein=US.3405.1.dcm.RAW DIMX=768 DIMY=576 nbit=24 -testWrite OT-PAL-8-face.dcm r +testWrite OT-PAL-8-face.dcm r; echo "expected pixelType=8U SamplesPerPixel=3 PlanarConfiguration=1" echo " PhotometricInterpretation=PALETTE COLOR" -affim filein=OT-PAL-8-face.dcm.raw dimx=640 dimy=480 nbit=24 +affim filein=OT-PAL-8-face.dcm.RAW dimx=640 dimy=480 nbit=24 -testWrite 8BitsUncompressedColor.dcm r -affim filein=8BitsUncompressedColor.dcm.raw dimx=800 dimy=535 nbit=24 +testWrite 8BitsUncompressedColor.dcm r; +affim filein=8BitsUncompressedColor.dcm.RAW dimx=800 dimy=535 nbit=24 # Implicit VR - Little Endian #----------------------------- -testWrite CT-MONO2-16-ankle.dcm r - affim filein=CT-MONO2-16-ankle.dcm.raw DIMX=512 DIMY=512 nbit=16 signe=o +testWrite CT-MONO2-16-ankle.dcm r; + affim filein=CT-MONO2-16-ankle.dcm.RAW DIMX=512 DIMY=512 nbit=16 signe=o -testWrite CT-MONO2-16-ort.dcm r -affim filein=CT-MONO2-16-ort.dcm.raw DIMX=512 DIMY=512 nbit=16 signe=o +testWrite CT-MONO2-16-ort.dcm r; +affim filein=CT-MONO2-16-ort.dcm.RAW DIMX=512 DIMY=512 nbit=16 signe=o -testWrite CT-MONO2-8-abdo.dcm r -affim filein=CT-MONO2-8-abdo.dcm.raw DIMX=512 DIMY=512 +testWrite CT-MONO2-8-abdo.dcm r; +affim filein=CT-MONO2-8-abdo.dcm.RAW DIMX=512 DIMY=512 -testWrite gdcm-MR-PHILIPS-16.dcm r -affim filein=gdcm-MR-PHILIPS-16.dcm.raw DIMX=256 DIMY=256 nbit=16 +testWrite gdcm-MR-PHILIPS-16.dcm r; +affim filein=gdcm-MR-PHILIPS-16.dcm.RAW DIMX=256 DIMY=256 nbit=16 -testWrite MR-MONO2-16-head.dcm r -affim filein=MR-MONO2-16-head.dcm.raw dim=256 nbit=16 signe=o +testWrite MR-MONO2-16-head.dcm r; +affim filein=MR-MONO2-16-head.dcm.RAW dim=256 nbit=16 signe=o -testWrite multiframe1Integris.dcm r -affim filein=multiframe1Integris.dcm.raw dim=1024 nbit=16 zoom=-2 -affim filein=multiframe1Integris.dcm.raw dim=1024 nbit=16 offset=31457280 zoom=-2 +testWrite multiframe1Integris.dcm r; +affim filein=multiframe1Integris.dcm.RAW dim=1024 nbit=16 zoom=-2 +affim filein=multiframe1Integris.dcm.RAW dim=1024 nbit=16 offset=31457280 zoom=-2 -testWrite multiframe2GE.dcm r -affim filein=multiframe2GE.dcm.raw dim=512 -affim filein=multiframe2GE.dcm.raw dim=512 offset=14417920 +testWrite multiframe2GE.dcm r; +affim filein=multiframe2GE.dcm.RAW dim=512 +affim filein=multiframe2GE.dcm.RAW dim=512 offset=14417920 -testWrite irmPhlipsNew1.dcm r # == gdcm-MR-PHILIPS-16.dcm -affim DIMX=256 DIMY=256 filein=irmPhlipsNew1.dcm.raw nbit=16 +testWrite irmPhlipsNew1.dcm r; # == gdcm-MR-PHILIPS-16.dcm +affim DIMX=256 DIMY=256 filein=irmPhlipsNew1.dcm.RAW nbit=16 #avec imagette (icone) -testWrite icone.dcm r -echo "Hopeless till we stop considering the Tag as an identifier inside the Header" -echo "The Tag is an identifier inside the *Dicom Dictionnary* only" +testWrite icone.dcm r; affim filein=icone.dcm bypassacr=1 dim=512 nbit=16 offset=18240 affim filein=icone.dcm dim=64 offset=13984 bypassacr=1 -affim filein=icone.dcm.raw dim=512 nbit=16 +affim filein=icone.dcm.RAW dim=512 nbit=16 #Palette @@ -119,86 +120,88 @@ affim filein=icone.dcm.raw dim=512 nbit=16 #Explicit VR - Little Endian #---------------------------- -testWrite CT-MONO2-16-brain.dcm r -affim filein=CT-MONO2-16-brain.dcm.raw DIMX=512 DIMY=512 nbit=16 signe=o +testWrite CT-MONO2-16-brain.dcm r; +affim filein=CT-MONO2-16-brain.dcm.RAW DIMX=512 DIMY=512 nbit=16 signe=o -testWrite gdcm-MR-PHILIPS-16-Multi-Seq.dcm r -affim filein=gdcm-MR-PHILIPS-16-Multi-Seq.dcm.raw DIMX=128 DIMY=128 nbit=16 +# 7 'first level' SeQuences , 140 'second level' SeQuences ?!? +testWrite gdcm-MR-PHILIPS-16-Multi-Seq.dcm r; +affim filein=gdcm-MR-PHILIPS-16-Multi-Seq.dcm.RAW DIMX=128 DIMY=128 nbit=16 +PrintHeader gdcm-MR-PHILIPS-16-Multi-Seq.dcm 2 -testWrite gdcm-MR-PHILIPS-16-NonRectPix.dcm r -affim filein=gdcm-MR-PHILIPS-16-NonRectPix.dcm.raw DIMX=160 DIMY=64 nbit=16 +testWrite gdcm-MR-PHILIPS-16-NonRectPix.dcm r; +affim filein=gdcm-MR-PHILIPS-16-NonRectPix.dcm.RAW DIMX=160 DIMY=64 nbit=16 -testWrite MR-MONO2-8-16x-heart.dcm r -affim filein=MR-MONO2-8-16x-heart.dcm.raw DIMX=256 DIMY=256 +testWrite MR-MONO2-8-16x-heart.dcm r; +affim filein=MR-MONO2-8-16x-heart.dcm.RAW DIMX=256 DIMY=256 -testWrite NM-MONO2-16-13x-heart.dcm r -affim filein=NM-MONO2-16-13x-heart.dcm.raw DIMX=64 DIMY=64 nbit=16 -affim filein=NM-MONO2-16-13x-heart.dcm.raw DIMX=64 DIMY=64 nbit=16 offset=98304 +testWrite NM-MONO2-16-13x-heart.dcm r; +affim filein=NM-MONO2-16-13x-heart.dcm.RAW DIMX=64 DIMY=64 nbit=16 +affim filein=NM-MONO2-16-13x-heart.dcm.RAW DIMX=64 DIMY=64 nbit=16 offset=98304 -testWrite sonataMonaco.dcm r -affim filein=sonataMonaco.dcm.raw DIMX=256 DIMY=208 nbit=16 +testWrite sonataMonaco.dcm r; +affim filein=sonataMonaco.dcm.RAW DIMX=256 DIMY=208 nbit=16 #MultiFrame -testWrite US-MONO2-8-8x-execho.dcm r -affim filein=US-MONO2-8-8x-execho.dcm.raw DIMX=128 DIMY=120 -affim filein=US-MONO2-8-8x-execho.dcm.raw DIMX=128 DIMY=120 offset=92160 +testWrite US-MONO2-8-8x-execho.dcm r; +affim filein=US-MONO2-8-8x-execho.dcm.RAW DIMX=128 DIMY=120 +affim filein=US-MONO2-8-8x-execho.dcm.RAW DIMX=128 DIMY=120 offset=92160 #RGB -testWrite US-RGB-8-epicard.dcm r +testWrite US-RGB-8-epicard.dcm r; echo "expected pixelType=8U SamplesPerPixel=3 PlanarConfiguration=1" echo " PhotometricInterpretation=RGB" -affim filein=US-RGB-8-epicard.dcm.raw dimx=640 dimy=480 nbit=24 +affim filein=US-RGB-8-epicard.dcm.RAW dimx=640 dimy=480 nbit=24 -testWrite US-RGB-8-esopecho.dcm r +testWrite US-RGB-8-esopecho.dcm r; echo "expected pixelType=8U SamplesPerPixel=3 PlanarConfiguration=0" echo " PhotometricInterpretation=RGB" -affim filein=US-RGB-8-esopecho.dcm.raw dimx=256 dimy=120 nbit=24 +affim filein=US-RGB-8-esopecho.dcm.RAW dimx=256 dimy=120 nbit=24 # Non-Hierarchical, First-Order Prediction (Process 14 [Selection Value 1]) #-------------------------------------------------------------------------- # (JPEG Lossless) testWrite CT-MONO2-16-chest.dcm r; -affim filein=CT-MONO2-16-chest.dcm.raw dimx=512 dimy=400 nbit=16 signe=o +affim filein=CT-MONO2-16-chest.dcm.RAW dimx=512 dimy=400 nbit=16 signe=o -testWrite 012345.002.050.dcm r -affim filein=012345.002.050.dcm.raw dim=256 nbit=16 +testWrite 012345.002.050.dcm r; +affim filein=012345.002.050.dcm.RAW dim=256 nbit=16 testWrite gdcm-JPEG-LossLess3a.dcm r; -affim filein=gdcm-JPEG-LossLess3a.dcm.raw dim=512 nbit=16 +affim filein=gdcm-JPEG-LossLess3a.dcm.RAW dim=512 nbit=16 testWrite XA-MONO2-8-12x-catheter.dcm r; -affim filein=XA-MONO2-8-12x-catheter.dcm.raw dim=512; -affim filein=XA-MONO2-8-12x-catheter.dcm.raw dim=512 offset=262144 -affim filein=XA-MONO2-8-12x-catheter.dcm.raw dim=512 offset=2883584 +affim filein=XA-MONO2-8-12x-catheter.dcm.RAW dim=512; +affim filein=XA-MONO2-8-12x-catheter.dcm.RAW dim=512 offset=262144 +affim filein=XA-MONO2-8-12x-catheter.dcm.RAW dim=512 offset=2883584 testWrite xa_integris.dcm r; echo "a lot of fragments expected here" -affim filein=xa_integris.dcm.raw dim=512 -affim filein=xa_integris.dcm.raw dim=512 offset=13107200 -affim filein=xa_integris.dcm.raw dim=512 offset=19660800 +affim filein=xa_integris.dcm.RAW dim=512 +affim filein=xa_integris.dcm.RAW dim=512 offset=13107200 +affim filein=xa_integris.dcm.RAW dim=512 offset=19660800 -testWrite 16BitsJpegLosslessGrayScale.dcm r -affim filein=16BitsJpegLosslessGrayScale.dcm.raw DIMX=800 DIMY=535 nbit=16 +testWrite 16BitsJpegLosslessGrayScale.dcm r; +affim filein=16BitsJpegLosslessGrayScale.dcm.RAW DIMX=800 DIMY=535 nbit=16 #comming from GE dlx via VTServer -testWrite I9000001.dcm r -affim filein=I9000001.dcm.raw dim=512 -affim filein=I9000001.dcm.raw dim=512 offset=7864320 +testWrite I9000001.dcm r; +affim filein=I9000001.dcm.RAW dim=512 +affim filein=I9000001.dcm.RAW dim=512 offset=7864320 #JPEG Extended (Process 2 & 4) // 16 bits #----------------------------- testWrite gdcm-JPEG-Extended.dcm r; -affim filein=gdcm-JPEG-Extended.dcm.raw dim=512 nbit=16 +affim filein=gdcm-JPEG-Extended.dcm.RAW dim=512 nbit=16 testWrite jpeglossy1.dcm r; -affim filein=jpeglossy1.dcm.raw dim=512 nbit=16 +affim filein=jpeglossy1.dcm.RAW dim=512 nbit=16 #JPEG Baseline (Process 14) #-------------------------- -testWrite MR-MONO2-12-shoulder.dcm r -affim filein=MR-MONO2-12-shoulder.dcm.raw DIMX=1024 DIMY=1024 nbit=16 +testWrite MR-MONO2-12-shoulder.dcm r; +affim filein=MR-MONO2-12-shoulder.dcm.RAW DIMX=1024 DIMY=1024 nbit=16 #fichier format ecat. @@ -209,123 +212,125 @@ affim filein=MR-MONO2-12-shoulder.dcm.raw DIMX=1024 DIMY=1024 nbit=16 #JPEG Baseline (Process 1) #------------------------- # Bracco Files -testWrite US.1.2.dcm r +testWrite US.1.2.dcm r; echo "expected : A lot of Fragments (40), nb Frames = 40 ;-)" echo "expected pixelType=8U SamplesPerPixel=3 PlanarConfiguration=0" echo " PhotometricInterpretation=YBR_FULL_422" -affim filein=US.1.2.dcm.raw DIMX=768 DIMY=576 nbit=24 -affim filein=US.1.2.dcm.raw DIMX=768 DIMY=576 nbit=24 offset=13271040 -affim filein=US.1.2.dcm.raw DIMX=768 DIMY=576 nbit=24 offset=39813120 +affim filein=US.1.2.dcm.RAW DIMX=768 DIMY=576 nbit=24 +affim filein=US.1.2.dcm.RAW DIMX=768 DIMY=576 nbit=24 offset=13271040 +affim filein=US.1.2.dcm.RAW DIMX=768 DIMY=576 nbit=24 offset=39813120 #Sequoia Acusson U11 -testWrite CLIP0001-Sequoia-U11.dcm r -affim filein=CLIP0001-Sequoia-U11.dcm.raw DIMX=768 DIMY=576 nbit=24 -affim filein=CLIP0001-Sequoia-U11.dcm.raw DIMX=768 DIMY=576 nbit=24 offset=1327104 -affim filein=CLIP0001-Sequoia-U11.dcm.raw DIMX=768 DIMY=576 nbit=24 offset=13271040 -affim filein=CLIP0001-Sequoia-U11.dcm.raw DIMX=768 DIMY=576 nbit=24 offset=26542080 +testWrite CLIP0001-Sequoia-U11.dcm r; +echo "Troubles with 0018|6022[SL][Reference Pixel Y(0)] [4294967177] x(7fffffff)" + +affim filein=CLIP0001-Sequoia-U11.dcm.RAW DIMX=768 DIMY=576 nbit=24 +affim filein=CLIP0001-Sequoia-U11.dcm.RAW DIMX=768 DIMY=576 nbit=24 offset=1327104 +affim filein=CLIP0001-Sequoia-U11.dcm.RAW DIMX=768 DIMY=576 nbit=24 offset=13271040 +affim filein=CLIP0001-Sequoia-U11.dcm.RAW DIMX=768 DIMY=576 nbit=24 offset=26542080 #RLE Lossless #------------- -testWrite canadaAloka.dcm r +testWrite canadaAloka.dcm r; echo "expected pixelType=8U SamplesPerPixel=1" echo " PlanarConfiguration=0 PhotometricInterpretation=MONOCHROME2" echo " nb Frames (DIMZ) : 1" -affim filein=canadaAloka.dcm.raw DIMX=608 DIMY=420 +affim filein=canadaAloka.dcm.RAW DIMX=608 DIMY=420 -testWrite FMAG0001.dcm r +testWrite FMAG0001.dcm r; echo "expected pixelType=8U SamplesPerPixel=3" echo " PlanarConfiguration=1 PhotometricInterpretation=YBR_FULL" echo " nb Frames (DIMZ) : 1" -affim filein=FMAG0001.dcm.raw DIMX=768 DIMY=576 nbit=24 +affim filein=FMAG0001.dcm.RAW DIMX=768 DIMY=576 nbit=24 -testWrite QMAG0001.dcm r +testWrite QMAG0001.dcm r; echo "expected pixelType=8U SamplesPerPixel=3" echo " PlanarConfiguration=1 PhotometricInterpretation=YBR_FULL" -affim filein=QMAG0001.dcm.raw DIMX=384 DIMY=288 nbit=24; +affim filein=QMAG0001.dcm.RAW DIMX=384 DIMY=288 nbit=24; -testWrite US-PAL-8-10x-echo.dcm r +testWrite US-PAL-8-10x-echo.dcm r; echo "expected pixelType=8U SamplesPerPixel=1 PlanarConfiguration=0" echo " PhotometricInterpretation=PALETTE COLOR" echo " nb Frames (DIMZ): 10" echo "expected : Parsing 10 'single fragment' Segments" echo " Reading 10 'single fragment' Segments (ouf!)" -affim filein=US-PAL-8-10x-echo.dcm.raw DIMX=600 DIMY=430 nbit=24 -affim filein=US-PAL-8-10x-echo.dcm.raw DIMX=600 DIMY=430 nbit=24 offset=774000 -affim filein=US-PAL-8-10x-echo.dcm.raw DIMX=600 DIMY=430 nbit=24 offset=1548000 -affim filein=US-PAL-8-10x-echo.dcm.raw DIMX=600 DIMY=430 nbit=24 offset=6966000 +affim filein=US-PAL-8-10x-echo.dcm.RAW DIMX=600 DIMY=430 nbit=24 +affim filein=US-PAL-8-10x-echo.dcm.RAW DIMX=600 DIMY=430 nbit=24 offset=774000 +affim filein=US-PAL-8-10x-echo.dcm.RAW DIMX=600 DIMY=430 nbit=24 offset=1548000 +affim filein=US-PAL-8-10x-echo.dcm.RAW DIMX=600 DIMY=430 nbit=24 offset=6966000 -testWrite 8BitsRunLengthGrayScale.dcm r +testWrite 8BitsRunLengthGrayScale.dcm r; echo "expected : correct Gray image" -affim filein=8BitsRunLengthGrayScale.dcm.raw DIMX=800 DIMY=535 +affim filein=8BitsRunLengthGrayScale.dcm.RAW DIMX=800 DIMY=535 -testWrite 8BitsRunLengthColor.dcm r +testWrite 8BitsRunLengthColor.dcm r; echo "expected pixelType=8U SamplesPerPixel=1 PlanarConfiguration=2" echo " PhotometricInterpretation=PALETTE COLOR" echo "expected correct color image" -affim filein=8BitsRunLengthColor.dcm.raw DIMX=800 DIMY=535 nbit=24 +affim filein=8BitsRunLengthColor.dcm.RAW DIMX=800 DIMY=535 nbit=24 #RLE 16 bits --> Try to find some more images -testWrite 16BitsRunLengthGrayScale.dcm r +testWrite 16BitsRunLengthGrayScale.dcm r; echo "expected pixelType=16U SamplesPerPixel=1 PlanarConfiguration=0" echo " PhotometricInterpretation=MONOCHROME2" -affim filein=16BitsRunLengthGrayScale.dcm.raw DIMX=800 DIMY=535 nbit=16 +affim filein=16BitsRunLengthGrayScale.dcm.RAW DIMX=800 DIMY=535 nbit=16 #Were supposed to be bugged #-------------------------- #(break xmedcon) -testWrite 00191113.dcm r -affim filein=00191113.dcm.raw DIMX=512 DIMY=512 -affim filein=00191113.dcm.raw DIMX=512 DIMY=512 offset=786432 +testWrite 00191113.dcm r; +affim filein=00191113.dcm.RAW DIMX=512 DIMY=512 +affim filein=00191113.dcm.RAW DIMX=512 DIMY=512 offset=786432 -testWrite DermaColorLossLess.dcm r -affim filein=DermaColorLossLess.dcm.raw DIMX=117 DIMY=181 nbit=24 +testWrite DermaColorLossLess.dcm r; +affim filein=DermaColorLossLess.dcm.RAW DIMX=117 DIMY=181 nbit=24 -testWrite RadBWLossLess.dcm r -affim filein=RadBWLossLess.dcm.raw DIMX=136 DIMY=92 nbit=16 +testWrite RadBWLossLess.dcm r; +affim filein=RadBWLossLess.dcm.RAW DIMX=136 DIMY=92 nbit=16 #Known as BUGGED ! #---------------- #Rectangular old 24 Bits image -testWrite gdcm-RGB-LibIDORect.acr r -affim filein=gdcm-RGB-LibIDORect.acr.raw DIMX=400 DIMY=100 nbit=24 +testWrite gdcm-RGB-LibIDORect.acr r; +affim filein=gdcm-RGB-LibIDORect.acr.RAW DIMX=400 DIMY=100 nbit=24 #MR GE GENESIS_SIGNA Palo Alto -testWrite DicomSampleNastyGEImage.dcm r +testWrite DicomSampleNastyGEImage.dcm r; echo "WAS expected : wrong lenth (13) for 0008|103e" -affim filein=DicomSampleNastyGEImage.dcm.raw DIMX=256 DIMY=256 nbit=16 +affim filein=DicomSampleNastyGEImage.dcm.RAW DIMX=256 DIMY=256 nbit=16 #MR Philips NTSCAN Hop. Neuro Lyon testWrite philipsMR-lossy.ima r; echo "WAS expected : 'Bogus Huffman table definition' on philipsMR-lossy.ima" echo "IS expected : 'JERR_BAD_HUFF_TABLE sym 16 (>15') but the show goes on" echo "breaks xmedcon" -affim filein=philipsMR-lossy.ima.raw dim=512 nbit=16 +affim filein=philipsMR-lossy.ima.RAW dim=512 nbit=16 #CT Siemens Hop. Salengro Lille testWrite gdcm-JPEG-LossLess3a.dcm r; echo "expected : wrong sequence delimiter (b00c,0eb6) at end of pixels"; echo "xmedcon says 'error: Unexpected end of file'" -affim filein=gdcm-JPEG-LossLess3a.dcm.raw dim=512 nbit=16 +affim filein=gdcm-JPEG-LossLess3a.dcm.RAW dim=512 nbit=16 vtkgdcmViewer gdcm-JPEG-LossLess3a.dcm #CR Philips Thoravision Hop Cardio Lyon -testWrite gdcm-JPEG-LossLessThoravision.dcm r +testWrite gdcm-JPEG-LossLessThoravision.dcm r; echo "expected : 147 fragments,length : 29860 + 145*32760 + 14416" echo "breaks xmedcom, breaks e-film" echo "WAS expected : hashed image -with jLBJpeg-" echo "IS expected : Seg Fault" -affim filein=gdcm-JPEG-LossLessThoravision.dcm.raw DIMX=1876 DIMY=2076 nbit=16 +affim filein=gdcm-JPEG-LossLessThoravision.dcm.RAW DIMX=1876 DIMY=2076 nbit=16 #MR Picker ST. ANTHONY HOSPITAL -testWrite MR.6799.1.dcm r +testWrite MR.6799.1.dcm r; echo "OK; DICOM Image with NO Preamble" -affim filein=MR.6799.1.dcm.raw dim=512 nbit=16 +affim filein=MR.6799.1.dcm.RAW dim=512 nbit=16 #Segmented Palette Color LUT Data -testWrite gdcm-US-ALOKA-16.dcm r +testWrite gdcm-US-ALOKA-16.dcm r; echo "expected pixelType=16U SamplesPerPixel=1 PlanarConfiguration=0" echo " PhotometricInterpretation=PALETTE COLOR" echo "expected : Gray image since 'Segmented xxx Palette Color LUT Data' not yet taken into account" @@ -333,24 +338,24 @@ echo "neither e-film nor DicomWorks deals with the color" echo "breaks xmedcom" echo "breaks vtkgdcmViewer (bad result : 24 bits expected; 16 found in Pixels area)" vtkgdcmViewer gdcm-US-ALOKA-16.dcm -affim dimx=640 dimy=480 filein=gdcm-US-ALOKA-16.dcm.raw nbit=16 +affim dimx=640 dimy=480 filein=gdcm-US-ALOKA-16.dcm.RAW nbit=16 # bugged Siemens 'Leonardo' image -testWrite 8078283Leonardo.dcm r -affim filein=8078283Leonardo.dcm.raw dim=512 nbit=16 +testWrite 8078283Leonardo.dcm r; +affim filein=8078283Leonardo.dcm.RAW dim=512 nbit=16 #CT McTwin Elscint C.H.R.U LILLE C.HURIEZ -testWrite MxTwinLossLess.dcm r -affim filein=MxTwinLossLess.dcm.raw DIMX=512 DIMY=512 nbit=16 +testWrite MxTwinLossLess.dcm r; +affim filein=MxTwinLossLess.dcm.RAW DIMX=512 DIMY=512 nbit=16 # MRI image from VPRO burned CD -testWrite mriThruVPRO.dcm r -affim filein=mriThruVPRO.dcm.raw DIMX=256 DIMY=256 nbit=16 +testWrite mriThruVPRO.dcm r; +affim filein=mriThruVPRO.dcm.RAW DIMX=256 DIMY=256 nbit=16 echo "expected : tasteless SHIT !" echo "breaks Siemens Leonardo viewer . JPEG encoding is bugged?" # gdcm made Theralys image # due to H table, a SeQuence is tagged with 0 length # when using gdcmFile::WriteDcmXXX -testWrite fromTheralys.dcm r -affim filein=fromTheralys.dcm.raw dim=256 nbit=16 +testWrite fromTheralys.dcm r; +affim filein=fromTheralys.dcm.RAW dim=256 nbit=16 diff --git a/checkSequences.sh b/checkSequences.sh new file mode 100644 index 0000000..059ae77 --- /dev/null +++ b/checkSequences.sh @@ -0,0 +1,58 @@ +# Horror Picture Show +# ------------------- + +gdcm-MR-PHILIPS-16-Multi-Seq.dcm # 400 SQ, embedded SQ , O length sequ + +gdcm-MR-PHILIPS-16-NonRectPix.dcm # 22 SQ, embedded SQ , O length sequ + +mriThruVPRO.dcm # 7 SQ O length sequ + +MxTwinLossLess.dcm # 0088|0200 x(59c) [Icon Image Sequence] O length sequ + +icone.dcm # 0008|2112 x(264) [Source Image Sequence] + # 0088|0200 x(362a) [Icon Image Sequence] + + +# Peacefull images +# ---------------- + +canadaAloka.dcm # 0018|6011 x(2f6) [Sequence of Ultrasound Regions ] + +CLIP0001-Sequoia-U11.dcm # 0018|6011 [Sequence of Ultrasound Regions ] + +cr172241.dcm # 0028|3000 x(344) [Modality LUT Sequence] + +fromTheralys.dcm # 0008|1140 x(2f1) [Referenced Image Sequence] + +gdcm-CR-DCMTK-16-NonSamplePerPix.dcm # 0008|1140 x(39a) [Referenced Image Sequence] + # 0008|2112 x(440) [Source Image Sequence] +gdcm-JPEG-Extended.dcm # idem + +gdcm-JPEG-LossLess3a.dcm # 0008|2112 x(378) [Source Image Sequence] + +gdcm-MR-PHILIPS-16.dcm # 0008|1140 x(33c) [Referenced Image Sequence] + +I9000001.dcm # 0028|6100 x(c0e) [Mask Subtraction Sequence] + # 0050|0010 x(c74) [Device Sequence] + +multiframe2GE.dcm # 0028|6100 x(3e) [Mask Subtraction Sequence] + # 0050|0010 x(3c) [Device Sequence] + +irmPhlipsNew1.dcm # 0008|1140 x(33c) [Referenced Image Sequence] + +multiframe1Integris.dcm # 0028|3000 x(66c) [Modality LUT Sequence] + +QMAG0001.dcm # 0008|2112 x(2ac) [Source Image Sequence] + # 0018|6011 x(3b6) [Sequence of Ultrasound Regions ] + +US.1.2.dcm # 0018|6011 x(4b8) [Sequence of Ultrasound Regions ] + +sonataMonaco.dcm # 0008|1140 x(35a) [Referenced Image Sequence] + +xa_integris.dcm # 0008|1111 x(32c) [Referenced Performed Procedure Step Sequence] + # 0029|fd00 x(674) [unkn] + + + + + diff --git a/checkWrite.sh b/checkWrite.sh deleted file mode 100644 index d0fd685..0000000 --- a/checkWrite.sh +++ /dev/null @@ -1,419 +0,0 @@ -# Check READ -#----------- -# -# We just write XDCM Files and AFFIM them -# to be sure the writting was OK -# -# Sebastien Barre's files have no interest here, since the header is -# a *very clean* ACR-NEMA -# Our pb come from DICOM V3, with SQ, shadow groups, etc. - - -#No Swap Info -#------------ -testWrite mr176621.dcm x; -#gdcmParser::CheckSwap: ACR/NEMA unfound swap info (time to raise bets) -PrintHeader mr176621.dcm.XDCM 2 #breaks Tag with uneven length 1463107 in x(8,8) . -v mr176621.dcm.XDCM #breaks : white image -xmedcon mr176621.dcm.XDCM #breaks - -# No Transfert Syntax -#-------------------- -#Big Endian - -testWrite cr172241.dcm x; -PrintHeader cr172241.dcm; #OK -v cr172241.dcm; # breaks -xmedcon cr172241.dcm; # OK -PrintHeader cr172241.dcm.XDCM 2 #down apres 0028|3006 [US][LUT Data (CTX dependent)] -v cr172241.dcm.XDCM # NOT CHECKED -xmedcon cr172241.dcm.XDCM # NOT CHECKED - -testWrite cr_45031.dcm x; -v cr_45031.dcm.XDCM #OK -xmedcon cr_45031.dcm.XDCM #OK - -testWrite CR-MONO1-10-chest.dcm x; -PrintHeader CR-MONO1-10-chest.dcm.XDCM 2 #OK -xmedcon CR-MONO1-10-chest.dcm.XDCM; #OK - -testWrite CT-MONO2-12-lomb-an2.acr2 x; -xmedcon CT-MONO2-12-lomb-an2.acr2.XDCM; #OK -PrintHeader CT-MONO2-12-lomb-an2.acr2.XDCM 2 # OK - -testWrite gdcm-MR-SIEMENS-16.acr1 x; -PrintHeader gdcm-MR-SIEMENS-16.acr1.XDCM 2 ; -#down0009|0000 l:x(46e55) 290389 Of:x(180)384 -v gdcm-MR-SIEMENS-16.acr1.XDCM; #black image -xmedcon gdcm-MR-SIEMENS-16.acr1.XDCM; #breaks - -testWrite gdcm-MR-SIEMENS-16.acr2 x; -PrintHeader gdcm-MR-SIEMENS-16.acr2.XDCM 2; -v gdcm-MR-SIEMENS-16.acr2.XDCM; #OK -xmedcon gdcm-MR-SIEMENS-16.acr2.XDCM; #breaks - -testWrite MR-MONO2-12-an2.acr2 x; -PrintHeader newACR1000.nema.XDCM 2 #down -# 0009|0000 lg :x(46e55) 290389 Off.: x(28a) 650 [Unknown] -xmedcon MR-MONO2-12-an2.acr2.XDCM # NOT CHECKED - -testWrite newACR1000.nema x; # == gdcmMR-SIEMENS-16.acr2 -PrintHeader newACR1000.nema.XDCM; #OK -v newACR1000.nema.XDCM; #OK -xmedcon newACR1000.nema.XDCM ; # breaks : no image found - -testWrite oldACR00001.ima x; # == gdcm-MR-SIEMENS.16.acr1 -PrintHeader oldACR00001.ima.XDCM # OK -v oldACR00001.ima.XDCM; #OK -xmedcon oldACR00001.ima.XDCM # # breaks : no image found - -testWrite OT-MONO2-8-a7.dcm x; -xmedcon OT-MONO2-8-a7.dcm.XDCM 2 #ok - -#No Samples Per Pixel -#-------------------- -testWrite gdcm-CR-DCMTK-16-NonSamplePerPix.dcm x; -affim filein=gdcm-CR-DCMTK-16-NonSamplePerPix.dcm dim=750 nbit=8 -PrintHeader gdcm-CR-DCMTK-16-NonSamplePerPix.dcm.XDCM 2 # OK - -#Unnormalized Rectangular LibIDO format image -#-------------------------------------------- -testWrite gdcm-ACR-LibIDO.acr x; -affim filein=gdcm-ACR-LibIDO.acr.XDCM dimx=512 dimy=301 - -#Bits Allocated =12, Bits Stored=12 -#---------------------------------- -#MR Philips (once upon a time in Lyon-Sud) -testWrite MR-MONO2-12-angio-an1.acr1 x; -v MR-MONO2-12-angio-an1.acr1.XDCM # shitty image -xmedcon R-MONO2-12-angio-an1.acr1.XDCM #pas mieux : warning: Incorrect PixelData length - -#RGB -#--- -testWrite US.3405.1.dcm x; -echo "expected pixelType=8U SamplesPerPixel=1 PlanarConfiguration=0" -echo " PhotometricInterpretation=RGB" -xmedcon US.3405.1.dcm.XDCM #OK - -testWrite OT-PAL-8-face.dcm x; -echo "expected pixelType=8U SamplesPerPixel=3 PlanarConfiguration=1" -echo " PhotometricInterpretation=PALETTE COLOR" -xmedcon OT-PAL-8-face.dcm.XDCM; #OK - -testWrite 8BitsUncompressedColor.dcm x; -xmedcon 8BitsUncompressedColor.dcm.XDCM ; #OK - -# Implicit VR - Little Endian -#----------------------------- - -testWrite CT-MONO2-16-ankle.dcm x; - xmedcon CT-MONO2-16-ankle.dcm.XDCM; #ok - PrintHeader CT-MONO2-16-ankle.dcm 2 #ok - -testWrite CT-MONO2-16-ort.dcm x; -xmedcon CT-MONO2-16-ort.dcm.XDCM #OK -PrintHeader CT-MONO2-16-ort.dcm.XDCM 2 #ok - -testWrite CT-MONO2-8-abdo.dcm x; -xmedcon CT-MONO2-8-abdo.dcm.XDCM #OK - -testWrite gdcm-MR-PHILIPS-16.dcm x; -affim filein=gdcm-MR-PHILIPS-16.dcm.XDCM -#PrintHeader OK; v OK; breaks xmedcom - -testWrite MR-MONO2-16-head.dcm x; -affim filein=MR-MONO2-16-head.dcm.XDCM - -testWrite multiframe1Integris.dcm x; -affim filein=multiframe1Integris.dcm.XDCM dim=1024 nbit=16 zoom=-2 -affim filein=multiframe1Integris.dcm.XDCM dim=1024 nbit=16 offset=31457280 zoom=-2 - PrintHeader CT-MONO2-8-abdo.dcm.XDCM 2 - -testWrite multiframe2GE.dcm x; -v multiframe2GE.dcm.XDCM -#breaks xmedcon -xmedcon multiframe2GE.dcm.XDCM - -testWrite irmPhlipsNew1.dcm x; # == gdcm-MR-PHILIPS-16.dcm -v irmPhlipsNew1.dcm.XDCM; -xmedcon irmPhlipsNew1.dcm.XDCM #breaks - -#avec imagette (icone) - -testWrite icone.dcm x; -PrintHeader icone.dcm.XDCM 2; -#PrintHeader OK; v OK; breaks xmedcom -v icone.dcm.XDCM -xmedcon icone.dcm.XDCM #breaks - -#Palette - -# ??? -# 8 Bits ? -# 16 Bits ? - -#Explicit VR - Little Endian -#---------------------------- -testWrite CT-MONO2-16-brain.dcm x; -xmedcon CT-MONO2-16-brain.dcm.XDCM #OK - -testWrite gdcm-MR-PHILIPS-16-Multi-Seq.dcm x; -PrintHeader gdcm-MR-PHILIPS-16-Multi-Seq.dcm 2 -v gdcm-MR-PHILIPS-16-Multi-Seq.dcm.XDCM #expected : image de *chiottes* -xmedcon gdcm-MR-PHILIPS-16-Multi-Seq.dcm.XDCM #breaks - -testWrite gdcm-MR-PHILIPS-16-NonRectPix.dcm x; -v gdcm-MR-PHILIPS-16-NonRectPix.dcm.XDCM #OK -xmedcon gdcm-MR-PHILIPS-16-NonRectPix.dcm.XDCM #OK - -testWrite MR-MONO2-8-16x-heart.dcm x; #multiframe -v MR-MONO2-8-16x-heart.dcm.XDCM ; #OK -xmedcon MR-MONO2-8-16x-heart.dcm.XDCM #OK - -testWrite NM-MONO2-16-13x-heart.dcm x; #multiframe -xmedcon NM-MONO2-16-13x-heart.dcm.XDCM #OK - -testWrite sonataMonaco.dcm x; -xmedcon sonataMonaco.dcm.XDCM #OK - -#MultiFrame -testWrite US-MONO2-8-8x-execho.dcm x; -PrintHeader US-MONO2-8-8x-execho.dcm.XDCM -xmedcon US-MONO2-8-8x-execho.dcm.XDCM; #OK - -#RGB - -testWrite US-RGB-8-epicard.dcm x; -echo "expected pixelType=8U SamplesPerPixel=3 PlanarConfiguration=1" -echo " PhotometricInterpretation=RGB" - xmedcon US-RGB-8-epicard.dcm.XDCM #OK - -testWrite US-RGB-8-esopecho.dcm x; -echo "expected pixelType=8U SamplesPerPixel=3 PlanarConfiguration=0" -echo " PhotometricInterpretation=RGB" -xmedcon US-RGB-8-esopecho.dcm.XDCM #OK - -# Non-Hierarchical, First-Order Prediction (Process 14 [Selection Value 1]) -#-------------------------------------------------------------------------- -# (JPEG Lossless) - -testWrite CT-MONO2-16-chest.dcm x; -xmedcon CT-MONO2-16-chest.dcm.XDCM #OK - -testWrite 012345.002.050.dcm x; -xmedcon 012345.002.050.dcm.XDCM #OK - -testWrite gdcm-JPEG-LossLess3a.dcm x; -PrintHeader gdcm-JPEG-LossLess3a.dcm.XDCM 2 -xmedcon gdcm-JPEG-LossLess3a.dcm.XDCM #OK - -testWrite XA-MONO2-8-12x-catheter.dcm x; -PrintHeader XA-MONO2-8-12x-catheter.dcm.XDCM 2; -xmedcon XA-MONO2-8-12x-catheter.dcm.XDCM; #OK - -testWrite xa_integris.dcm x; -echo "a lot of fragments expected here" -xmedcon xa_integris.dcm.XDCM #OK - -testWrite 16BitsJpegLosslessGrayScale.dcm x; -xmedcon 16BitsJpegLosslessGrayScale.dcm.XDCM #OK - -#comming from GE dlx via VTServer -v I9000001.dcm; -testWrite I9000001.dcm x; -PrintHeader I9000001.dcm.XDCM 2; -#black image -v I9000001.dcm.XDCM; -#no image found -xmedcon I9000001.dcm.XDCM; - -#JPEG Extended (Process 2 & 4) // 16 bits -#----------------------------- -testWrite gdcm-JPEG-Extended.dcm x; -xmedcon gdcm-JPEG-Extended.dcm.XDCM #OK - -testWrite jpeglossy1.dcm x; -xmedcon jpeglossy1.dcm.XDCM #OK - -#JPEG Baseline (Process 14) -#-------------------------- -testWrite MR-MONO2-12-shoulder.dcm x; -xmedcon MR-MONO2-12-shoulder.dcm.XDCM; #OK - - -#fichier format ecat. -#testWrite imageEcat.ecat r - -#JPEG Lossy 8 bits -#================= -#JPEG Baseline (Process 1) -#------------------------- -# Bracco Files -testWrite US.1.2.dcm x; -echo "expected : A lot of Fragments (40), nb Frames = 40 ;-)" -echo "expected pixelType=8U SamplesPerPixel=3 PlanarConfiguration=0" -echo " PhotometricInterpretation=YBR_FULL_422" -xmedcon US.1.2.dcm.XDCM #OK - -#Sequoia Acusson U11 -testWrite CLIP0001-Sequoia-U11.dcm x; -xmedcon CLIP0001-Sequoia-U11.dcm.XDCM #OK - -#RLE Lossless -#------------- -testWrite canadaAloka.dcm x; -echo "expected pixelType=8U SamplesPerPixel=1" -echo " PlanarConfiguration=0 PhotometricInterpretation=MONOCHROME2" -echo " nb Frames (DIMZ) : 1" -xmedcon canadaAloka.dcm.XDCM - -testWrite jpeglossy1.dcm x; - xmecon jpeglossy1.dcm.XDCM #OK - -testWrite FMAG0001.dcm x; -echo "expected pixelType=8U SamplesPerPixel=3" -echo " PlanarConfiguration=1 PhotometricInterpretation=YBR_FULL" -echo " nb Frames (DIMZ) : 1" -xmedcon FMAG0001.dcm.XDCM #OK - -v QMAG0001.dcm; #OK -xmedcon QMAG0001.dcm; #original breaks xmedcon -testWrite QMAG0001.dcm x; -echo "expected pixelType=8U SamplesPerPixel=3"; -echo " PlanarConfiguration=1 PhotometricInterpretation=YBR_FULL"; -v QMAG0001.dcm.XDCM; #OK -xmedcon QMAG0001.dcm.XDCM; #OK - -testWrite US-PAL-8-10x-echo.dcm x; -echo "expected pixelType=8U SamplesPerPixel=1 PlanarConfiguration=0" -echo " PhotometricInterpretation=PALETTE COLOR" -echo " nb Frames (DIMZ): 10" -echo "expected : Parsing 10 'single fragment' Segments" -echo " Reading 10 'single fragment' Segments (ouf!)" -xmedcon US-PAL-8-10x-echo.dcm.XDCM #OK - -testWrite 8BitsRunLengthGrayScale.dcm x; -echo "expected : correct Gray image" -xmedcon 8BitsRunLengthGrayScale.dcm.XDCM #OK - -testWrite 8BitsRunLengthColor.dcm x; -echo "expected pixelType=8U SamplesPerPixel=1 PlanarConfiguration=2" -echo " PhotometricInterpretation=PALETTE COLOR" -echo "expected correct color image" -xmedcon 8BitsRunLengthColor.dcm.XDCM #OK - -#RLE 16 bits --> Try to find some more images - -testWrite 16BitsRunLengthGrayScale.dcm x; -echo "expected pixelType=16U SamplesPerPixel=1 PlanarConfiguration=0" -echo " PhotometricInterpretation=MONOCHROME2" -xmedcon 16BitsRunLengthGrayScale.dcm.XDCM #OK - -#Were supposed to be bugged -#-------------------------- -#(break xmedcon) - xmedcon 00191113.dcm #No images found -testWrite 00191113.dcm x; -xmedcon 00191113.dcm.XDCM #OK - -xmedcon DermaColorLossLess.dcm; #breaks xmedcon : No images found -testWrite DermaColorLossLess.dcm x; -xmedcon DermaColorLossLess.dcm.XDCM; #breaks xmedcon -#Feb 02 19:33:16 log[2619]: warning: Tag with uneven length -#Feb 02 19:33:16 log[2619]: warning: No transfer syntax found -#Feb 02 19:33:16 log[2619]: error: No images found -v DermaColorLossLess.dcm.XDCM #OK - -#Original breaks xmedcon, breaks v, affimdcm complian ?! -affimdcm filein=RadBWLossLess.dcm; #OK -v RadBWLossLess.dcm; -xmedcon RadBWLossLess.dcm; -testWrite RadBWLossLess.dcm x; -#No pixel found -v RadBWLossLess.dcm.XDCM; #No pixel found -xmedcon RadBWLossLess.dcm.XDCM; - -#Known as BUGGED ! -#---------------- - -#Rectangular old 24 Bits image -testWrite gdcm-RGB-LibIDORect.acr x; -v gdcm-RGB-LibIDORect.acr.XDCM -xmedcon gdcm-RGB-LibIDORect.acr.XDCM #breaks : large Bit Allocated (24) - -#MR GE GENESIS_SIGNA Palo Alto -testWrite DicomSampleNastyGEImage.dcm x; -echo " expected : warning uneven length (13) for 0008|103e" -xmedcon DicomSampleNastyGEImage.dcm.XDCM #OK - -#MR Philips NTSCAN Hop. Neuro Lyon -PrintHeader philipsMR-lossy.ima #breaks PrintHeader ?!? -testWrite philipsMR-lossy.ima x; #NOT CHECKED -echo "WAS expected : 'Bogus Huffman table definition' on philipsMR-lossy.ima" -echo "IS expected : 'JERR_BAD_HUFF_TABLE sym 16 (>15') but the show goes on" -echo "breaks xmedcon" -v philipsMR-lossy.ima.XDCM; #NOT CHECKED -xmedcon philipsMR-lossy.ima.XDCM; #NOT CHECKED - -#CT Siemens Hop. Salengro Lille -testWrite gdcm-JPEG-LossLess3a.dcm x; -echo "expected : wrong sequence delimiter (b00c,0eb6) at end of pixels"; -echo "xmedcon says 'error: Unexpected end of file'" -vtkgdcmViewer gdcm-JPEG-LossLess3a.dcm.XDCM #OK; needs 'R' for display -xmedcon gdcm-JPEG-LossLess3a.dcm.XDCM; #OK - -#CR Philips Thoravision Hop Cardio Lyon -affimdcm filein=gdcm-JPEG-LossLessThoravision.dcm #OK -testWrite gdcm-JPEG-LossLessThoravision.dcm x; -echo "expected : 147 fragments,length : 29860 + 145*32760 + 14416" -echo "breaks xmedcom, breaks e-film" -echo "WAS expected : hashed image -with jLBJpeg-" -echo "IS expected : Seg Fault" -xmedcon gdcm-JPEG-LossLessThoravision.dcm.XDCM # NOT CHECKED - -#MR Picker ST. ANTHONY HOSPITAL -testWrite MR.6799.1.dcm x; -echo "OK; DICOM Image with NO Preamble" -xmedcon MR.6799.1.dcm.XDCM #OK - -#Segmented Palette Color LUT Data -xmedcon gdcm-US-ALOKA-16.dcm; #breaks -vtkgdcmViewer gdcm-US-ALOKA-16.dcm3OK -testWrite gdcm-US-ALOKA-16.dcm x; -echo "expected pixelType=16U SamplesPerPixel=1 PlanarConfiguration=0" -echo " PhotometricInterpretation=PALETTE COLOR" -echo "expected : Gray image since 'Segmented xxx Palette Color LUT Data' not yet taken into account" -echo "neither e-film nor DicomWorks deals with the color" -echo "breaks xmedcom" -echo "breaks vtkgdcmViewer (bad result : 24 bits expected; 16 found in Pixels area)" -vtkgdcmViewer gdcm-US-ALOKA-16.dcm.XDCM #OK -xmedcon gdcm-US-ALOKA-16.dcm.XDCM #breaks -#Feb 03 13:40:19 log[26999]: error: Missing CLUT -#Feb 03 13:40:19 log[26999]: error: No images found - -# bugged Siemens 'Leonardo' image -testWrite 8078283Leonardo.dcm x; -xmedcon 8078283Leonardo.dcm.XDCM #OK - -#CT McTwin Elscint C.H.R.U LILLE C.HURIEZ - xmedcon MxTwinLossLess.dcm #breaks - v MxTwinLossLess.dcm #OK - testWrite MxTwinLossLess.dcm x; - v MxTwinLossLess.dcm.XDCM; #OK - xmedcon MxTwinLossLess.dcm.XDCM #breaks - -# MRI image from VPRO burned CD -v mriThruVPRO.dcm; # Tasteless SHIT -xmedcon mriThruVPRO.dcm; # pas mieux -testWrite mriThruVPRO.dcm x; -v mriThruVPRO.dcm.XDCM -echo "expected : tasteless SHIT !" -echo "breaks Siemens Leonardo viewer . JPEG encoding is bugged?" - -# gdcm made Theralys image -# due to H table, a SeQuence is tagged with 0 length -# when using gdcmFile::WriteDcmXXX -xmedcon fromTheralys.dcm # Original breaks xmedcon -testWrite fromTheralys.dcm x; -v fromTheralys.dcm.XDCM; # OK (unsolved Length = 13 ...) -xmedcon fromTheralys.dcm.XDCM # Breaks : no image found diff --git a/checkWriteExplicit.sh b/checkWriteExplicit.sh index 2fcb294..2461e2c 100644 --- a/checkWriteExplicit.sh +++ b/checkWriteExplicit.sh @@ -16,7 +16,7 @@ #------------ testWrite mr176621.dcm x; PrintHeader mr176621.dcm.XDCM 2; . -v mr176621.dcm.XDCM; # white image +v mr176621.dcm.XDCM; # OK xmedcon mr176621.dcm.XDCM; #breaks because 'DICM" without group 0000 # Write DCM needs 'CheckFileHeaderConsistency' method @@ -24,7 +24,9 @@ xmedcon mr176621.dcm.XDCM; #breaks because 'DICM" without group 0000 #-------------------- #Big Endian -affimdcm filein=cr172241.dcm.XDCM zoom=-4; + +# ------------------------------------------- BIG SOUCY !! +affimdcm filein=cr172241.dcm zoom=-4; xmedcon cr172241.dcm; # OK testWrite cr172241.dcm r; @@ -34,24 +36,25 @@ PrintHeader cr172241.dcm 2; #OK v cr172241.dcm; # breaks (white image) WHITE IMAGE ?!? # Doesn't break DaVaW ... testWrite cr172241.dcm x; -PrintHeader cr172241.dcm.XDCM 2; #OK -xmedcon cr172241.dcm.XDCM; # OK -v cr172241.dcm.XDCM; # breaks ?!? White image ! +PrintHeader cr172241.dcm.XDCM 2; #OK +xmedcon cr172241.dcm.XDCM; # OK Incorrect OB value representation (fixed) +affimdcm filein=cr172241.dcm.XDCM; # OK +v cr172241.dcm.XDCM; # breaks ?!? White image ! testWrite cr_45031.dcm x; -v cr_45031.dcm.XDCM; #OK +v cr_45031.dcm.XDCM; #OK xmedcon cr_45031.dcm.XDCM; #OK testWrite CR-MONO1-10-chest.dcm x; PrintHeader CR-MONO1-10-chest.dcm.XDCM 2; #OK -v CR-MONO1-10-chest.dcm.XDCM; -xmedcon CR-MONO1-10-chest.dcm.XDCM; #OK +v CR-MONO1-10-chest.dcm.XDCM; #OK +xmedcon CR-MONO1-10-chest.dcm.XDCM; #OK Incorrect OB value representation (fixed) testWrite CT-MONO2-12-lomb-an2.acr2 x; PrintHeader CT-MONO2-12-lomb-an2.acr2.XDCM 2; # OK v CT-MONO2-12-lomb-an2.acr2.XDCM; #OK -xmedcon CT-MONO2-12-lomb-an2.acr2.XDCM; #OK +xmedcon CT-MONO2-12-lomb-an2.acr2.XDCM; #OK Incorrect OB value representation (fixed) xmedcon gdcm-MR-SIEMENS-16.acr1; # Original OK PrintHeader gdcm-MR-SIEMENS-16.acr1; #OK @@ -64,7 +67,8 @@ xmedcon gdcm-MR-SIEMENS-16.acr2 #original OK testWrite gdcm-MR-SIEMENS-16.acr2 x; PrintHeader gdcm-MR-SIEMENS-16.acr2.XDCM 2; v gdcm-MR-SIEMENS-16.acr2.XDCM; #OK -xmedcon gdcm-MR-SIEMENS-16.acr2.XDCM; #breaks +xmedcon gdcm-MR-SIEMENS-16.acr2.XDCM; #breaks + # --> TODO fix group length for odd groups #Feb 03 18:50:24 log[4419]: warning: No transfer syntax found #Feb 03 18:50:24 log[4419]: warning: Tag with uneven length #Feb 03 18:50:24 log[4419]: error: No images found @@ -93,8 +97,8 @@ xmedcon OT-MONO2-8-a7.dcm.XDCM ; #OK testWrite gdcm-CR-DCMTK-16-NonSamplePerPix.dcm x; affim filein=gdcm-CR-DCMTK-16-NonSamplePerPix.dcm; PrintHeader gdcm-CR-DCMTK-16-NonSamplePerPix.dcm.XDCM 2; # OK -v gdcm-CR-DCMTK-16-NonSamplePerPix.dcm.XDCM; #OK -xmedcon gdcm-CR-DCMTK-16-NonSamplePerPix.dcm.XDCM #OK +v gdcm-CR-DCMTK-16-NonSamplePerPix.dcm.XDCM; #OK +xmedcon gdcm-CR-DCMTK-16-NonSamplePerPix.dcm.XDCM #OK #Unnormalized Rectangular LibIDO format image #-------------------------------------------- @@ -117,10 +121,13 @@ echo " PhotometricInterpretation=RGB"; v US.3405.1.dcm.XDCM; #OK xmedcon US.3405.1.dcm.XDCM; #OK +# ------------------------------------------- KING SIZE SOUCY !! + testWrite OT-PAL-8-face.dcm x; echo "expected pixelType=8U SamplesPerPixel=3 PlanarConfiguration=1"; echo " PhotometricInterpretation=PALETTE COLOR"; PrintHeaderOT-PAL-8-face.dcm.XDCM; OK +affimdcm filein=OT-PAL-8-face.dcm.XDCM; #OK v OT-PAL-8-face.dcm.XDCM; # seg fault .!? xmedcon OT-PAL-8-face.dcm.XDCM; #OK @@ -180,7 +187,7 @@ echo "so many 0xfffe ! (274)" testWrite icone.dcm x; PrintHeader icone.dcm.XDCM 2; #PrintHeader OK; v OK; breaks xmedcom -v icone.dcm.XDCM; # shitty image +v icone.dcm.XDCM; # shitty image --> TODO : FIX (once again)icon pb xmedcon icone.dcm.XDCM; #breaks #Palette @@ -192,7 +199,7 @@ xmedcon icone.dcm.XDCM; #breaks #Explicit VR - Little Endian #---------------------------- testWrite CT-MONO2-16-brain.dcm x; -v CT-MONO2-16-brain.dcm.XDCM; #OK +v CT-MONO2-16-brain.dcm.XDCM; #OK xmedcon CT-MONO2-16-brain.dcm.XDCM; #OK PrintHeader gdcm-MR-PHILIPS-16-Multi-Seq.dcm 2; @@ -201,28 +208,30 @@ v gdcm-MR-PHILIPS-16-Multi-Seq.dcm; #OK testWrite gdcm-MR-PHILIPS-16-Multi-Seq.dcm x; PrintHeader gdcm-MR-PHILIPS-16-Multi-Seq.dcm.XDCM 2; #pixel group missing??!? #v gdcm-MR-PHILIPS-16-Multi-Seq.dcm.XDCM; #shitty image, ofcourse -xmedcon gdcm-MR-PHILIPS-16-Multi-Seq.dcm.XDCM; # works ?!? +xmedcon gdcm-MR-PHILIPS-16-Multi-Seq.dcm.XDCM; # works ?!? +v gdcm-MR-PHILIPS-16-Multi-Seq.dcm.XDCM; + testWrite gdcm-MR-PHILIPS-16-NonRectPix.dcm x; v gdcm-MR-PHILIPS-16-NonRectPix.dcm.XDCM; #OK xmedcon gdcm-MR-PHILIPS-16-NonRectPix.dcm.XDCM; #OK warning: Incorrect sequence length -testWrite MR-MONO2-8-16x-heart.dcm x; #multiframe # equals to ??? -v MR-MONO2-8-16x-heart.dcm.XDCM; #OK +testWrite MR-MONO2-8-16x-heart.dcm x; #multiframe # equals to ??? +v MR-MONO2-8-16x-heart.dcm.XDCM; #OK xmedcon MR-MONO2-8-16x-heart.dcm.XDCM; #OK testWrite NM-MONO2-16-13x-heart.dcm x; #multiframe -v NM-MONO2-16-13x-heart.dcm.XDCM; #OK +v NM-MONO2-16-13x-heart.dcm.XDCM; #OK xmedcon NM-MONO2-16-13x-heart.dcm.XDCM; #OK testWrite sonataMonaco.dcm x; -v sonataMonaco.dcm.XDCM; #OK +v sonataMonaco.dcm.XDCM; #OK xmedcon sonataMonaco.dcm.XDCM; #OK #MultiFrame testWrite US-MONO2-8-8x-execho.dcm x; PrintHeader US-MONO2-8-8x-execho.dcm.XDCM; -v US-MONO2-8-8x-execho.dcm.XDCM; # OK +v US-MONO2-8-8x-execho.dcm.XDCM; # OK xmedcon US-MONO2-8-8x-execho.dcm.XDCM; #OK #RGB diff --git a/checkWriteImplicit.sh b/checkWriteImplicit.sh new file mode 100644 index 0000000..4ca29d8 --- /dev/null +++ b/checkWriteImplicit.sh @@ -0,0 +1,435 @@ +# Check READ +#----------- +# +# We just write DCM Files and AFFIM them +# to be sure the writting was OK +# +# Sebastien Barre's files have no interest here, since the header is +# a *very clean* ACR-NEMA +# Our pb come from DICOM V3, with SQ, shadow groups, etc. + + +#No Swap Info +#------------ +testWrite mr176621.dcm d; +#gdcmParser::CheckSwap: ACR/NEMA unfound swap info (time to raise bets) +PrintHeader mr176621.dcm.DCM 2; . +v mr176621.dcm.DCM; #OK +xmedcon mr176621.dcm.DCM; #OK + +# No Transfert Syntax +#-------------------- + +#Big Endian +testWrite cr172241.dcm r; # Big Soucy !! +affim filein=cr172241.dcm.RAW nbit=16 DIMX=1792 DIMY=2392; #OK +PrintHeader cr172241.dcm 2; #OK +v cr172241.dcm; # breaks (white image) WHITE IMAGE ?!? +xmedcon cr172241.dcm; # OK +#-- +testWrite cr172241.dcm d; +PrintHeader cr172241.dcm.DCM 2; #OK +v cr172241.dcm.DCM; # breaks ?!? +xmedcon cr172241.dcm.DCM; # OK + +testWrite cr_45031.dcm d; +v cr_45031.dcm.DCM; #OK +xmedcon cr_45031.dcm.DCM; #OK + +testWrite CR-MONO1-10-chest.dcm d; +PrintHeader CR-MONO1-10-chest.dcm.DCM 2; #OK +xmedcon CR-MONO1-10-chest.dcm.DCM; #OK + +testWrite CT-MONO2-12-lomb-an2.acr2 d; +PrintHeader CT-MONO2-12-lomb-an2.acr2.DCM 2; # OK +v CT-MONO2-12-lomb-an2.acr2.DCM; #OK +xmedcon CT-MONO2-12-lomb-an2.acr2.DCM; #OK + +PrintHeader gdcm-MR-SIEMENS-16.acr1; #OK +testWrite gdcm-MR-SIEMENS-16.acr1 d; +PrintHeader gdcm-MR-SIEMENS-16.acr1.DCM 2 ; +v gdcm-MR-SIEMENS-16.acr1.DCM; +xmedcon gdcm-MR-SIEMENS-16.acr1.DCM; #breaks error: No images found +xmedcon gdcm-MR-SIEMENS-16.acr1; # OK + +testWrite gdcm-MR-SIEMENS-16.acr2 d; +PrintHeader gdcm-MR-SIEMENS-16.acr2.DCM 2; +v gdcm-MR-SIEMENS-16.acr2.DCM; #OK +xmedcon gdcm-MR-SIEMENS-16.acr2.DCM; #breaks +#Feb 03 18:50:24 log[4419]: warning: No transfer syntax found +#Feb 03 18:50:24 log[4419]: warning: Tag with uneven length +#Feb 03 18:50:24 log[4419]: error: No images found + +testWrite MR-MONO2-12-an2.acr2 d; +PrintHeader newACR1000.nema.DCM 2; +xmedcon MR-MONO2-12-an2.acr2.DCM; # NOT CHECKED + +testWrite newACR1000.nema d; # == gdcmMR-SIEMENS-16.acr2 +PrintHeader newACR1000.nema.DCM; #OK +v newACR1000.nema.DCM; #OK +xmedcon newACR1000.nema.DCM; # breaks : no image found + +testWrite oldACR00001.ima d; # == gdcm-MR-SIEMENS.16.acr1 +PrintHeader oldACR00001.ima.DCM; # OK +v oldACR00001.ima.DCM; #OK +xmedcon oldACR00001.ima.DCM; # breaks : no image found + +testWrite OT-MONO2-8-a7.dcm d; +xmedcon OT-MONO2-8-a7.dcm.DCM 2; #ok + +#No Samples Per Pixel +#-------------------- +testWrite gdcm-CR-DCMTK-16-NonSamplePerPix.dcm d; +affim filein=gdcm-CR-DCMTK-16-NonSamplePerPix.dcm; +PrintHeader gdcm-CR-DCMTK-16-NonSamplePerPix.dcm.DCM 2; # OK + +#Unnormalized Rectangular LibIDO format image +#-------------------------------------------- +testWrite gdcm-ACR-LibIDO.acr d; +v gdcm-ACR-LibIDO.acr.DCM; +xmedcon gdcm-ACR-LibIDO.acr.DCM; + +#Bits Allocated =12, Bits Stored=12 +#---------------------------------- +#MR Philips (once upon a time in Lyon-Sud) +testWrite MR-MONO2-12-angio-an1.acr1 d; +v MR-MONO2-12-angio-an1.acr1.DCM; # shitty image +xmedcon R-MONO2-12-angio-an1.acr1.DCM;#pas mieux : warning: Incorrect PixelData length + +#RGB +#--- +testWrite US.3405.1.dcm d; +echo "expected pixelType=8U SamplesPerPixel=1 PlanarConfiguration=0"; +echo " PhotometricInterpretation=RGB"; +xmedcon US.3405.1.dcm.DCM; #OK + +testWrite OT-PAL-8-face.dcm d; +echo "expected pixelType=8U SamplesPerPixel=3 PlanarConfiguration=1"; +echo " PhotometricInterpretation=PALETTE COLOR"; +xmedcon OT-PAL-8-face.dcm.DCM; #OK + +testWrite 8BitsUncompressedColor.dcm d; +xmedcon 8BitsUncompressedColor.dcm.DCM ; #OK + +# Implicit VR - Little Endian +#----------------------------- + +testWrite CT-MONO2-16-ankle.dcm d; + xmedcon CT-MONO2-16-ankle.dcm.DCM; #ok + PrintHeader CT-MONO2-16-ankle.dcm 2; #ok + +testWrite CT-MONO2-16-ort.dcm d; +xmedcon CT-MONO2-16-ort.dcm.DCM; #OK +PrintHeader CT-MONO2-16-ort.dcm.DCM 2; #ok + +testWrite CT-MONO2-8-abdo.dcm d; +xmedcon CT-MONO2-8-abdo.dcm.DCM; #OK + +testWrite gdcm-MR-PHILIPS-16.dcm d; +PrintHeader gdcm-MR-PHILIPS-16.dcm.DCM 2; #OK +v gdcm-MR-PHILIPS-16.dcm.DCM; # OK +xmedcom gdcm-MR-PHILIPS-16.dcm.DCM; # error: No images found +xmedcom gdcm-MR-PHILIPS-16.dcm; # OK with original image + +testWrite MR-MONO2-16-head.dcm d; +xmedcon MR-MONO2-16-head.dcm.DCM; #OK + +testWrite multiframe1Integris.dcm d; +PrintHeader CT-MONO2-8-abdo.dcm.DCM 2; #OK +v multiframe1Integris.dcm.DCM; #OK +xmedcon multiframe1Integris.dcm.DCM; #breaks No images found + +testWrite multiframe2GE.dcm d; +v multiframe2GE.dcm.DCM; #OK +#breaks xmedcon +xmedcon multiframe2GE.dcm.DCM; #breaks No images found + +v irmPhlipsNew1.dcm; +testWrite irmPhlipsNew1.dcm d; # == gdcm-MR-PHILIPS-16.dcm +v irmPhlipsNew1.dcm.DCM; # black image +xmedcon irmPhlipsNew1.dcm.DCM; #breaks + +#avec imagette (icone) + +testWrite icone.dcm d; +PrintHeader icone.dcm.DCM 2; +#PrintHeader OK; v OK; breaks xmedcom +v icone.dcm.DCM; +xmedcon icone.dcm.DCM; #breaks + +#Palette + +# ??? +# 8 Bits ? +# 16 Bits ? + +#Explicit VR - Little Endian +#---------------------------- +testWrite CT-MONO2-16-brain.dcm d; +xmedcon CT-MONO2-16-brain.dcm.DCM; #OK + +PrintHeader gdcm-MR-PHILIPS-16-Multi-Seq.dcm 2; +xmedcon gdcm-MR-PHILIPS-16-Multi-Seq.dcm #OK :Skip PHILIPS premature item bug +v gdcm-MR-PHILIPS-16-Multi-Seq.dcm; #OK +testWrite gdcm-MR-PHILIPS-16-Multi-Seq.dcm d; +PrintHeader gdcm-MR-PHILIPS-16-Multi-Seq.dcm.DCM 2; #pixel group missing ?!? +v gdcm-MR-PHILIPS-16-Multi-Seq.dcm.DCM; #NOT CHECKED +xmedcon gdcm-MR-PHILIPS-16-Multi-Seq.dcm.DCM; #breaks + +testWrite gdcm-MR-PHILIPS-16-NonRectPix.dcm d; +v gdcm-MR-PHILIPS-16-NonRectPix.dcm.DCM; #OK +xmedcon gdcm-MR-PHILIPS-16-NonRectPix.dcm.DCM; #OK + +testWrite MR-MONO2-8-16x-heart.dcm d; #multiframe +v MR-MONO2-8-16x-heart.dcm.DCM; #OK +xmedcon MR-MONO2-8-16x-heart.dcm.DCM; #OK + +testWrite NM-MONO2-16-13x-heart.dcm d; #multiframe +xmedcon NM-MONO2-16-13x-heart.dcm.DCM; #OK + +testWrite sonataMonaco.dcm d; +xmedcon sonataMonaco.dcm.DCM; #OK + +#MultiFrame +testWrite US-MONO2-8-8x-execho.dcm d; +PrintHeader US-MONO2-8-8x-execho.dcm.DCM; +xmedcon US-MONO2-8-8x-execho.dcm.DCM; #OK + +#RGB + +testWrite US-RGB-8-epicard.dcm d; +echo "expected pixelType=8U SamplesPerPixel=3 PlanarConfiguration=1"; +echo " PhotometricInterpretation=RGB"; + xmedcon US-RGB-8-epicard.dcm.DCM; #OK + +testWrite US-RGB-8-esopecho.dcm d; +echo "expected pixelType=8U SamplesPerPixel=3 PlanarConfiguration=0"; +echo " PhotometricInterpretation=RGB", +xmedcon US-RGB-8-esopecho.dcm.DCM; #OK + +# Non-Hierarchical, First-Order Prediction (Process 14 [Selection Value 1]) +#-------------------------------------------------------------------------- +# (JPEG Lossless) + +testWrite CT-MONO2-16-chest.dcm d; +xmedcon CT-MONO2-16-chest.dcm.DCM; #OK + +testWrite 012345.002.050.dcm d; +xmedcon 012345.002.050.dcm.DCM; #OK + +testWrite gdcm-JPEG-LossLess3a.dcm d; +PrintHeader gdcm-JPEG-LossLess3a.dcm.DCM 2; +xmedcon gdcm-JPEG-LossLess3a.dcm.DCM; #OK + +testWrite XA-MONO2-8-12x-catheter.dcm d; +PrintHeader XA-MONO2-8-12x-catheter.dcm.DCM 2; +xmedcon XA-MONO2-8-12x-catheter.dcm.DCM; #OK + +testWrite xa_integris.dcm d; +echo "a lot of fragments expected here"; +xmedcon xa_integris.dcm.DCM #OK + +testWrite 16BitsJpegLosslessGrayScale.dcm d; +xmedcon 16BitsJpegLosslessGrayScale.dcm.DCM #OK + +#comming from GE dlx via VTServer +v I9000001.dcm; +testWrite I9000001.dcm d; +PrintHeader I9000001.dcm.DCM 2; +#black image +v I9000001.dcm.DCM; +#no image found +xmedcon I9000001.dcm.DCM; + +#JPEG Extended (Process 2 & 4) // 16 bits +#----------------------------- +testWrite gdcm-JPEG-Extended.dcm d; +xmedcon gdcm-JPEG-Extended.dcm.DCM; #OK + +testWrite jpeglossy1.dcm d; +xmedcon jpeglossy1.dcm.DCM #OK + +#JPEG Baseline (Process 14) +#-------------------------- +testWrite MR-MONO2-12-shoulder.dcm d; +xmedcon MR-MONO2-12-shoulder.dcm.DCM; #OK + + +#fichier format ecat. +#testWrite imageEcat.ecat r + +#JPEG Lossy 8 bits +#================= +#JPEG Baseline (Process 1) +#------------------------- +# Bracco Files +testWrite US.1.2.dcm d; +echo "expected : A lot of Fragments (40), nb Frames = 40 ;-)"; +echo "expected pixelType=8U SamplesPerPixel=3 PlanarConfiguration=0"; +echo " PhotometricInterpretation=YBR_FULL_422"; +xmedcon US.1.2.dcm.DCM; #OK + +#Sequoia Acusson U11 +testWrite CLIP0001-Sequoia-U11.dcm d; +xmedcon CLIP0001-Sequoia-U11.dcm.DCM; #OK + +#RLE Lossless +#------------- +testWrite canadaAloka.dcm d; +echo "expected pixelType=8U SamplesPerPixel=1"; +echo " PlanarConfiguration=0 PhotometricInterpretation=MONOCHROME2"; +echo " nb Frames (DIMZ) : 1"; +xmedcon canadaAloka.dcm.DCM; + +testWrite jpeglossy1.dcm d; + xmecon jpeglossy1.dcm.DCM; #OK + +testWrite FMAG0001.dcm d; +echo "expected pixelType=8U SamplesPerPixel=3"; +echo " PlanarConfiguration=1 PhotometricInterpretation=YBR_FULL"; +echo " nb Frames (DIMZ) : 1"; +xmedcon FMAG0001.dcm.DCM; #OK + +v QMAG0001.dcm; #OK +xmedcon QMAG0001.dcm; #original breaks xmedcon +testWrite QMAG0001.dcm d; +echo "expected pixelType=8U SamplesPerPixel=3"; +echo " PlanarConfiguration=1 PhotometricInterpretation=YBR_FULL"; +v QMAG0001.dcm.DCM; #OK +xmedcon QMAG0001.dcm.DCM; #OK + +testWrite US-PAL-8-10x-echo.dcm d; +echo "expected pixelType=8U SamplesPerPixel=1 PlanarConfiguration=0"; +echo " PhotometricInterpretation=PALETTE COLOR"; +echo " nb Frames (DIMZ): 10"; +echo "expected : Parsing 10 'single fragment' Segments"; +echo " Reading 10 'single fragment' Segments (ouf!)"; +xmedcon US-PAL-8-10x-echo.dcm.DCM; #OK + +testWrite 8BitsRunLengthGrayScale.dcm d; +echo "expected : correct Gray image"; +xmedcon 8BitsRunLengthGrayScale.dcm.DCM; #OK + +testWrite 8BitsRunLengthColor.dcm d; +echo "expected pixelType=8U SamplesPerPixel=1 PlanarConfiguration=2"; +echo " PhotometricInterpretation=PALETTE COLOR"; +echo "expected correct color image"; +xmedcon 8BitsRunLengthColor.dcm.DCM; #OK + +#RLE 16 bits --> Try to find some more images + +testWrite 16BitsRunLengthGrayScale.dcm d; +echo "expected pixelType=16U SamplesPerPixel=1 PlanarConfiguration=0"; +echo " PhotometricInterpretation=MONOCHROME2"; +xmedcon 16BitsRunLengthGrayScale.dcm.DCM; #OK + +#Were supposed to be bugged +#-------------------------- +#(break xmedcon) + xmedcon 00191113.dcm; #No images found +testWrite 00191113.dcm d; +xmedcon 00191113.dcm.DCM; #OK + +xmedcon DermaColorLossLess.dcm; #breaks xmedcon : No images found +testWrite DermaColorLossLess.dcm d; +xmedcon DermaColorLossLess.dcm.DCM; #breaks xmedcon +#Feb 02 19:33:16 log[2619]: warning: Tag with uneven length +#Feb 02 19:33:16 log[2619]: warning: No transfer syntax found +#Feb 02 19:33:16 log[2619]: error: No images found +v DermaColorLossLess.dcm.DCM #OK + +#Original breaks xmedcon, affimdcm complian ?! +affimdcm filein=RadBWLossLess.dcm; #OK +v RadBWLossLess.dcm; #OK +xmedcon RadBWLossLess.dcm; # breaks :error: No images found +testWrite RadBWLossLess.dcm d; +v RadBWLossLess.dcm.DCM; #OK +xmedcon RadBWLossLess.dcm.DCM; #error: No images found + +#Known as BUGGED ! +#---------------- + +#Rectangular old 24 Bits image +testWrite gdcm-RGB-LibIDORect.acr d; +v gdcm-RGB-LibIDORect.acr.DCM; +xmedcon gdcm-RGB-LibIDORect.acr.DCM; # breaks : large Bit Allocated (24) +#TODO transform '24 bit images' into 8 bits + samples per pixel = 3 + +#MR GE GENESIS_SIGNA Palo Alto +testWrite DicomSampleNastyGEImage.dcm d; +echo " expected : warning uneven length (13) for 0008|103e"; +xmedcon DicomSampleNastyGEImage.dcm.DCM; #OK + +#MR Philips NTSCAN Hop. Neuro Lyon +PrintHeader philipsMR-lossy.ima #OK +xmedcon philipsMR-lossy.ima; #original breaks xmedcon +v philipsMR-lossy.ima; #Original OK +testWrite philipsMR-lossy.ima d; +echo "WAS expected : 'Bogus Huffman table definition' on philipsMR-lossy.ima"; +echo "IS expected : 'JERR_BAD_HUFF_TABLE sym 16 (>15)' but the show goes on"; +v philipsMR-lossy.ima.DCM; #OK +xmedcon philipsMR-lossy.ima.DCM; #OK + +#CT Siemens Hop. Salengro Lille +testWrite gdcm-JPEG-LossLess3a.dcm d; +echo "expected : wrong sequence delimiter (b00c,0eb6) at end of pixels"; +echo "xmedcon says 'error: Unexpected end of file'"; +vtkgdcmViewer gdcm-JPEG-LossLess3a.dcm.DCM; #OK; needs 'R' for display +xmedcon gdcm-JPEG-LossLess3a.dcm.DCM; #OK + +#CR Philips Thoravision Hop Cardio Lyon +affimdcm filein=gdcm-JPEG-LossLessThoravision.dcm; # OK, wrong image as usual +xmedcon gdcm-JPEG-LossLessThoravision.dcm; #original seg faults xmedcon +testWrite gdcm-JPEG-LossLessThoravision.dcm d; #breaks ; +echo "expected : 147 fragments,length : 29860 + 145*32760 + 14416"; +echo "breaks xmedcom, breaks e-film"; +echo "WAS expected : hashed image -with jLBJpeg-"; +echo "IS expected : Seg Fault"; +xmedcon gdcm-JPEG-LossLessThoravision.dcm.DCM; # NOT CHECKED + +#MR Picker ST. ANTHONY HOSPITAL +testWrite MR.6799.1.dcm d; +echo "OK; DICOM Image with NO Preamble"; +xmedcon MR.6799.1.dcm.DCM; #OK + +#Segmented Palette Color LUT Data +xmedcon gdcm-US-ALOKA-16.dcm; #breaks +vtkgdcmViewer gdcm-US-ALOKA-16.dcm3; #OK +testWrite gdcm-US-ALOKA-16.dcm d; +echo "expected pixelType=16U SamplesPerPixel=1 PlanarConfiguration=0"; +echo " PhotometricInterpretation=PALETTE COLOR"; +echo "expected : Gray image since 'Segmented xxx Palette Color LUT Data' not yet taken into account"; +echo "neither e-film nor DicomWorks deals with the color" +echo "breaks xmedcom"; +echo "breaks vtkgdcmViewer (bad result : 24 bits expected; 16 found in Pixels area)"; +vtkgdcmViewer gdcm-US-ALOKA-16.dcm.DCM; #OK +xmedcon gdcm-US-ALOKA-16.dcm.DCM; #breaks +#Feb 03 13:40:19 log[26999]: error: Missing CLUT +#Feb 03 13:40:19 log[26999]: error: No images found + +# bugged Siemens 'Leonardo' image +testWrite 8078283Leonardo.dcm d; +xmedcon 8078283Leonardo.dcm.DCM; #OK + +#CT McTwin Elscint C.H.R.U LILLE C.HURIEZ + xmedcon MxTwinLossLess.dcm; #breaks + v MxTwinLossLess.dcm; #OK + testWrite MxTwinLossLess.dcm d; + v MxTwinLossLess.dcm.DCM; #OK + xmedcon MxTwinLossLess.dcm.DCM #breaks + +# MRI image from VPRO burned CD +v mriThruVPRO.dcm; # Tasteless SHIT +xmedcon mriThruVPRO.dcm; # pas mieux +testWrite mriThruVPRO.dcm d; +v mriThruVPRO.dcm.DCM; +echo "expected : tasteless SHIT !" +echo "breaks Siemens Leonardo viewer . JPEG encoding is bugged?" + +# gdcm made Theralys image +# due to H table, a SeQuence is tagged with 0 length +# when using gdcmFile::WriteDcmXXX +xmedcon fromTheralys.dcm; # Original breaks xmedcon +testWrite fromTheralys.dcm d; +v fromTheralys.dcm.DCM; # OK (unsolved Length = 13 ...) +xmedcon fromTheralys.dcm.DCM; # Breaks : no image found