Catastrophic failure
Re: Catastrophic failure
We're letting your script continue. Its up to 150,000 loops and still running. We have no clue why its failing for you.
-
- Posts: 3
- Joined: 2011-09-19T13:39:16-07:00
- Authentication code: 8675308
- Location: Northampton, UK
Re: Catastrophic failure
Being fairly new to Imagemagick, I apologise if this is unrelated, but I am also having problems with the -draw command failing. I am adding text annotations to tif images from Visual Basic using convert and -draw.
The first annotation generally works. After adding one annotation to an image, if I then try to add another annotation to the modified image, it generally fails. I say generally because there are occasional instances where I can add two annotations sequentially or where the first annotation fails.
If I then resize the image slightly using IrfanView and apply the same -draw command, it generally works. It seems that the -draw text command generally works on files written by Irfan View, but not on files written by ImageMagick.
There is a 100k text file '2fe3_appcompat.txt' produced, which I do not claim to understand.
The first annotation generally works. After adding one annotation to an image, if I then try to add another annotation to the modified image, it generally fails. I say generally because there are occasional instances where I can add two annotations sequentially or where the first annotation fails.
If I then resize the image slightly using IrfanView and apply the same -draw command, it generally works. It seems that the -draw text command generally works on files written by Irfan View, but not on files written by ImageMagick.
There is a 100k text file '2fe3_appcompat.txt' produced, which I do not claim to understand.
- fmw42
- Posts: 25562
- Joined: 2007-07-02T17:14:51-07:00
- Authentication code: 1152
- Location: Sunnyvale, California, USA
Re: Catastrophic failure
I will stick my nose in here, though I don't know anything about Windows and VBscript. But the question I would ask is whether the problem is with IM or with VBscript interfacing with IM. What happens if you run the equivalent commands from the command line in a terminal window? Do they fail and for the same images? Do they fail for all images? Does any image work at all?
Also have you tried upgrading or atleast re-installing IM?
Also when you complain about some process failing it might be nice to see the exact command that is failing in a form that others can test. Forgive me if I missed it.
In my view, something is wrong with your environment or computer -- perhaps memory or disk drive? Have you tried the same thing on some other computer?
Sorry for sticking my nose it. Just some friendly thoughts about your problem.
Also have you tried upgrading or atleast re-installing IM?
Also when you complain about some process failing it might be nice to see the exact command that is failing in a form that others can test. Forgive me if I missed it.
In my view, something is wrong with your environment or computer -- perhaps memory or disk drive? Have you tried the same thing on some other computer?
Sorry for sticking my nose it. Just some friendly thoughts about your problem.
-
- Posts: 3
- Joined: 2011-09-19T13:39:16-07:00
- Authentication code: 8675308
- Location: Northampton, UK
Re: Catastrophic failure
Thanks for the comment. I have tried running the command in a DOS command window. If a command fails from VB script, it also fails from the DOS prompt. The failures are very repeatable, i.e. I can re-run the VB script, re-creating the same image files and the same annotation problem each time. The annotations work on the majority of images, but fail on a few.
As far as I have observed, annotations always fail when attempted on an image which has already been successfully annotated by the script using ImageMagick. They also fail on a small number of 'original' unannotated images. It seems as though there is something about the image file format which causes the failure. I am trying to see what is different about them. This is taking a little while...
Here is a failing command:
"C:\program files\imagemagick-6.7.2-q16\convert.exe" "f:\files\test_new\43 Lichfield Drive\Sale\Land Registry\00003.tif" -size 500x50 xc:none -box transparent -font Arial -pointsize 54 -draw "text 1487,263 'Bad'" "f:\files\test_new\43 Lichfield Drive\Sale\Land Registry\00003.tif"
Working at the DOS prompt, this command works on one file, but fails on another. Both are tif image files, originally scanned in, and are about the same size. One is 1686x2291x1bpp; the other is 1654x2338x1bpp.
If I use IrfanView to resize the failing image, first to double size, then back to original size, then save it, the command works. Time to have another coffee and compare the two files.
As far as I have observed, annotations always fail when attempted on an image which has already been successfully annotated by the script using ImageMagick. They also fail on a small number of 'original' unannotated images. It seems as though there is something about the image file format which causes the failure. I am trying to see what is different about them. This is taking a little while...
Here is a failing command:
"C:\program files\imagemagick-6.7.2-q16\convert.exe" "f:\files\test_new\43 Lichfield Drive\Sale\Land Registry\00003.tif" -size 500x50 xc:none -box transparent -font Arial -pointsize 54 -draw "text 1487,263 'Bad'" "f:\files\test_new\43 Lichfield Drive\Sale\Land Registry\00003.tif"
Working at the DOS prompt, this command works on one file, but fails on another. Both are tif image files, originally scanned in, and are about the same size. One is 1686x2291x1bpp; the other is 1654x2338x1bpp.
If I use IrfanView to resize the failing image, first to double size, then back to original size, then save it, the command works. Time to have another coffee and compare the two files.
Re: Catastrophic failure
We updated the TIFF delegate library in ImageMagick 6.7.2-7. Have you tried it? If that fails, post a URL to your image. Hopefully we can reproduce the problem with your image.
-
- Posts: 3
- Joined: 2011-09-19T13:39:16-07:00
- Authentication code: 8675308
- Location: Northampton, UK
Re: Catastrophic failure
Following some of the suggestions, I have been using 2 PCs and also installed the ImageMagick update.
I have also uploaded one of my problem tif files to : http://www.davidmann.talktalk.net/im/00003.tif
On the original PC with IM 6.7.2-7, I have run a test set with just 4 files to annotate.
From the script, 2 of the files work and two fail.
Running the same commands from a DOS prompt, I get the same results.
Both the above specify the full path (C:\program files\imagemagick-6.7.2-Q16) to convert.exe in the program files folder.
If I remove the path, and just put convert.exe, all the files work from the DOS prompt.
This is odd, but I cannot find another convert.exe on the machine.
On the second PC with IM 6.7.2-7, all four of the test files above worked ok with the script, so, silly me, I tried a larger set of data.
A small proportion of the files (about 0.1%) failed in the larger set, so I will have a look at these tomorrow and see if I can find any common factors.
I have also uploaded one of my problem tif files to : http://www.davidmann.talktalk.net/im/00003.tif
On the original PC with IM 6.7.2-7, I have run a test set with just 4 files to annotate.
From the script, 2 of the files work and two fail.
Running the same commands from a DOS prompt, I get the same results.
Both the above specify the full path (C:\program files\imagemagick-6.7.2-Q16) to convert.exe in the program files folder.
If I remove the path, and just put convert.exe, all the files work from the DOS prompt.
This is odd, but I cannot find another convert.exe on the machine.
On the second PC with IM 6.7.2-7, all four of the test files above worked ok with the script, so, silly me, I tried a larger set of data.
A small proportion of the files (about 0.1%) failed in the larger set, so I will have a look at these tomorrow and see if I can find any common factors.
Re: Catastrophic failure
I am still getting this error now and then. Last time today, causing again some images lost as the script failed.
For me it happens after many thousands of images processed by the same VB script.
Has anything being done that may affect this (memory leak?) failure? Should I install a newer version?
arto
For me it happens after many thousands of images processed by the same VB script.
Has anything being done that may affect this (memory leak?) failure? Should I install a newer version?
arto
- anthony
- Posts: 8883
- Joined: 2004-05-31T19:27:03-07:00
- Authentication code: 8675308
- Location: Brisbane, Australia
Re: Catastrophic failure
Things to look for.
Unusual TIFF data formats (common in TIFF image file formats). See
http://www.imagemagick.org/Usage/formats/#tiff
Use of CMYK in some images rather than RGB.
Use of non-standard color profiles!
Basically find one image that fails, and study it.
Unusual TIFF data formats (common in TIFF image file formats). See
http://www.imagemagick.org/Usage/formats/#tiff
Use of CMYK in some images rather than RGB.
Use of non-standard color profiles!
Basically find one image that fails, and study it.
Anthony Thyssen -- Webmaster for ImageMagick Example Pages
https://imagemagick.org/Usage/
https://imagemagick.org/Usage/
Re: Catastrophic failure
The situation is the same as in the beginning of this thread. The images are simple jpeg-images and the failure happens to any image. See my tests using the same image over and over, it eventually failed every time. I use ImageMagick to add annotations to the images taken automatically every few minutes before posting them to the web server. This works for many weeks before the failure. Nothing wrong with the imags.
See the last image taken here: http://nyrola.jklsirius.fi/ccd/capture/allsky/
arto
See the last image taken here: http://nyrola.jklsirius.fi/ccd/capture/allsky/
arto