Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Windows 7 Pro VM Python 2.7 gives 5 test errors with latest release 0.10.1 #803

Closed
Garyfallidis opened this issue Dec 5, 2015 · 22 comments

Comments

@Garyfallidis
Copy link
Contributor

After doing in Windows 7 Pro (64 bit) (Python 2.7, Anaconda 2.0 with Numpy 1.8.1, Cython 0.20.1 and Scipy 0.14.0)

pip install dipy
import dipy
dipy.test()

I get the following errors

======================================================================
ERROR: dipy.segment.tests.test_feature.test_feature_extract
Traceback (most recent call last):
File "C:\Users\Eleftherios\Anaconda\lib\site-packages\nose\case.py", line 197, in runTest
self.test(*self.arg)
File "C:\Users\Eleftherios\Anaconda\lib\site-packages\dipy\segment\tests\test_feature.py", line 231, in test_feature_e
features = extract(feature, streamlines)
File "dipy/segment/featurespeed.pyx", line 371, in dipy.segment.featurespeed.extract (dipy\segment\featurespeed.c:6302
File "dipy/segment/featurespeed.pyx", line 394, in dipy.segment.featurespeed.extract (dipy\segment\featurespeed.c:5973
File "dipy/segment/featurespeed.pyx", line 363, in dipy.segment.featurespeed.infer_shape (dipy\segment\featurespeed.c:
File "dipy/segment/featurespeed.pyx", line 46, in dipy.segment.featurespeed.Feature.c_infer_shape (dipy\segment\featur
7)
TypeError: object of type 'long' has no len()
======================================================================
======================================================================
ERROR: dipy.tracking.tests.test_life.test_voxel2streamline
Traceback (most recent call last):
File "C:\Users\Eleftherios\Anaconda\lib\site-packages\nose\case.py", line 197, in runTest
self.test(*self.arg)
File "C:\Users\Eleftherios\Anaconda\lib\site-packages\dipy\tracking\tests\test_life.py", line 89, in test_voxel2stream
v2f, v2fn = life.voxel2streamline(streamline, False, affine)
File "C:\Users\Eleftherios\Anaconda\lib\site-packages\dipy\tracking\life.py", line 313, in voxel2streamline
return _voxel2streamline(transformed_streamline, unique_idx)
File "dipy/tracking/vox2track.pyx", line 20, in dipy.tracking.vox2track._voxel2streamline (dipy\tracking\vox2track.c:1
ValueError: Buffer dtype mismatch, expected 'npy_intp' but got 'long'
======================================================================
======================================================================
ERROR: dipy.tracking.tests.test_life.test_FiberModel_init
Traceback (most recent call last):
File "C:\Users\Eleftherios\Anaconda\lib\site-packages\nose\case.py", line 197, in runTest
self.test(*self.arg)
File "C:\Users\Eleftherios\Anaconda\lib\site-packages\dipy\tracking\tests\testlife.py", line 111, in test_FiberModel
fiber_matrix, vox_coords = FM.setup(streamline, affine, sphere=sphere)
File "C:\Users\Eleftherios\Anaconda\lib\site-packages\dipy\tracking\life.py", line 377, in setup
affine=affine, unique_idx=vox_coords)
File "C:\Users\Eleftherios\Anaconda\lib\site-packages\dipy\tracking\life.py", line 313, in voxel2streamline
return _voxel2streamline(transformed_streamline, unique_idx)
File "dipy/tracking/vox2track.pyx", line 20, in dipy.tracking.vox2track._voxel2streamline (dipy\tracking\vox2track.c:1
ValueError: Buffer dtype mismatch, expected 'npy_intp' but got 'long'
======================================================================
======================================================================
ERROR: dipy.tracking.tests.test_life.test_FiberFit
Traceback (most recent call last):
File "C:\Users\Eleftherios\Anaconda\lib\site-packages\nose\case.py", line 197, in runTest
self.test(*self.arg)
File "C:\Users\Eleftherios\Anaconda\lib\site-packages\dipy\tracking\tests\test_life.py", line 132, in test_FiberFit
fiber_matrix, vox_coords = FM.setup(streamline, None, evals)
File "C:\Users\Eleftherios\Anaconda\lib\site-packages\dipy\tracking\life.py", line 377, in setup
affine=affine, unique_idx=vox_coords)
File "C:\Users\Eleftherios\Anaconda\lib\site-packages\dipy\tracking\life.py", line 313, in voxel2streamline
return _voxel2streamline(transformed_streamline, unique_idx)
File "dipy/tracking/vox2track.pyx", line 20, in dipy.tracking.vox2track._voxel2streamline (dipy\tracking\vox2track.c:1
*ValueError: Buffer dtype mismatch, expected 'npy_intp' but got 'long'*
======================================================================
======================================================================
FAIL: dipy.viz.tests.test_fvtk_window.test_renderer
Traceback (most recent call last):
File "C:\Users\Eleftherios\Anaconda\lib\site-packages\nose\case.py", line 197, in runTest
self.test(self.arg)
File "C:\Users\Eleftherios\Anaconda\lib\site-packages\nose\util.py", line 619, in newfunc
return func(arg, kw)
File "C:\Users\Eleftherios\Anaconda\lib\site-packages\numpy\testing\decorators.py", line 146, in skipper_func
return f(*args, kwargs)
File "C:\Users\Eleftherios\Anaconda\lib\site-packages\dipy\testing\decorators.py", line 68, in test_with_xvfb
my_test()
File "C:\Users\Eleftherios\Anaconda\lib\site-packages\dipy\viz\tests\test_fvtk_window.py", line 36, in test_renderer
npt.assert_equal(report.colors_found, [True, False])
File "C:\Users\Eleftherios\Anaconda\lib\site-packages\numpy\testing\utils.py", line 255, in assert_equal
assert_equal(actual[k], desired[k], 'item=%r\n%s' % (k, err_msg), verbose)
File "C:\Users\Eleftherios\Anaconda\lib\site-packages\numpy\testing\utils.py", line 317, in assert_equal
raise AssertionError(msg)
AssertionError:
Items are not equal:
item=0
ACTUAL: False
DESIRED: True
@Garyfallidis
Copy link
Contributor Author

Can someone with a Windows machine try the same? pip install dipy and run the tests? These errors did not appear in the buildbots but appeared in my virtual machine which is a bit unexpected.

@Garyfallidis Garyfallidis changed the title Windows 7 Pro VM Python 2.7 test errors with latest release 0.10.1 Windows 7 Pro VM Python 2.7 gives 5 test errors with latest release 0.10.1 Dec 5, 2015
@matthew-brett
Copy link
Contributor

Perhaps the error is specific to Anaconda?

@Garyfallidis
Copy link
Contributor Author

Or Windows 64 bit specific? Can you remind me which of the win bots is the one with 64 bits?
For now I am trying to upgrade cython and recompile.

@matthew-brett
Copy link
Contributor

Could be 64-bits - we don't test Windows 64-bits at the moment.

@Garyfallidis
Copy link
Contributor Author

We should consider adding one maybe Win 8.1 or 10 machine (64bit) we have nobody working on the core-dev team on windows machines. So, we could be missing some errors there. Maybe Appveyor can help in this regard too.

@matthew-brett
Copy link
Contributor

Yes, sure, I will do that on a spare machine I have in my office on Monday.

@Garyfallidis
Copy link
Contributor Author

Just a bit of feedback here. Same errors appear with updating Cython.

@Garyfallidis
Copy link
Contributor Author

Cool, thumbs up for the spare machine!
@matthieudumont and @omarocegueda do you often develop on Windows these days? If yes whenever you see any errors on the nosetests please write an issue or provide a fix if possible. We currently miss eyeballing on 64 bit windows machines. Thx in advance.

@omarocegueda
Copy link
Contributor

Hi!,

@matthieudumont and @omarocegueda do you often develop on Windows these days?

sorry, I have been working on Linux since a few weeks because some automatic windows updates messed up my partition and the hard drive wasn't even recognized, I guess it was a conflict with my dual-boot configuration. Anyway, let me try to repro on my 64bit 8.1.

@omarocegueda
Copy link
Contributor

According to this post:
https://groups.google.com/forum/#!topic/cython-users/UX70kTr-6vk

"There are issues with the mingw runtime conflicting with the MSVC
runtime on Windows 64". This is the kind of errors I get when I attempt to build dipy:

/../x86_64-w64-mingw32/bin/ld.exe: warning: cannot find entry symbol _DllMain@12;

I started seeing these errors when I updated to Anaconda2-2.4-x86-64 in windows 8.1 64 bits. By any chance are you using mingw as well?

I will try using visual c instead (we may need to stop recommending people to use mingw =( )

@matthew-brett
Copy link
Contributor

Omar - I think the buildbots are all using MSVC - certainly for Python 3.5.

@omarocegueda
Copy link
Contributor

Thanks Matthew!, good to know!, I was using mingw because I was having problems with relatively recent versions of MSVC: I was having the typical error message saying that it cannot find vcvarsall.bat even though I had visual studio professional 2012. So at some point I tried mingw, everything worked fine, and I kept using it. Now I see there are more detailed instructions from the cython group.

@omarocegueda
Copy link
Contributor

Alright, I finally succeeded installing anaconda2 and the MS sdk on windows 8 64 bits, and I confirm that many tests are failing. In my case, its 9 regression tests from the registration module.

@matthew-brett
Copy link
Contributor

Attempt at Python 2.7 64-bit builds:

http://nipy.bic.berkeley.edu/builders/dipy-bdist64-27

Attempt at Python 3.5 64-bit builds:

http://nipy.bic.berkeley.edu/builders/dipy-bdist64-35

@matthew-brett
Copy link
Contributor

OK, we now have Python 2.7 and 3.5 builds on Windows 7 64-bit (links above) and a Python 3.5 build on Windows 10:

http://nipy.bic.berkeley.edu/builders/dipy-bdist64-35-win10

@arokem
Copy link
Contributor

arokem commented Dec 10, 2015

Since you have just done this installation, maybe you can help this person on the mailing list?

https://mail.python.org/pipermail/neuroimaging/2015-December/000672.html

@matthew-brett
Copy link
Contributor

That looks to be an Anaconda compilation error - I haven't installed or tested Anaconda. Omar - do you have any insights into that one?

@omarocegueda
Copy link
Contributor

I also had a lot of problems attempting to build extensions on win64. The root of the problem turned out to be mingw. When one looks on the internet, everybody recommends using mingw, but I think that's no longer a good idea because there is no stable version of mingw for 64bit arch. By following these instructions:

https://github.com/cython/cython/wiki/CythonExtensionsOnWindows

everything worked smoothly (except by the long time it took to download the SDK from Microsoft!). I was just hesitant about answering on the mailing list because the error messages this guy mentions are different from the ones I got, I didn't want to provide a misleading advise.

@matthew-brett
Copy link
Contributor

I'm worried that this is actually an Anaconda compiler configuration error.

@arokem
Copy link
Contributor

arokem commented Dec 11, 2015

Do you have instructions somewhere on how to build/install Dipy on Windows
without Anaconda?

On Wed, Dec 9, 2015 at 10:05 PM, Matthew Brett notifications@github.com
wrote:

I'm worried that this is actually an Anaconda compiler configuration
error.


Reply to this email directly or view it on GitHub
#803 (comment).

@matthew-brett
Copy link
Contributor

Not specifically, but it's the same for any windows compiled project : https://matthew-brett.github.io/pydagogue/python_msvc.html

@matthew-brett
Copy link
Contributor

I think we should close this one, because I think we have reports +/- proposed fixes for the component failures open now:

#806
#810
#812
#813

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants