[SciPy-User] test issues with 0.10

Paul Anton Letnes paul.anton.letnes at gmail.com
Tue Nov 15 03:00:50 EST 2011


Trying again; to me it does not look like the compiler is the issue here. But what do I know :)

OT: Does anyone know what the difficulty is with building a working gfortran on OS X? This is something I never understood properly.

Build:
i-courant ~/src/scipy-0.10.0 % ATLAS= BLAS=/System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib LAPACK=/System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libLAPACK.dylib CC=/usr/bin/gcc FC=/usr/local/bin/gfortran-4.2 CXX=/usr/bin/g++ python setup.py build

Install:
i-courant ~/src/scipy-0.10.0 % python setup.py install

Test results:
i-courant /tmp % python -c 'import scipy; scipy.test(verbose=1)'                       [8:56:33 on 11-11-15]
Running unit tests for scipy
NumPy version 1.6.1
NumPy is installed in /usr/local/Cellar/python/2.7.2/lib/python2.7/site-packages/numpy
SciPy version 0.10.0
SciPy is installed in /usr/local/Cellar/python/2.7.2/lib/python2.7/site-packages/scipy
Python version 2.7.2 (default, Oct  9 2011, 18:03:13) [GCC 4.2.1 (Apple Inc. build 5666) (dot 3)]
nose version 1.1.2
...................................................................................................................................................................................F.python(78903) malloc: *** error for object 0x104bf78e8: incorrect checksum for freed object - object was probably modified after being freed.
*** set a breakpoint in malloc_error_break to debug
zsh: abort      python -c 'import scipy; scipy.test(verbose=1)'
i-courant /tmp/paulanto % python -c 'import scipy; scipy.test(verbose=2)'                       [8:56:52 on 11-11-15]
Running unit tests for scipy
NumPy version 1.6.1
NumPy is installed in /usr/local/Cellar/python/2.7.2/lib/python2.7/site-packages/numpy
SciPy version 0.10.0
SciPy is installed in /usr/local/Cellar/python/2.7.2/lib/python2.7/site-packages/scipy
Python version 2.7.2 (default, Oct  9 2011, 18:03:13) [GCC 4.2.1 (Apple Inc. build 5666) (dot 3)]
nose version 1.1.2
Tests cophenet(Z) on tdist data set. ... ok
Tests cophenet(Z, Y) on tdist data set. ... ok
Tests correspond(Z, y) on linkage and CDMs over observation sets of different sizes. ... ok
Tests correspond(Z, y) on linkage and CDMs over observation sets of different sizes. Correspondance should be false. ... ok
Tests correspond(Z, y) on linkage and CDMs over observation sets of different sizes. Correspondance should be false. ... ok
Tests correspond(Z, y) with empty linkage and condensed distance matrix. ... ok
Tests num_obs_linkage with observation matrices of multiple sizes. ... ok
Tests fcluster(Z, criterion='maxclust', t=2) on a random 3-cluster data set. ... ok
Tests fcluster(Z, criterion='maxclust', t=3) on a random 3-cluster data set. ... ok
Tests fcluster(Z, criterion='maxclust', t=4) on a random 3-cluster data set. ... ok
Tests fclusterdata(X, criterion='maxclust', t=2) on a random 3-cluster data set. ... ok
Tests fclusterdata(X, criterion='maxclust', t=3) on a random 3-cluster data set. ... ok
Tests fclusterdata(X, criterion='maxclust', t=4) on a random 3-cluster data set. ... ok
Tests from_mlab_linkage on empty linkage array. ... ok
Tests from_mlab_linkage on linkage array with multiple rows. ... ok
Tests from_mlab_linkage on linkage array with single row. ... ok
Tests inconsistency matrix calculation (depth=1) on a complete linkage. ... ok
Tests inconsistency matrix calculation (depth=2) on a complete linkage. ... ok
Tests inconsistency matrix calculation (depth=3) on a complete linkage. ... ok
Tests inconsistency matrix calculation (depth=4) on a complete linkage. ... ok
Tests inconsistency matrix calculation (depth=1, dataset=Q) with single linkage. ... ok
Tests inconsistency matrix calculation (depth=2, dataset=Q) with single linkage. ... ok
Tests inconsistency matrix calculation (depth=3, dataset=Q) with single linkage. ... ok
Tests inconsistency matrix calculation (depth=4, dataset=Q) with single linkage. ... ok
Tests inconsistency matrix calculation (depth=1) on a single linkage. ... ok
Tests inconsistency matrix calculation (depth=2) on a single linkage. ... ok
Tests inconsistency matrix calculation (depth=3) on a single linkage. ... ok
Tests inconsistency matrix calculation (depth=4) on a single linkage. ... ok
Tests is_isomorphic on test case #1 (one flat cluster, different labellings) ... ok
Tests is_isomorphic on test case #2 (two flat clusters, different labelings) ... ok
Tests is_isomorphic on test case #3 (no flat clusters) ... ok
Tests is_isomorphic on test case #4A (3 flat clusters, different labelings, isomorphic) ... ok
Tests is_isomorphic on test case #4B (3 flat clusters, different labelings, nonisomorphic) ... ok
Tests is_isomorphic on test case #4C (3 flat clusters, different labelings, isomorphic) ... ok
Tests is_isomorphic on test case #5A (1000 observations, 2 random clusters, random permutation of the labeling). Run 3 times. ... ok
Tests is_isomorphic on test case #5B (1000 observations, 3 random clusters, random permutation of the labeling). Run 3 times. ... ok
Tests is_isomorphic on test case #5C (1000 observations, 5 random clusters, random permutation of the labeling). Run 3 times. ... ok
Tests is_isomorphic on test case #5A (1000 observations, 2 random clusters, random permutation of the labeling, slightly nonisomorphic.) Run 3 times. ... ok
Tests is_isomorphic on test case #5B (1000 observations, 3 random clusters, random permutation of the labeling, slightly nonisomorphic.) Run 3 times. ... ok
Tests is_isomorphic on test case #5C (1000 observations, 5 random clusters, random permutation of the labeling, slightly non-isomorphic.) Run 3 times. ... ok
Tests is_monotonic(Z) on 1x4 linkage. Expecting True. ... ok
Tests is_monotonic(Z) on 2x4 linkage. Expecting False. ... ok
Tests is_monotonic(Z) on 2x4 linkage. Expecting True. ... ok
Tests is_monotonic(Z) on 3x4 linkage (case 1). Expecting False. ... ok
Tests is_monotonic(Z) on 3x4 linkage (case 2). Expecting False. ... ok
Tests is_monotonic(Z) on 3x4 linkage (case 3). Expecting False ... ok
Tests is_monotonic(Z) on 3x4 linkage. Expecting True. ... ok
Tests is_monotonic(Z) on an empty linkage. ... ok
Tests is_monotonic(Z) on clustering generated by single linkage on Iris data set. Expecting True. ... ok
Tests is_monotonic(Z) on clustering generated by single linkage on tdist data set. Expecting True. ... ok
Tests is_monotonic(Z) on clustering generated by single linkage on tdist data set. Perturbing. Expecting False. ... ok
Tests is_valid_im(R) on im over 2 observations. ... ok
Tests is_valid_im(R) on im over 3 observations. ... ok
Tests is_valid_im(R) with 3 columns. ... ok
Tests is_valid_im(R) on im on observation sets between sizes 4 and 15 (step size 3). ... ok
Tests is_valid_im(R) on im on observation sets between sizes 4 and 15 (step size 3) with negative link counts. ... ok
Tests is_valid_im(R) on im on observation sets between sizes 4 and 15 (step size 3) with negative link height means. ... ok
Tests is_valid_im(R) on im on observation sets between sizes 4 and 15 (step size 3) with negative link height standard deviations. ... ok
Tests is_valid_im(R) with 5 columns. ... ok
Tests is_valid_im(R) with empty inconsistency matrix. ... ok
Tests is_valid_im(R) with integer type. ... ok
Tests is_valid_linkage(Z) on linkage over 2 observations. ... ok
Tests is_valid_linkage(Z) on linkage over 3 observations. ... ok
Tests is_valid_linkage(Z) with 3 columns. ... ok
Tests is_valid_linkage(Z) on linkage on observation sets between sizes 4 and 15 (step size 3). ... ok
Tests is_valid_linkage(Z) on linkage on observation sets between sizes 4 and 15 (step size 3) with negative counts. ... ok
Tests is_valid_linkage(Z) on linkage on observation sets between sizes 4 and 15 (step size 3) with negative distances. ... ok
Tests is_valid_linkage(Z) on linkage on observation sets between sizes 4 and 15 (step size 3) with negative indices (left). ... ok
Tests is_valid_linkage(Z) on linkage on observation sets between sizes 4 and 15 (step size 3) with negative indices (right). ... ok
Tests is_valid_linkage(Z) with 5 columns. ... ok
Tests is_valid_linkage(Z) with empty linkage. ... ok
Tests is_valid_linkage(Z) with integer type. ... ok
Tests leaders using a flat clustering generated by single linkage. ... ok
Tests leaves_list(Z) on a 1x4 linkage. ... ok
Tests leaves_list(Z) on a 2x4 linkage. ... ok
Tests leaves_list(Z) on the Iris data set using average linkage. ... ok
Tests leaves_list(Z) on the Iris data set using centroid linkage. ... ok
Tests leaves_list(Z) on the Iris data set using complete linkage. ... ok
Tests leaves_list(Z) on the Iris data set using median linkage. ... ok
Tests leaves_list(Z) on the Iris data set using single linkage. ... ok
Tests leaves_list(Z) on the Iris data set using ward linkage. ... ok
Tests linkage(Y, 'average') on the tdist data set. ... ok
Tests linkage(Y, 'centroid') on the Q data set. ... ok
Tests linkage(Y, 'complete') on the Q data set. ... ok
Tests linkage(Y, 'complete') on the tdist data set. ... ok
Tests linkage(Y) where Y is a 0x4 linkage matrix. Exception expected. ... ok
Tests linkage(Y, 'single') on the Q data set. ... ok
Tests linkage(Y, 'single') on the tdist data set. ... ok
Tests linkage(Y, 'weighted') on the Q data set. ... ok
Tests linkage(Y, 'weighted') on the tdist data set. ... ok
Tests maxdists(Z) on the Q data set using centroid linkage. ... ok
Tests maxdists(Z) on the Q data set using complete linkage. ... ok
Tests maxdists(Z) on the Q data set using median linkage. ... ok
Tests maxdists(Z) on the Q data set using single linkage. ... ok
Tests maxdists(Z) on the Q data set using Ward linkage. ... ok
Tests maxdists(Z) on empty linkage. Expecting exception. ... ok
Tests maxdists(Z) on linkage with one cluster. ... ok
Tests maxinconsts(Z, R) on the Q data set using centroid linkage. ... ok
Tests maxinconsts(Z, R) on the Q data set using complete linkage. ... ok
Tests maxinconsts(Z, R) on the Q data set using median linkage. ... ok
Tests maxinconsts(Z, R) on the Q data set using single linkage. ... ok
Tests maxinconsts(Z, R) on the Q data set using Ward linkage. ... ok
Tests maxinconsts(Z, R) on linkage and inconsistency matrices with different numbers of clusters. Expecting exception. ... ok
Tests maxinconsts(Z, R) on empty linkage. Expecting exception. ... ok
Tests maxinconsts(Z, R) on linkage with one cluster. ... ok
Tests maxRstat(Z, R, 0) on the Q data set using centroid linkage. ... ok
Tests maxRstat(Z, R, 0) on the Q data set using complete linkage. ... ok
Tests maxRstat(Z, R, 0) on the Q data set using median linkage. ... ok
Tests maxRstat(Z, R, 0) on the Q data set using single linkage. ... ok
Tests maxRstat(Z, R, 0) on the Q data set using Ward linkage. ... ok
Tests maxRstat(Z, R, 0) on linkage and inconsistency matrices with different numbers of clusters. Expecting exception. ... ok
Tests maxRstat(Z, R, 0) on empty linkage. Expecting exception. ... ok
Tests maxRstat(Z, R, 0) on linkage with one cluster. ... ok
Tests maxRstat(Z, R, 1) on the Q data set using centroid linkage. ... ok
Tests maxRstat(Z, R, 1) on the Q data set using complete linkage. ... ok
Tests maxRstat(Z, R, 1) on the Q data set using median linkage. ... ok
Tests maxRstat(Z, R, 1) on the Q data set using single linkage. ... ok
Tests maxRstat(Z, R, 1) on the Q data set using Ward linkage. ... ok
Tests maxRstat(Z, R, 1) on linkage and inconsistency matrices with different numbers of clusters. Expecting exception. ... ok
Tests maxRstat(Z, R, 1) on empty linkage. Expecting exception. ... ok
Tests maxRstat(Z, R, 1) on linkage with one cluster. ... ok
Tests maxRstat(Z, R, 2) on the Q data set using centroid linkage. ... ok
Tests maxRstat(Z, R, 2) on the Q data set using complete linkage. ... ok
Tests maxRstat(Z, R, 2) on the Q data set using median linkage. ... ok
Tests maxRstat(Z, R, 2) on the Q data set using single linkage. ... ok
Tests maxRstat(Z, R, 2) on the Q data set using Ward linkage. ... ok
Tests maxRstat(Z, R, 2) on linkage and inconsistency matrices with different numbers of clusters. Expecting exception. ... ok
Tests maxRstat(Z, R, 2) on empty linkage. Expecting exception. ... ok
Tests maxRstat(Z, R, 2) on linkage with one cluster. ... ok
Tests maxRstat(Z, R, 3) on the Q data set using centroid linkage. ... ok
Tests maxRstat(Z, R, 3) on the Q data set using complete linkage. ... ok
Tests maxRstat(Z, R, 3) on the Q data set using median linkage. ... ok
Tests maxRstat(Z, R, 3) on the Q data set using single linkage. ... ok
Tests maxRstat(Z, R, 3) on the Q data set using Ward linkage. ... ok
Tests maxRstat(Z, R, 3) on linkage and inconsistency matrices with different numbers of clusters. Expecting exception. ... ok
Tests maxRstat(Z, R, 3) on empty linkage. Expecting exception. ... ok
Tests maxRstat(Z, R, 3) on linkage with one cluster. ... ok
Tests maxRstat(Z, R, 3.3). Expecting exception. ... ok
Tests maxRstat(Z, R, -1). Expecting exception. ... ok
Tests maxRstat(Z, R, 4). Expecting exception. ... ok
Tests num_obs_linkage(Z) on linkage over 2 observations. ... ok
Tests num_obs_linkage(Z) on linkage over 3 observations. ... ok
Tests num_obs_linkage(Z) on linkage on observation sets between sizes 4 and 15 (step size 3). ... ok
Tests num_obs_linkage(Z) with empty linkage. ... ok
Tests to_mlab_linkage on linkage array with multiple rows. ... ok
Tests to_mlab_linkage on empty linkage array. ... ok
Tests to_mlab_linkage on linkage array with single row. ... ok
test_hierarchy.load_testing_files ... ok
Ticket #505. ... ok
Testing that kmeans2 init methods work. ... ok
Testing simple call to kmeans2 with rank 1 data. ... ok
Testing simple call to kmeans2 with rank 1 data. ... ok
Testing simple call to kmeans2 and its results. ... ok
Regression test for #546: fail when k arg is 0. ... ok
This will cause kmean to have a cluster with no points. ... ok
test_kmeans_simple (test_vq.TestKMean) ... ok
test_large_features (test_vq.TestKMean) ... ok
test_py_vq (test_vq.TestVq) ... ok
test_py_vq2 (test_vq.TestVq) ... ok
test_vq (test_vq.TestVq) ... ok
Test special rank 1 vq algo, python implementation. ... ok
test_codata.test_find ... ok
test_codata.test_basic_table_parse ... ok
test_codata.test_basic_lookup ... ok
test_codata.test_find_all ... ok
test_codata.test_find_single ... ok
test_codata.test_2002_vs_2006 ... ok
Check that updating stored values with exact ones worked. ... ok
test_constants.test_fahrenheit_to_celcius ... ok
test_constants.test_celcius_to_kelvin ... ok
test_constants.test_kelvin_to_celcius ... ok
test_constants.test_fahrenheit_to_kelvin ... ok
test_constants.test_kelvin_to_fahrenheit ... ok
test_constants.test_celcius_to_fahrenheit ... ok
test_constants.test_lambda_to_nu ... ok
test_constants.test_nu_to_lambda ... ok
test_definition (test_basic.TestDoubleFFT) ... ok
test_djbfft (test_basic.TestDoubleFFT) ... ok
test_n_argument_real (test_basic.TestDoubleFFT) ... ok
test_definition (test_basic.TestDoubleIFFT) ... FAIL
test_definition_real (test_basic.TestDoubleIFFT) ... ok
test_djbfft (test_basic.TestDoubleIFFT) ... zsh: segmentation fault  python -c 'import scipy; scipy.test(verbose=2)'



On 14. nov. 2011, at 21:56, Ralf Gommers wrote:

> 
> 
> On Mon, Nov 14, 2011 at 9:17 PM, Paul Anton Letnes <paul.anton.letnes at gmail.com> wrote:
> 
> On 14. nov. 2011, at 20:48, Ralf Gommers wrote:
> 
> >
> >
> > On Mon, Nov 14, 2011 at 3:20 PM, Paul Anton Letnes <paul.anton.letnes at gmail.com> wrote:
> > Hi, when trying to build scipy 0.10 with python 2.7 (from homebrew/python.org), numpy 1.6.1 (built manually) on Mac OS X 10.7.2 and with gcc 4.6.0 (built from source), scipy.test() breaks. Any ideas?
> >
> > Was everything including python itself built with gcc 4.6.0?
> 
> No; I'm sorry about the screwup on version numbers. Here are the correct ones:
> 
> i-courant ~/src/scipy-0.10.0 % python
> Python 2.7.2 (default, Oct  9 2011, 18:03:13)
> [GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] on darwin
> Type "help", "copyright", "credits" or "license" for more information.
> so python was built with Apple GCC 4.2.1. The same goes for numpy. The reason is that numpy and scipy setup tries to send the -faltivec flag to the compiler, which only Apple's gcc accepts. Same gcc version with scipy. The gfortran version, however, is 4.6.0. Apple's gcc installation does not include gfortran, so that's why I installed a separate gfortran.
> 
> That's not the correct gfortran. Through homebrew you should be able to get the right one, or download it directly: (http://r.research.att.com/gfortran-lion-5666-3.pkg). It is version 4.2.4, but may report itself as 4.2.1.
> 
> The -faltivec thing was a numpy distutils issue that is fixed in numpy master. It shouldn't have given you any problems, it just caused you to miss out on SSE optimizations.
> 
> (As a side question, what's a reliable way of getting all this (recent gfortran, numpy, scipy) installed? Homebrew is not very helpful with alternative gcc installations, neither is Apple…)
> 
> On OS X 10.7 this is still a bit painful due to the switch to llvm-gcc as default compiler. But if you get the right gfortran, linked also from http://scipy.org/Installing_SciPy/Mac_OS_X, and set gcc as default compiler you should be good to go. Of course there are binary installers too that work on 10.7 if you don't want to fight with compilers. That's just a matter of downloading Python from python.org and numpy/scipy from Sourceforge.
> 
> > What was the last version of scipy that did work for you?
> 
> 0.10.b2 was working fine, although not all tests passed. I figured it would be ironed out before release. (I did not use any of the problematic sub-modules anyway.)
> 
> With the same compilers, that's odd. No changes to fftpack code or tests went in since beta 2. 
> 
> Ralf
> 
> _______________________________________________
> SciPy-User mailing list
> SciPy-User at scipy.org
> http://mail.scipy.org/mailman/listinfo/scipy-user




More information about the SciPy-User mailing list