Mon 22 Feb 2016 12:08:25 AM UTC, comment #11:
This report has been idle for several months. Have you made any progress debugging your build of Octave? I don't think any of the developers are able to reproduce this, it seems like some problem with your GraphicsMagick or other system libraries.
|
Tue 20 Oct 2015 02:02:35 PM UTC, comment #10:
Pantxo:
gm display <image> works fine.
gm convert -scale 400 image1.jpg image2.jpg works too
Inside octave, using the same image1.jpg as above, on doing 'a = imread('image1.jpg'), I get the error:
warning: your version of GraphicsMagick limits images to 16 bits per pixel
warning: called from
imformats>default_formats at line 256 column 11
imformats at line 79 column 3
imageIO at line 106 column 11
imread at line 106 column 30
octave-gui: magick/pixel_cache.c:2886: ModifyCache: Assertion `image->cache != (Cache) ((void *)0)' failed.
panic: Aborted -- stopping myself...
attempting to save variables to 'octave-workspace'...
save to 'octave-workspace' complete
Aborted
Thanks for the other information - I just started to use GM because of the requirements of Octave.
|
Tue 20 Oct 2015 07:14:10 AM UTC, comment #9:
>>While checking the strace output, I noticed that, even though I used octave with --no-gui, all GUI-related libraries are still loaded. Is this normal?
Yes, if you want pure cli and no Qt libs, try "-cli" option. The "--no-gui" option doesn't load the main GUI widgets but is still able to use Qt toolkit for graphics.
>> pkg load signal
Signal package should have nothing to do with this bug, "imread" is a core function.
After compiling GraphicsMagick did you try to use simple "gm" command line utility (see e.g. this old bug report [1])? Or did you run their test suite (if they do have one)? This is just to make sure GM is working properly on its own.
[1] http://permalink.gmane.org/gmane.comp.video.graphicsmagick.bugs/99
|
Tue 20 Oct 2015 04:12:09 AM UTC, comment #8:
I'm recompiling a version without using the SlackBuild script - from the config.log I can see the AMD libraries are not included.
While checking the strace output, I noticed that, even though I used octave with --no-gui, all GUI-related libraries are still loaded. Is this normal?
Finished compiling. On executing
pkg load signal
a = imread('image.png')
I get:
warning: called from
imformats>default_formats at line 256 column 11
imformats at line 79 column 3
imageIO at line 106 column 11
imread at line 106 column 30
octave-gui: magick/pixel_cache.c:2886: ModifyCache: Assertion `image->cache != (Cache) ((void *)0)' failed.
Program received signal SIGABRT, Aborted.
(Attached backtrace)
(file #35239)
|
Tue 20 Oct 2015 01:35:20 AM UTC, comment #7:
I hope I didn't give the impression that I'm an expert on all this.
I found (using strace on octave) that it libacml gets pulled in on line 875 or so. So it doesn't seem to depend on the environment. This is way after the default dependencies from Octave are loaded. I looked over the SlackBuild script, and found that there, some links are made to the amd files. I'm attaching the script. I've no idea how to avoid loading acml.
Glad to do any other tests...
(file #35238)
|
Mon 19 Oct 2015 11:59:33 PM UTC, comment #6:
Thanks for the info. What about the ACML library? Did you intentionally install that or configure Octave to use it, or is your environment loading it when Octave is being run? Can you try Octave without it and see if the segfault disappears?
To be clear I'm talking about the library /usr/lib64/libacml_mp.so that shows up in your gdb backtrace.
|
Mon 19 Oct 2015 11:32:14 PM UTC, comment #5:
Sorry about the delay.
I compiled GraphicsMagick with the following parameters:
./configure --prefix=/usr
--libdir=/usr/lib64
--with-quantum-depth=16
--enable-shared
--disable-static
--with-magick-plus-plus=yes
I then (re-)compiled Octave with the SlackBuild script.
Finally, I installed the Signal library (1.3.2) using the pkg install command.
|
Mon 19 Oct 2015 03:55:31 PM UTC, comment #4:
The backtrace looks like the error is occurring in the AMD ACML library, in a function called GetCacheInfo(). Moreover, I see that GraphicsMagick has a function called GetCacheInfo(Cache*).
I suspect some conflict between the ACML library and the GraphicsMagick library. Would be helpful to see if this crash only occurs when ACML is loaded (using LD_PRELOAD?)
@Pantxo: actually recently distributions have started building GM --with-quantum-depth=16 (RHEL 7, Fedora, Debian testing, Ubuntu 15.04).
|
Mon 19 Oct 2015 01:25:52 PM UTC, comment #3:
end of comment #2 should read
"... which is generally not the default for GraphicsMagick on linux distros."
|
Mon 19 Oct 2015 07:49:29 AM UTC, comment #2:
Hi,
Can you provide relevant informations on the way you installed Octave 4.0 and GraphicsMagic (responsible for loading image data from file). I see that you have quantum-depth=16 (instead of 8) which is generally the default for GraphicsMagick on linux distros.
|
Mon 19 Oct 2015 04:07:55 AM UTC, comment #1:
The signal library installed is version 1.3.2
|
Mon 19 Oct 2015 03:48:52 AM UTC, original submission:
When trying to read an image I get the following error:
warning: your version of GraphicsMagick limits images to 16 bits per pixel
panic: Segmentation fault -- stopping myself...
attempting to save variables to 'octave-workspace'...
save to 'octave-workspace' complete
octave exited with signal 11
I used the following code:
s1 = double(imread('st.png'));
I tried:
- Same code with st.png = converted from the original tif.
- I though the 'double' conversion was the problem, so I removed that too.
- I also tried another image altogether.
Attached the gdb backtrace
https://savannah.gnu.org/bugs/?41699 could be related if the underlying structures are of the type used.
https://savannah.gnu.org/bugs/?42488 is similar but I have no 'clear all' calls (and I'm using Linux)
Note that this is dissimilar to most bug reports, as this happens immediately - not on exit.
|