The following code works as expected when I type it in the REPL

using PyPlot

x=linspace(0, pi, 201)
figure(1)
plot(x, cos(x))

But including it from a file frequently leads to an error with the 
following traceback

ERROR: LAPACKException(139839840190464)
 in getri! at linalg/lapack.jl:587
 in inv at linalg/lu.jl:149
 in inv at linalg/dense.jl:328
 in include at ./boot.jl:245
 in include_from_node1 at ./loading.jl:128
 in include at ./boot.jl:245
 in include_from_node1 at ./loading.jl:128
 in reload_path at loading.jl:152
 in _require at loading.jl:67
 in require at loading.jl:54
 in include at ./boot.jl:245
 in include_from_node1 at ./loading.jl:128
 in include at ./boot.jl:245
 in include_from_node1 at ./loading.jl:128
 in reload_path at loading.jl:152
 in _require at loading.jl:67
 in require at loading.jl:51
 in include at ./boot.jl:245
 in include_from_node1 at ./loading.jl:128
while loading /home/nfs/z8900007/.julia/Color/src/conversions.jl, in 
expression starting on line 652
while loading /home/nfs/z8900007/.julia/Color/src/Color.jl, in expression 
starting on line 36
while loading /home/nfs/z8900007/.julia/PyPlot/src/colormaps.jl, in 
expression starting on line 4
while loading /home/nfs/z8900007/.julia/PyPlot/src/PyPlot.jl, in expression 
starting on line 399
while loading /home/nfs/z8900007/scratch/julia/Bar.jl, in expression 
starting on line 1

Lines 647-652 in Color/src/conversions.jl are

# Chromatic adaptation from CIECAM02
const CAT02 = [ 0.7328 0.4296 -0.1624
                         -0.7036 1.6975  0.0061
                          0.0030 0.0136  0.9834 ]

const CAT02_INV = inv(CAT02)

so something goes wrong when julia asks Lapack to invert this 3x3 matrix.

I am running

julia  0.3.2
PyPlot 1.4.3
Color 0.3.13
Kubuntu 14.04 
Python 2.7.6 
Matplotlib 1.3.1.

and built the julia executable from source. 

Reply via email to