[Scipy-tickets] [SciPy] #824: ndimage.histogram is broken for Scipy v0.6 (Fedora 10)

SciPy scipy-tickets@scipy....
Tue Dec 23 12:28:00 CST 2008


#824: ndimage.histogram is broken for Scipy v0.6 (Fedora 10)
---------------------------+------------------------------------------------
 Reporter:  vossman        |       Owner:  somebody         
     Type:  defect         |      Status:  new              
 Priority:  normal         |   Milestone:                   
Component:  scipy.ndimage  |     Version:  devel            
 Severity:  major          |    Keywords:  ndimage histogram
---------------------------+------------------------------------------------
 I am part of science lab where we develop an open source product.
 Unfortunately, our software crashes for both Fedora 9 and 10. I narrowed
 the problem down to a function in Scipy. When I run the script:

 {{{
 #!/usr/bin/env python
 import sys
 import scipy
 import scipy.ndimage
 import numpy
 a = numpy.zeros((4,4))
 a[1, 0:2] = 1
 a[1:4, 3] = 2
 print "python v", sys.version
 print "numpy v", numpy.__version__
 print "scipy v", scipy.__version__
 print a
 print "\nresult="
 print scipy.ndimage.histogram(a, min=1, max=3, bins=2)
 }}}

 On all of of CentOS 5 machines I get the expected result:

 {{{
 python v 2.4.3 (#1, May 24 2008, 13:57:05)
 [GCC 4.1.2 20070626 (Red Hat 4.1.2-14)]
 numpy v 1.0.3
 scipy v 0.5.2
 [[ 0.  0.  0.  0.]
  [ 1.  1.  0.  2.]
  [ 0.  0.  0.  2.]
  [ 0.  0.  0.  2.]]

 result=
 [2 3]
 }}}

 But on our two x86_64 Fedora 10 machines, I get an "Illegal instruction"
 error that breaks the entire script, even overrides try/except clauses:

 {{{
 python v 2.5.2 (r252:60911, Sep 30 2008, 15:42:03)
 [GCC 4.3.2 20080917 (Red Hat 4.3.2-4)]
 numpy v 1.2.0
 scipy v 0.6.0
 [[ 0.  0.  0.  0.]
  [ 1.  1.  0.  2.]
  [ 0.  0.  0.  2.]
  [ 0.  0.  0.  2.]]

 result=
 Illegal instruction
 }}}

 In addition, if I run it on our older i686 Fedora 9 box:

 {{{
 python v 2.5.1 (r251:54863, Apr  8 2008, 01:20:16)
 [GCC 4.3.0 20080404 (Red Hat 4.3.0-6)]
 numpy v 1.0.3.1
 scipy v 0.6.0
 [[ 0.  0.  0.  0.]
  [ 1.  1.  0.  2.]
  [ 0.  0.  0.  2.]
  [ 0.  0.  0.  2.]]

 result=
 Illegal instruction
 }}}

 So, I believe the problem is with Scipy not Fedora. Let me know if I can
 provide more information

-- 
Ticket URL: <http://scipy.org/scipy/scipy/ticket/824>
SciPy <http://www.scipy.org/>
SciPy is open-source software for mathematics, science, and engineering.


More information about the Scipy-tickets mailing list