Not responding when Convert Jpg(800Kb) to Tiff

Post any defects you find in the released or beta versions of the ImageMagick software here. Include the ImageMagick version, OS, and any command-line required to reproduce the problem. Got a patch for a bug? Post it here.
Post Reply
sireeshala
Posts: 38
Joined: 2013-09-27T04:00:05-07:00
Authentication code: 6789

Not responding when Convert Jpg(800Kb) to Tiff

Post by sireeshala »

At image.type(BilevelType) Not responding because of the recursion.
if i have changed the parameters resize or density or any thing else its working fine.

For the following image
https://www.dropbox.com/s/3g3baikbnvomd5k/rescale.jpg

Code: Select all

string sResultSinglePage( "rescale.jpg");
Geometry gNewDensity(300,300);
	Image image;
	image.read( sResultSinglePage.c_str() );
	image.resize("7968x10968");
        image.density(gNewDensity);
        image.quality(g_nJpegQuality);
        image.magick("TIFF");
        image.compressType(Group4Compression);
        image.type(BilevelType);
        image.write("rescale.tiff");
Thanks in advance
User avatar
dlemstra
Posts: 1570
Joined: 2013-05-04T15:28:54-07:00
Authentication code: 6789
Contact:

Re: Not responding when Convert Jpg(800Kb) to Tiff

Post by dlemstra »

Can you please post your IM version and platform?
.NET + ImageMagick = Magick.NET https://github.com/dlemstra/Magick.NET, @MagickNET, Donate
sireeshala
Posts: 38
Joined: 2013-09-27T04:00:05-07:00
Authentication code: 6789

Re: Not responding when Convert Jpg(800Kb) to Tiff

Post by sireeshala »

On windows 7 64 bit and Im Version is 6.8.7
sireeshala
Posts: 38
Joined: 2013-09-27T04:00:05-07:00
Authentication code: 6789

Re: Not responding when Convert Jpg(800Kb) to Tiff

Post by sireeshala »

if I tried to avoid the function (commented out) image.type function
image.write function is also not responding for 15 to 18 mins and given a complete black image.

is this a bug or is there any problem with the image properties?
Even i am able to reproduce this on 6.8.2

Thanks in advance,
User avatar
dlemstra
Posts: 1570
Joined: 2013-05-04T15:28:54-07:00
Authentication code: 6789
Contact:

Re: Not responding when Convert Jpg(800Kb) to Tiff

Post by dlemstra »

The problem probably the amount of pixels in your image. At some point ImageMagick will use your disk to store its pixels and reading/writing that is really slow. Maybe you can switch your application to 64 bit? This will allow you to allocate more memory at once.
.NET + ImageMagick = Magick.NET https://github.com/dlemstra/Magick.NET, @MagickNET, Donate
sireeshala
Posts: 38
Joined: 2013-09-27T04:00:05-07:00
Authentication code: 6789

Re: Not responding when Convert Jpg(800Kb) to Tiff

Post by sireeshala »

application has some dependencies so we cant switch it over 64 bit.
Mentioned that "probably the amount of pixels in image". are there any specified limits ?
Can we get some other solution to this problem?
User avatar
dlemstra
Posts: 1570
Joined: 2013-05-04T15:28:54-07:00
Authentication code: 6789
Contact:

Re: Not responding when Convert Jpg(800Kb) to Tiff

Post by dlemstra »

You can increase the memory limit with Image::cacheThreshold(bytes). The documentation says megabytes but it really is bytes, I already patched this comment in the svn repository. You can read more about memory limits on windows here: http://msdn.microsoft.com/en-us/library/aa366778.aspx.
.NET + ImageMagick = Magick.NET https://github.com/dlemstra/Magick.NET, @MagickNET, Donate
sireeshala
Posts: 38
Joined: 2013-09-27T04:00:05-07:00
Authentication code: 6789

Re: Not responding when Convert Jpg(800Kb) to Tiff

Post by sireeshala »

There is no use by setting this value is there any other alternative ?
User avatar
dlemstra
Posts: 1570
Joined: 2013-05-04T15:28:54-07:00
Authentication code: 6789
Contact:

Re: Not responding when Convert Jpg(800Kb) to Tiff

Post by dlemstra »

sireeshala wrote:There is no use by setting this value
Setting this value did not help?
.NET + ImageMagick = Magick.NET https://github.com/dlemstra/Magick.NET, @MagickNET, Donate
sireeshala
Posts: 38
Joined: 2013-09-27T04:00:05-07:00
Authentication code: 6789

Re: Not responding when Convert Jpg(800Kb) to Tiff

Post by sireeshala »

i have tried to set with some values like 100000 .... it did nt worked out
Can you suggest any exact value which fixes this problem
User avatar
dlemstra
Posts: 1570
Joined: 2013-05-04T15:28:54-07:00
Authentication code: 6789
Contact:

Re: Not responding when Convert Jpg(800Kb) to Tiff

Post by dlemstra »

I cannot suggest a value that fixes the problem. You could try the maximum value: 4294967295
.NET + ImageMagick = Magick.NET https://github.com/dlemstra/Magick.NET, @MagickNET, Donate
sireeshala
Posts: 38
Joined: 2013-09-27T04:00:05-07:00
Authentication code: 6789

Re: Not responding when Convert Jpg(800Kb) to Tiff

Post by sireeshala »

Setting the memory limit to any value does nt worked out .
Still the convert.exe in not responding for longer time.

Is it possible to throw any error if its unbale to convert in a specified time limit.
Post Reply