Dicom file conversion problems
Re: Dicom file conversion problems
You most likely do not have JPEG support built-in. That requires the JPEG library and header files installed on your system before your build ImageMagick. Check with this command 'convert -list format'. Is JPEG listed as readable / writeable?
Re: Dicom file conversion problems
I have:
DCM* DCM r-- Digital Imaging and Communications in Medicine image
DICOM is used by the medical community for images like X-rays. The
specification, "Digital Imaging and Communications in Medicine
(DICOM)", is available at http://medical.nema.org/. In particular,
see part 5 which describes the image encoding (RLE, JPEG, JPEG-LS),
and supplement 61 which adds JPEG-2000 encoding.
JPEG* JPEG rw- Joint Photographic Experts Group JFIF format (80)
JPG* JPEG rw- Joint Photographic Experts Group JFIF format (80)
DCM* DCM r-- Digital Imaging and Communications in Medicine image
DICOM is used by the medical community for images like X-rays. The
specification, "Digital Imaging and Communications in Medicine
(DICOM)", is available at http://medical.nema.org/. In particular,
see part 5 which describes the image encoding (RLE, JPEG, JPEG-LS),
and supplement 61 which adds JPEG-2000 encoding.
JPEG* JPEG rw- Joint Photographic Experts Group JFIF format (80)
JPG* JPEG rw- Joint Photographic Experts Group JFIF format (80)
Re: Dicom file conversion problems
Did you build with modules, --with-modules? If so, it could be a permissions problem for /usr/local/lib/ImageMagick-6.8.4. If not, add -debug module or -debug configure to your command line and see if it reports any problems.
Re: Dicom file conversion problems
Can you provide the exact command which I should enter to command line? It should be
convert -debug configure dicom.dcm image.jpg
2013-04-20T17:57:29+02:00 0:00.000 0.000u 6.8.4 Configure convert[1434]: utility.c/ExpandFilenames/936/Configure
Command line: convert {-debug} {configure} {dicom.dcm} {image.jpg}
2013-04-20T17:57:29+02:00 0:00.000 0.000u 6.8.4 Configure convert[1434]: configure.c/GetConfigureOptions/589/Configure
Searching for configure file: "/usr/local/Cellar/imagemagick/6.8.4-10/share/ImageMagick-6/coder.xml"
2013-04-20T17:57:29+02:00 0:00.000 0.000u 6.8.4 Configure convert[1434]: configure.c/GetConfigureOptions/589/Configure
Searching for configure file: "/usr/local/Cellar/imagemagick/6.8.4-10/lib/ImageMagick//config-Q16/coder.xml"
2013-04-20T17:57:29+02:00 0:00.000 0.000u 6.8.4 Configure convert[1434]: configure.c/GetConfigureOptions/589/Configure
Searching for configure file: "/usr/local/Cellar/imagemagick/6.8.4-10/etc/ImageMagick-6/coder.xml"
2013-04-20T17:57:29+02:00 0:00.000 0.000u 6.8.4 Configure convert[1434]: configure.c/GetConfigureOptions/589/Configure
Searching for configure file: "/usr/local/Cellar/imagemagick/6.8.4-10/share/doc/ImageMagick-6/coder.xml"
2013-04-20T17:57:29+02:00 0:00.000 0.000u 6.8.4 Configure convert[1434]: configure.c/GetConfigureOptions/589/Configure
Searching for configure file: "/Users/camol/.magick/coder.xml"
2013-04-20T17:57:29+02:00 0:00.000 0.000u 6.8.4 Configure convert[1434]: coder.c/LoadCoderList/696/Configure
Loading coder configuration file "/usr/local/Cellar/imagemagick/6.8.4-10/etc/ImageMagick-6/coder.xml" ...
2013-04-20T17:57:29+02:00 0:00.000 0.000u 6.8.4 Configure convert[1434]: configure.c/GetConfigureOptions/589/Configure
Searching for configure file: "/usr/local/Cellar/imagemagick/6.8.4-10/share/ImageMagick-6/magic.xml"
2013-04-20T17:57:29+02:00 0:00.000 0.000u 6.8.4 Configure convert[1434]: configure.c/GetConfigureOptions/589/Configure
Searching for configure file: "/usr/local/Cellar/imagemagick/6.8.4-10/lib/ImageMagick//config-Q16/magic.xml"
2013-04-20T17:57:29+02:00 0:00.000 0.000u 6.8.4 Configure convert[1434]: configure.c/GetConfigureOptions/589/Configure
Searching for configure file: "/usr/local/Cellar/imagemagick/6.8.4-10/etc/ImageMagick-6/magic.xml"
2013-04-20T17:57:29+02:00 0:00.000 0.000u 6.8.4 Configure convert[1434]: configure.c/GetConfigureOptions/589/Configure
Searching for configure file: "/usr/local/Cellar/imagemagick/6.8.4-10/share/doc/ImageMagick-6/magic.xml"
2013-04-20T17:57:29+02:00 0:00.000 0.000u 6.8.4 Configure convert[1434]: configure.c/GetConfigureOptions/589/Configure
Searching for configure file: "/Users/camol/.magick/magic.xml"
2013-04-20T17:57:29+02:00 0:00.000 0.000u 6.8.4 Configure convert[1434]: magic.c/LoadMagicList/681/Configure
Loading magic configure file "/usr/local/Cellar/imagemagick/6.8.4-10/etc/ImageMagick-6/magic.xml" ...
2013-04-20T17:57:29+02:00 0:00.010 0.000u 6.8.4 Configure convert[1434]: configure.c/GetConfigureOptions/589/Configure
Searching for configure file: "/usr/local/Cellar/imagemagick/6.8.4-10/share/ImageMagick-6/delegates.xml"
2013-04-20T17:57:29+02:00 0:00.010 0.000u 6.8.4 Configure convert[1434]: configure.c/GetConfigureOptions/589/Configure
Searching for configure file: "/usr/local/Cellar/imagemagick/6.8.4-10/lib/ImageMagick//config-Q16/delegates.xml"
2013-04-20T17:57:29+02:00 0:00.010 0.000u 6.8.4 Configure convert[1434]: configure.c/GetConfigureOptions/589/Configure
Searching for configure file: "/usr/local/Cellar/imagemagick/6.8.4-10/etc/ImageMagick-6/delegates.xml"
2013-04-20T17:57:29+02:00 0:00.010 0.000u 6.8.4 Configure convert[1434]: configure.c/GetConfigureOptions/589/Configure
Searching for configure file: "/usr/local/Cellar/imagemagick/6.8.4-10/share/doc/ImageMagick-6/delegates.xml"
2013-04-20T17:57:29+02:00 0:00.010 0.000u 6.8.4 Configure convert[1434]: configure.c/GetConfigureOptions/589/Configure
Searching for configure file: "/Users/camol/.magick/delegates.xml"
2013-04-20T17:57:29+02:00 0:00.010 0.000u 6.8.4 Configure convert[1434]: delegate.c/LoadDelegateList/1228/Configure
Loading delegate configuration file "/usr/local/Cellar/imagemagick/6.8.4-10/etc/ImageMagick-6/delegates.xml" ...
2013-04-20T17:57:29+02:00 0:00.010 0.010u 6.8.4 Configure convert[1434]: locale.c/LoadLocaleList/1093/Configure
Loading locale configure file "/usr/local/Cellar/imagemagick/6.8.4-10/share/ImageMagick-6/locale.xml" ...
2013-04-20T17:57:29+02:00 0:00.010 0.010u 6.8.4 Configure convert[1434]: locale.c/LoadLocaleList/1093/Configure
Loading locale configure file "/usr/local/Cellar/imagemagick/6.8.4-10/share/ImageMagick-6/english.xml" ...
convert: no decode delegate for this image format `/var/tmp/magick-1434I_fn_ALVZStW' @ error/constitute.c/ReadImage/550.
convert: no images defined `image.jpg' @ error/convert.c/ConvertImageCommand/3106.
convert -debug configure dicom.dcm image.jpg
2013-04-20T17:57:29+02:00 0:00.000 0.000u 6.8.4 Configure convert[1434]: utility.c/ExpandFilenames/936/Configure
Command line: convert {-debug} {configure} {dicom.dcm} {image.jpg}
2013-04-20T17:57:29+02:00 0:00.000 0.000u 6.8.4 Configure convert[1434]: configure.c/GetConfigureOptions/589/Configure
Searching for configure file: "/usr/local/Cellar/imagemagick/6.8.4-10/share/ImageMagick-6/coder.xml"
2013-04-20T17:57:29+02:00 0:00.000 0.000u 6.8.4 Configure convert[1434]: configure.c/GetConfigureOptions/589/Configure
Searching for configure file: "/usr/local/Cellar/imagemagick/6.8.4-10/lib/ImageMagick//config-Q16/coder.xml"
2013-04-20T17:57:29+02:00 0:00.000 0.000u 6.8.4 Configure convert[1434]: configure.c/GetConfigureOptions/589/Configure
Searching for configure file: "/usr/local/Cellar/imagemagick/6.8.4-10/etc/ImageMagick-6/coder.xml"
2013-04-20T17:57:29+02:00 0:00.000 0.000u 6.8.4 Configure convert[1434]: configure.c/GetConfigureOptions/589/Configure
Searching for configure file: "/usr/local/Cellar/imagemagick/6.8.4-10/share/doc/ImageMagick-6/coder.xml"
2013-04-20T17:57:29+02:00 0:00.000 0.000u 6.8.4 Configure convert[1434]: configure.c/GetConfigureOptions/589/Configure
Searching for configure file: "/Users/camol/.magick/coder.xml"
2013-04-20T17:57:29+02:00 0:00.000 0.000u 6.8.4 Configure convert[1434]: coder.c/LoadCoderList/696/Configure
Loading coder configuration file "/usr/local/Cellar/imagemagick/6.8.4-10/etc/ImageMagick-6/coder.xml" ...
2013-04-20T17:57:29+02:00 0:00.000 0.000u 6.8.4 Configure convert[1434]: configure.c/GetConfigureOptions/589/Configure
Searching for configure file: "/usr/local/Cellar/imagemagick/6.8.4-10/share/ImageMagick-6/magic.xml"
2013-04-20T17:57:29+02:00 0:00.000 0.000u 6.8.4 Configure convert[1434]: configure.c/GetConfigureOptions/589/Configure
Searching for configure file: "/usr/local/Cellar/imagemagick/6.8.4-10/lib/ImageMagick//config-Q16/magic.xml"
2013-04-20T17:57:29+02:00 0:00.000 0.000u 6.8.4 Configure convert[1434]: configure.c/GetConfigureOptions/589/Configure
Searching for configure file: "/usr/local/Cellar/imagemagick/6.8.4-10/etc/ImageMagick-6/magic.xml"
2013-04-20T17:57:29+02:00 0:00.000 0.000u 6.8.4 Configure convert[1434]: configure.c/GetConfigureOptions/589/Configure
Searching for configure file: "/usr/local/Cellar/imagemagick/6.8.4-10/share/doc/ImageMagick-6/magic.xml"
2013-04-20T17:57:29+02:00 0:00.000 0.000u 6.8.4 Configure convert[1434]: configure.c/GetConfigureOptions/589/Configure
Searching for configure file: "/Users/camol/.magick/magic.xml"
2013-04-20T17:57:29+02:00 0:00.000 0.000u 6.8.4 Configure convert[1434]: magic.c/LoadMagicList/681/Configure
Loading magic configure file "/usr/local/Cellar/imagemagick/6.8.4-10/etc/ImageMagick-6/magic.xml" ...
2013-04-20T17:57:29+02:00 0:00.010 0.000u 6.8.4 Configure convert[1434]: configure.c/GetConfigureOptions/589/Configure
Searching for configure file: "/usr/local/Cellar/imagemagick/6.8.4-10/share/ImageMagick-6/delegates.xml"
2013-04-20T17:57:29+02:00 0:00.010 0.000u 6.8.4 Configure convert[1434]: configure.c/GetConfigureOptions/589/Configure
Searching for configure file: "/usr/local/Cellar/imagemagick/6.8.4-10/lib/ImageMagick//config-Q16/delegates.xml"
2013-04-20T17:57:29+02:00 0:00.010 0.000u 6.8.4 Configure convert[1434]: configure.c/GetConfigureOptions/589/Configure
Searching for configure file: "/usr/local/Cellar/imagemagick/6.8.4-10/etc/ImageMagick-6/delegates.xml"
2013-04-20T17:57:29+02:00 0:00.010 0.000u 6.8.4 Configure convert[1434]: configure.c/GetConfigureOptions/589/Configure
Searching for configure file: "/usr/local/Cellar/imagemagick/6.8.4-10/share/doc/ImageMagick-6/delegates.xml"
2013-04-20T17:57:29+02:00 0:00.010 0.000u 6.8.4 Configure convert[1434]: configure.c/GetConfigureOptions/589/Configure
Searching for configure file: "/Users/camol/.magick/delegates.xml"
2013-04-20T17:57:29+02:00 0:00.010 0.000u 6.8.4 Configure convert[1434]: delegate.c/LoadDelegateList/1228/Configure
Loading delegate configuration file "/usr/local/Cellar/imagemagick/6.8.4-10/etc/ImageMagick-6/delegates.xml" ...
2013-04-20T17:57:29+02:00 0:00.010 0.010u 6.8.4 Configure convert[1434]: locale.c/LoadLocaleList/1093/Configure
Loading locale configure file "/usr/local/Cellar/imagemagick/6.8.4-10/share/ImageMagick-6/locale.xml" ...
2013-04-20T17:57:29+02:00 0:00.010 0.010u 6.8.4 Configure convert[1434]: locale.c/LoadLocaleList/1093/Configure
Loading locale configure file "/usr/local/Cellar/imagemagick/6.8.4-10/share/ImageMagick-6/english.xml" ...
convert: no decode delegate for this image format `/var/tmp/magick-1434I_fn_ALVZStW' @ error/constitute.c/ReadImage/550.
convert: no images defined `image.jpg' @ error/convert.c/ConvertImageCommand/3106.
Re: Dicom file conversion problems
ImageMagick looks for a delegate to read an image if it tries to find a supported module and can't find it. Did you build with --with-modules? Type 'convert -list configure' and see the CONFIGURE tag to verify. The command 'convert -debug module dicom.dcm image.jpg' returns this for us:
Notice how it searches for and finds both the DCM and JPEG modules.
Code: Select all
convert -debug module dicom.dcm image.jpg
2013-04-20T16:58:28-04:00 0:00.000 0.000u 6.8.5 Module convert[26569]: module.c/OpenModule/1263/Module
Searching for module "DCM" using filename "dcm.la"
2013-04-20T16:58:28-04:00 0:00.000 0.000u 6.8.5 Module convert[26569]: module.c/GetMagickModulePath/565/Module
Searching for coder module file "dcm.la" ...
2013-04-20T16:58:28-04:00 0:00.000 0.000u 6.8.5 Module convert[26569]: module.c/OpenModule/1272/Module
Opening module at path "/usr/local/lib/ImageMagick-6.8.5//modules-Q16/coders/dcm.la"
2013-04-20T16:58:28-04:00 0:00.000 0.000u 6.8.5 Module convert[26569]: module.c/OpenModule/1299/Module
Method "RegisterDCMImage" in module "DCM" at address 0x7f27f93dab00
2013-04-20T16:58:28-04:00 0:00.000 0.000u 6.8.5 Module convert[26569]: module.c/OpenModule/1313/Module
Method "UnregisterDCMImage" in module "DCM" at address 0x7f27f93dab80
2013-04-20T16:58:30-04:00 0:02.080 2.070u 6.8.5 Module convert[26569]: module.c/OpenModule/1263/Module
Searching for module "JPEG" using filename "jpeg.la"
2013-04-20T16:58:30-04:00 0:02.080 2.070u 6.8.5 Module convert[26569]: module.c/GetMagickModulePath/565/Module
Searching for coder module file "jpeg.la" ...
2013-04-20T16:58:30-04:00 0:02.080 2.070u 6.8.5 Module convert[26569]: module.c/OpenModule/1272/Module
Opening module at path "/usr/local/lib/ImageMagick-6.8.5//modules-Q16/coders/jpeg.la"
2013-04-20T16:58:30-04:00 0:02.080 2.070u 6.8.5 Module convert[26569]: module.c/OpenModule/1299/Module
Method "RegisterJPEGImage" in module "JPEG" at address 0x7f27f91b4db0
2013-04-20T16:58:30-04:00 0:02.080 2.070u 6.8.5 Module convert[26569]: module.c/OpenModule/1313/Module
Method "UnregisterJPEGImage" in module "JPEG" at address 0x7f27f91b4f60
Re: Dicom file conversion problems
For list configure I got this two tags:
Code: Select all
CONFIGURE ./configure '--disable-osx-universal-binary' '--without-perl' '--prefix=/usr/local/Cellar/imagemagick/6.8.4-10' '--disable-dependency-tracking' '--enable-shared' '--disable-static' '--without-pango' '--with-included-ltdl' '--with-modules' '--disable-openmp' '--without-gslib' '--with-gs-font-dir=/usr/local/share/ghostscript/fonts' '--without-x' '--with-freetype=yes' 'CC=cc' 'CXX=c++'
CONFIGURE_PATH /usr/local/Cellar/imagemagick/6.8.4-10/etc/ImageMagick-6/
Re: Dicom file conversion problems
As you can see there is --with-moduls so is it okey than?
Re: Dicom file conversion problems
Please is there anything a I can about it I in real need of this feature
Re: Dicom file conversion problems
Did you try a static build?
- cd ImageMagick-6.8.5-2
./configure --disable-shared --enable-static
make
make install
Re: Dicom file conversion problems
After the options you mentioned I get this:
after:
EDIT:
It is strange becouse I can't convert the dicom I've uploaded before but I can this one
:\
Code: Select all
convert: unexpected end-of-file `dicom.dcm': No such file or directory @ error/dcm.c/ReadDCMImage/4067.
Code: Select all
convert dicom.dcm image.jpg
It is strange becouse I can't convert the dicom I've uploaded before but I can this one
Code: Select all
http://speedy.sh/5zSt8/knee.dcm