Imagemagick getting stuck while converting tif file.

Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
senthilkumartk
Posts: 6
Joined: 2013-04-03T23:31:23-07:00
Authentication code: 6789

Imagemagick getting stuck while converting tif file.

Post by senthilkumartk »

Hi,

I am using ImageMagick 6.8 to convert a tif file to jpg.
After around 30 mins the following windows error occured.
ImageMagick studio library and utility programs has stopped working.
The command I used is

Code: Select all

convert  front.tif -debug Trace -intent relative -resize "500x375>" -quality 95 -colorspace sRGB black_front.jpg
From the trace log the Imagemagick is getting stuck at
2015-02-20T12:59:42+05:00 0:00.077 0.078u 6.8.0 Trace imconvert.exe[8540]: splay-tree.c/GetValueFromSplayTree/890/Trace
...
2015-02-20T13:27:29+06:00 27:47.261 1660.443u 6.8.0 Trace imconvert.exe[8540]: xml-tree.c/GetXMLTreeChild/708/Trace


Any help on resolving the issue is much appreciated.


Thanks,
Senthil.
snibgo
Posts: 12159
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Imagemagick getting stuck while converting tif file.

Post by snibgo »

You should give the exact version number. What does "convert -version" say?

"-intent relative" is only for profile conversion, so should do nothing.

Are you running the command from the command line, or from something else?

You'll probably need to provide front.tif. You can put it somewhere like dropbox.com and paste the link here.
snibgo's IM pages: im.snibgo.com
User avatar
dlemstra
Posts: 1570
Joined: 2013-05-04T15:28:54-07:00
Authentication code: 6789
Contact:

Re: Imagemagick getting stuck while converting tif file.

Post by dlemstra »

Can you upgrade your version of ImageMagick to the latest version available?
.NET + ImageMagick = Magick.NET https://github.com/dlemstra/Magick.NET, @MagickNET, Donate
senthilkumartk
Posts: 6
Joined: 2013-04-03T23:31:23-07:00
Authentication code: 6789

Re: Imagemagick getting stuck while converting tif file.

Post by senthilkumartk »

Thanks for the prompt reply.

Code: Select all

convert -version
Version: ImageMagick 6.8.0-5 2012-11-03 Q16 http://www.imagemagick.org
Copyright: Copyright (C) 1999-2012 ImageMagick Studio LLC
Features: OpenMP
I am running the command from command prompt.
I am afraid I will not be able to post the tif file, since it is sensitive.
Any other debug statements might help in finding the issue.
snibgo
Posts: 12159
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Imagemagick getting stuck while converting tif file.

Post by snibgo »

Can you post the text output from "identify -verbose front.tif". You can replace any sensitive information with XXXXXX.
snibgo's IM pages: im.snibgo.com
senthilkumartk
Posts: 6
Joined: 2013-04-03T23:31:23-07:00
Authentication code: 6789

Re: Imagemagick getting stuck while converting tif file.

Post by senthilkumartk »

Identify command also got stuck at the same point.
The image works fine on the latest version of ImageMagick.
PhotoCat
Posts: 20
Joined: 2016-07-08T08:43:07-07:00
Authentication code: 1151

(workaround found) Re: Imagemagick getting stuck while converting tif file.

Post by PhotoCat »

Hi All and especially magick developers,

I have experienced the same problem during tif conversion and I have found a workaround!

My command line is: (in win7 x64)

magick convert filein*.tif -units PixelsPerInch -page Letter -density 72 fileout.pdf

and it sometimes gives me an error message: (sometimes but not always)

"Imagemagick Studio Library and utility programs has stopped working"

Doing the following manual expansion helps sometimes:

magick convert filein001.tif flein002.tif filein003.tif -units PixelsPerInch -page Letter -density 72 fileout.pdf

However, I found this error is very command shell related. i.e. windows 7's cmd.exe related. Also same problems with
windows's powershell that came with win7.

I tried to run the above command line in mks's command shell with much less problems. (well it has other problems like unicode text problem etc)

Hopefully I have provided enough pointers to allow the developers to fix this problem in Imagemagick, which is a superb piece of batch image processing s/w! Tks for all the hard work! Highly appreciated!
PhotoCat
Posts: 20
Joined: 2016-07-08T08:43:07-07:00
Authentication code: 1151

Re: Imagemagick getting stuck while converting tif file.

Post by PhotoCat »

C:\Program Files\ImageMagick-7.0.1-Q16\magick.exe

The version was used. tks!
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: Imagemagick getting stuck while converting tif file.

Post by fmw42 »

Out of curiosity why are you using:

magick convert

and not simply

magick
PhotoCat
Posts: 20
Joined: 2016-07-08T08:43:07-07:00
Authentication code: 1151

Re: Imagemagick getting stuck while converting tif file.

Post by PhotoCat »

Tks fmw42 so much!
It was out of ignorance!!
Tried just magick without the convert and it worked fine now!
This is so great!
Tks fmw42 again!
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: Imagemagick getting stuck while converting tif file.

Post by fmw42 »

It really should not have mattered, since magick and magick convert are supposed to be the same.
PhotoCat
Posts: 20
Joined: 2016-07-08T08:43:07-07:00
Authentication code: 1151

Re: Imagemagick getting stuck while converting tif file.

Post by PhotoCat »

Very strange then. The failure is very consistent. I went back to magick convert and it said,
"Imagemagick Studio Library and utility programs has stopped working" again.
Change it back to just magick, everything worked! BTW, everything in a .bat file.
Anyway it fixed the problem and thank you so much fmw42!
snibgo
Posts: 12159
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Imagemagick getting stuck while converting tif file.

Post by snibgo »

"magick" requires v7 syntax. For example, a keyword is "-read-mask".

"magick convert" requires v6 syntax. For example, a keyword is "-mask".

(At least, the above is true of v7.0.1-4 on Windows 8.1.)
snibgo's IM pages: im.snibgo.com
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: Imagemagick getting stuck while converting tif file.

Post by fmw42 »

snibgo wrote:"magick" requires v7 syntax. For example, a keyword is "-read-mask".

"magick convert" requires v6 syntax. For example, a keyword is "-mask".

(At least, the above is true of v7.0.1-4 on Windows 8.1.)

Yes, there are v7 vs v6 syntax changes to consider, but I do not see anything in his command that would require a syntax change. Am I missing something obvious?

Might there be an issue on Windows if legacy support has been used when installing IM?

Snibgo - does magick XXX always invoke legacy support or perhaps only for XXX=convert. I thought magick XXX was use to invoke XXX=montage and other commands, for IM 7. I presume all the commands but XXX=convert have no changed syntax, but I am not sure if they are now running native IM 7 or running legacy IM 6.

The porting guide is not clear to me on this 6 vs 7 issue. All it says is

"animate, compare, composite, conjure, convert, display, identify, import, mogrify, montage, stream: To reduce the footprint of the command-line utilities, these utilities are symbolic links to the magick utility. You can also invoke them from the magick utility, for example, use magick convert logo: logo.png to invoke the convert utility."
snibgo
Posts: 12159
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Imagemagick getting stuck while converting tif file.

Post by snibgo »

fmw42 wrote:Yes, there are v7 vs v6 syntax changes to consider, but I do not see anything in his command that would require a syntax change. Am I missing something obvious?
Nothing in his command is specific to v6 or v7 (as far as I know), so it should do the same in both.

Further experimentation shows that "magick convert" needs the v7 "-alpha-color", not the v6 "-mattecolor". So "magick convert" is a hybrid v6-or-v7 syntax. Yuck.

I haven't played with "magick mogrify", "magick montage" etc.
snibgo's IM pages: im.snibgo.com
Post Reply