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

weave not working with anaconda #13

Open
Krzysiaczek99 opened this issue Feb 21, 2019 · 2 comments
Open

weave not working with anaconda #13

Krzysiaczek99 opened this issue Feb 21, 2019 · 2 comments
Labels

Comments

@Krzysiaczek99
Copy link

Krzysiaczek99 commented Feb 21, 2019

recently i tried weave with python 2.7 (64 bit) from anaconda and i come to multiple issues.

see Stackoverflow question

https://stackoverflow.com/questions/54764514/weawve-importerror-dll-load-failed-1-is-not-a-valid-win32-application-anacond

additionally i tried to test the distribution from command line with nose for both python 2.7 from anaconda and python 2.7 32 bit (XY) amd it also fails

ENo module named msvccompiler in numpy.distutils; trying from distutils
Cannot build msvcr library: "msvcr90d.dll" not found
Cannot build msvcr library: "msvcr90d.dll" not found
E...............................................................................................
======================================================================
ERROR: test_5point_avg_2d_complex_double (test_blitz_tools.TestBlitz)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "C:\Python27\lib\site-packages\weave\tests\test_blitz_tools.py", line 147, in test_5point_avg_2d_complex_double
    self.generic_2d(expr,complex128)
  File "C:\Python27\lib\site-packages\weave\tests\test_blitz_tools.py", line 94, in generic_2d
    standard,compiled = self.generic_check(expr,arg_dict,type,size)
  File "C:\Python27\lib\site-packages\weave\tests\test_blitz_tools.py", line 67, in generic_check
    blitz_tools.blitz(expr,arg_dict,{},verbose=0)
  File "C:\Python27\lib\site-packages\weave\blitz_tools.py", line 68, in blitz
    **kw)
  File "C:\Python27\lib\site-packages\weave\inline_tools.py", line 502, in compile_function
    exec('import ' + module_name)
  File "<string>", line 1, in <module>
ImportError: DLL load failed: The specified procedure could not be found.

and for anaconda python

Retaining cwd: c:\users\krzysz~1.faj\appdata\local\temp\1\krzysztof.fajst\python27_compiled\m1Retaining cwd: c:\users\krzysz~1.faj\appdata\local\temp\1\krzysztof.fajst\python27_compiled\m1

_preserve_environment([])
_preserve_environment([])
_update_environment(...)
_update_environment(...)
_update_environment(...)
_update_environment(...)
g++ -g -shared c:\users\krzysz~1.faj\appdata\local\temp\1\weave-krzysztof.fajst-iaqybo\python27_intermediate\compiler_e3b0c44298fc1c149afbf4c8996fb924\Release\users\krzysz~1.faj\appdata\local\temp\1\krzysztof.fajst\python27_compiled\m1\sc_0340c4711ae583ecbbd754dae5e2aea60.o c:\users\krzysz~1.faj\appdata\local\temp\1\weave-krzysztof.fajst-iaqybo\python27_intermediate\compiler_e3b0c44298fc1c149afbf4c8996fb924\Release\programdata\anaconda3\envs\python27\lib\site-packages\weave\scxx\weave_imp.o -LC:\ProgramData\Anaconda3\envs\Python27\libs -LC:\ProgramData\Anaconda3\envs\Python27\PCbuild\amd64 -LC:\ProgramData\Anaconda3\envs\Python27\PC\VS9.0\amd64 -lpython27 -lmsvcr90 -o c:\users\krzysz~1.faj\appdata\local\temp\1\krzysztof.fajst\python27_compiled\m1\sc_0340c4711ae583ecbbd754dae5e2aea60.pyd
exec_command(['g++', '-g', '-shared', 'c:\\users\\krzysz~1.faj\\appdata\\local\\temp\\1\\weave-krzysztof.fajst-iaqybo\\python27_intermediate\\compiler_e3b0c44298fc1c149afbf4c8996fb924\\Release\\users\\krzysz~1.faj\\appdata\\local\\temp\\1\\krzysztof.fajst\\python27_compiled\\m1\\sc_0340c4711ae583ecbbd754dae5e2aea60.o', 'c:\\users\\krzysz~1.faj\\appdata\\local\\temp\\1\\weave-krzysztof.fajst-iaqybo\\python27_intermediate\\compiler_e3b0c44298fc1c149afbf4c8996fb924\\Release\\programdata\\anaconda3\\envs\\python27\\lib\\site-packages\\weave\\scxx\\weave_imp.o', '-LC:\\ProgramData\\Anaconda3\\envs\\Python27\\libs', '-LC:\\ProgramData\\Anaconda3\\envs\\Python27\\PCbuild\\amd64', '-LC:\\ProgramData\\Anaconda3\\envs\\Python27\\PC\\VS9.0\\amd64', '-lpython27', '-lmsvcr90', '-o', 'c:\\users\\krzysz~1.faj\\appdata\\local\\temp\\1\\krzysztof.fajst\\python27_compiled\\m1\\sc_0340c4711ae583ecbbd754dae5e2aea60.pyd'],)
Retaining cwd: c:\users\krzysz~1.faj\appdata\local\temp\1\krzysztof.fajst\python27_compiled\m1
_preserve_environment([])
_update_environment(...)
_update_environment(...)
Eset_threshold: not changing threshold from DEBUG level 1 to 4
running build_ext
running build_src
build_src
building extension "sc_173243115fe8831dd7db82e9d5b3f1520" sources
build_src: building npy-pkg config files
Skip building import library: "C:\ProgramData\Anaconda3\envs\Python27\libs\libpython27.a" exists
new_compiler returns numpy.distutils.mingw32ccompiler.Mingw32CCompiler
customize Mingw32CCompiler
customize Mingw32CCompiler using build_ext
********************************************************************************
numpy.distutils.mingw32ccompiler.Mingw32CCompiler
linker_exe    = ['gcc', '-g']
compiler_so   = ['gcc', '-g', '-DDEBUG', '-DMS_WIN64', '-O0', '-Wall', '-Wstrict-prototypes']
archiver      = ['ar', '-cr']
preprocessor  = None
linker_so     = ['gcc', '-g', '-shared']
compiler_cxx  = ['g++']
ranlib        = None
compiler      = ['gcc', '-g', '-DDEBUG', '-DMS_WIN64', '-O0', '-Wall']
libraries     = []
library_dirs  = ['C:\\ProgramData\\Anaconda3\\envs\\Python27\\libs', 'C:\\ProgramData\\Anaconda3\\envs\\Python27\\PCbuild\\amd64', 'C:\\ProgramData\\Anaconda3\\envs\\Python27\\PC\\VS9.0\\amd64']
include_dirs  = ['C:\\ProgramData\\Anaconda3\\envs\\Python27\\include', 'C:\\ProgramData\\Anaconda3\\envs\\Python27\\PC']
********************************************************************************
Skip building import library: "C:\ProgramData\Anaconda3\envs\Python27\libs\libpython27.a" exists
new_compiler returns numpy.distutils.mingw32ccompiler.Mingw32CCompiler
customize Mingw32CCompiler
customize Mingw32CCompiler using build_ext
********************************************************************************
numpy.distutils.mingw32ccompiler.Mingw32CCompiler
linker_exe    = ['gcc', '-g']
compiler_so   = ['gcc', '-g', '-DDEBUG', '-DMS_WIN64', '-O0', '-Wall']
archiver      = ['ar', '-cr']
preprocessor  = None
linker_so     = ['gcc', '-g', '-shared']
compiler_cxx  = ['g++']
ranlib        = None
compiler      = ['gcc', '-g', '-DDEBUG', '-DMS_WIN64', '-O0', '-Wall']
libraries     = []
library_dirs  = ['C:\\ProgramData\\Anaconda3\\envs\\Python27\\libs', 'C:\\ProgramData\\Anaconda3\\envs\\Python27\\PCbuild\\amd64', 'C:\\ProgramData\\Anaconda3\\envs\\Python27\\PC\\VS9.0\\amd64']
include_dirs  = ['C:\\ProgramData\\Anaconda3\\envs\\Python27\\include', 'C:\\ProgramData\\Anaconda3\\envs\\Python27\\PC']
********************************************************************************
building 'sc_173243115fe8831dd7db82e9d5b3f1520' extension
compiling C++ sources
C compiler: g++ -g -DDEBUG -DMS_WIN64 -O0 -Wall

compile options: '-D__MSVCRT_VERSION__=0x1500 -IC:\ProgramData\Anaconda3\envs\Python27\lib\site-packages\weave -IC:\ProgramData\Anaconda3\envs\Python27\lib\site-packages\weave\scxx -IC:\ProgramData\Anaconda3\envs\Python27\lib\site-packages\numpy\core\include -IC:\ProgramData\Anaconda3\envs\Python27\include -IC:\ProgramData\Anaconda3\envs\Python27\PC -c'
g++ -g -DDEBUG -DMS_WIN64 -O0 -Wall -D__MSVCRT_VERSION__=0x1500 -IC:\ProgramData\Anaconda3\envs\Python27\lib\site-packages\weave -IC:\ProgramData\Anaconda3\envs\Python27\lib\site-packages\weave\scxx -IC:\ProgramData\Anaconda3\envs\Python27\lib\site-packages\numpy\core\include -IC:\ProgramData\Anaconda3\envs\Python27\include -IC:\ProgramData\Anaconda3\envs\Python27\PC -c c:\users\krzysz~1.faj\appdata\local\temp\1\krzysztof.fajst\python27_compiled\m1\sc_173243115fe8831dd7db82e9d5b3f1520.cpp -o c:\users\krzysz~1.faj\appdata\local\temp\1\weave-krzysztof.fajst-iaqybo\python27_intermediate\compiler_e3b0c44298fc1c149afbf4c8996fb924\Release\users\krzysz~1.faj\appdata\local\temp\1\krzysztof.fajst\python27_compiled\m1\sc_173243115fe8831dd7db82e9d5b3f1520.og++ -g -DDEBUG -DMS_WIN64 -O0 -Wall -D__MSVCRT_VERSION__=0x1500 -IC:\ProgramData\Anaconda3\envs\Python27\lib\site-packages\weave -IC:\ProgramData\Anaconda3\envs\Python27\lib\site-packages\weave\scxx -IC:\ProgramData\Anaconda3\envs\Python27\lib\site-packages\numpy\core\include -IC:\ProgramData\Anaconda3\envs\Python27\include -IC:\ProgramData\Anaconda3\envs\Python27\PC -c C:\ProgramData\Anaconda3\envs\Python27\lib\site-packages\weave\scxx\weave_imp.cpp -o c:\users\krzysz~1.faj\appdata\local\temp\1\weave-krzysztof.fajst-iaqybo\python27_intermediate\compiler_e3b0c44298fc1c149afbf4c8996fb924\Release\programdata\anaconda3\envs\python27\lib\site-packages\weave\scxx\weave_imp.o

exec_command(['g++', '-g', '-DDEBUG', '-DMS_WIN64', '-O0', '-Wall', '-D__MSVCRT_VERSION__=0x1500', '-IC:\\ProgramData\\Anaconda3\\envs\\Python27\\lib\\site-packages\\weave', '-IC:\\ProgramData\\Anaconda3\\envs\\Python27\\lib\\site-packages\\weave\\scxx', '-IC:\\ProgramData\\Anaconda3\\envs\\Python27\\lib\\site-packages\\numpy\\core\\include', '-IC:\\ProgramData\\Anaconda3\\envs\\Python27\\include', '-IC:\\ProgramData\\Anaconda3\\envs\\Python27\\PC', '-c', 'C:\\ProgramData\\Anaconda3\\envs\\Python27\\lib\\site-packages\\weave\\scxx\\weave_imp.cpp', '-o', 'c:\\users\\krzysz~1.faj\\appdata\\local\\temp\\1\\weave-krzysztof.fajst-iaqybo\\python27_intermediate\\compiler_e3b0c44298fc1c149afbf4c8996fb924\\Release\\programdata\\anaconda3\\envs\\python27\\lib\\site-packages\\weave\\scxx\\weave_imp.o'],)exec_command(['g++', '-g', '-DDEBUG', '-DMS_WIN64', '-O0', '-Wall', '-D__MSVCRT_VERSION__=0x1500', '-IC:\\ProgramData\\Anaconda3\\envs\\Python27\\lib\\site-packages\\weave', '-IC:\\ProgramData\\Anaconda3\\envs\\Python27\\lib\\site-packages\\weave\\scxx', '-IC:\\ProgramData\\Anaconda3\\envs\\Python27\\lib\\site-packages\\numpy\\core\\include', '-IC:\\ProgramData\\Anaconda3\\envs\\Python27\\include', '-IC:\\ProgramData\\Anaconda3\\envs\\Python27\\PC', '-c', 'c:\\users\\krzysz~1.faj\\appdata\\local\\temp\\1\\krzysztof.fajst\\python27_compiled\\m1\\sc_173243115fe8831dd7db82e9d5b3f1520.cpp', '-o', 'c:\\users\\krzysz~1.faj\\appdata\\local\\temp\\1\\weave-krzysztof.fajst-iaqybo\\python27_intermediate\\compiler_e3b0c44298fc1c149afbf4c8996fb924\\Release\\users\\krzysz~1.faj\\appdata\\local\\temp\\1\\krzysztof.fajst\\python27_compiled\\m1\\sc_173243115fe8831dd7db82e9d5b3f1520.o'],)

Retaining cwd: c:\users\krzysz~1.faj\appdata\local\temp\1\krzysztof.fajst\python27_compiled\m1Retaining cwd: c:\users\krzysz~1.faj\appdata\local\temp\1\krzysztof.fajst\python27_compiled\m1

_preserve_environment([])_preserve_environment([])

_update_environment(...)
_update_environment(...)
_update_environment(...)
_update_environment(...)
g++ -g -shared c:\users\krzysz~1.faj\appdata\local\temp\1\weave-krzysztof.fajst-iaqybo\python27_intermediate\compiler_e3b0c44298fc1c149afbf4c8996fb924\Release\users\krzysz~1.faj\appdata\local\temp\1\krzysztof.fajst\python27_compiled\m1\sc_173243115fe8831dd7db82e9d5b3f1520.o c:\users\krzysz~1.faj\appdata\local\temp\1\weave-krzysztof.fajst-iaqybo\python27_intermediate\compiler_e3b0c44298fc1c149afbf4c8996fb924\Release\programdata\anaconda3\envs\python27\lib\site-packages\weave\scxx\weave_imp.o -LC:\ProgramData\Anaconda3\envs\Python27\libs -LC:\ProgramData\Anaconda3\envs\Python27\PCbuild\amd64 -LC:\ProgramData\Anaconda3\envs\Python27\PC\VS9.0\amd64 -lpython27 -lmsvcr90 -o c:\users\krzysz~1.faj\appdata\local\temp\1\krzysztof.fajst\python27_compiled\m1\sc_173243115fe8831dd7db82e9d5b3f1520.pyd
exec_command(['g++', '-g', '-shared', 'c:\\users\\krzysz~1.faj\\appdata\\local\\temp\\1\\weave-krzysztof.fajst-iaqybo\\python27_intermediate\\compiler_e3b0c44298fc1c149afbf4c8996fb924\\Release\\users\\krzysz~1.faj\\appdata\\local\\temp\\1\\krzysztof.fajst\\python27_compiled\\m1\\sc_173243115fe8831dd7db82e9d5b3f1520.o', 'c:\\users\\krzysz~1.faj\\appdata\\local\\temp\\1\\weave-krzysztof.fajst-iaqybo\\python27_intermediate\\compiler_e3b0c44298fc1c149afbf4c8996fb924\\Release\\programdata\\anaconda3\\envs\\python27\\lib\\site-packages\\weave\\scxx\\weave_imp.o', '-LC:\\ProgramData\\Anaconda3\\envs\\Python27\\libs', '-LC:\\ProgramData\\Anaconda3\\envs\\Python27\\PCbuild\\amd64', '-LC:\\ProgramData\\Anaconda3\\envs\\Python27\\PC\\VS9.0\\amd64', '-lpython27', '-lmsvcr90', '-o', 'c:\\users\\krzysz~1.faj\\appdata\\local\\temp\\1\\krzysztof.fajst\\python27_compiled\\m1\\sc_173243115fe8831dd7db82e9d5b3f1520.pyd'],)
Retaining cwd: c:\users\krzysz~1.faj\appdata\local\temp\1\krzysztof.fajst\python27_compiled\m1
_preserve_environment([])
_update_environment(...)
_update_environment(...)
E...............................................................................................
======================================================================
ERROR: test_5point_avg_2d_complex_double (test_blitz_tools.TestBlitz)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "C:\ProgramData\Anaconda3\envs\Python27\lib\site-packages\weave\tests\test_blitz_tools.py", line 147, in test_5point_avg_2d_complex_double
    self.generic_2d(expr,complex128)
  File "C:\ProgramData\Anaconda3\envs\Python27\lib\site-packages\weave\tests\test_blitz_tools.py", line 94, in generic_2d
    standard,compiled = self.generic_check(expr,arg_dict,type,size)
  File "C:\ProgramData\Anaconda3\envs\Python27\lib\site-packages\weave\tests\test_blitz_tools.py", line 67, in generic_check
    blitz_tools.blitz(expr,arg_dict,{},verbose=0)
  File "C:\ProgramData\Anaconda3\envs\Python27\lib\site-packages\weave\blitz_tools.py", line 68, in blitz
    **kw)
  File "C:\ProgramData\Anaconda3\envs\Python27\lib\site-packages\weave\inline_tools.py", line 502, in compile_function
    exec('import ' + module_name)
  File "<string>", line 1, in <module>
ImportError: DLL load failed: %1 is not a valid Win32 application.

======================================================================
ERROR: test_5point_avg_2d_double (test_blitz_tools.TestBlitz)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "C:\ProgramData\Anaconda3\envs\Python27\lib\site-packages\weave\tests\test_blitz_tools.py", line 121, in test_5point_avg_2d_double
    self.generic_2d(expr,float64)
  File "C:\ProgramData\Anaconda3\envs\Python27\lib\site-packages\weave\tests\test_blitz_tools.py", line 94, in generic_2d
    standard,compiled = self.generic_check(expr,arg_dict,type,size)
  File "C:\ProgramData\Anaconda3\envs\Python27\lib\site-packages\weave\tests\test_blitz_tools.py", line 67, in generic_check
    blitz_tools.blitz(expr,arg_dict,{},verbose=0)
  File "C:\ProgramData\Anaconda3\envs\Python27\lib\site-packages\weave\blitz_tools.py", line 68, in blitz
    **kw)
  File "C:\ProgramData\Anaconda3\envs\Python27\lib\site-packages\weave\inline_tools.py", line 502, in compile_function
    exec('import ' + module_name)
  File "<string>", line 1, in <module>
ImportError: DLL load failed: %1 is not a valid Win32 application.


@rgommers rgommers added the bug label Feb 21, 2019
@rgommers
Copy link
Member

Possibly due to a recent change in Anaconda, but I'm not sure - could be that this never worked. Looks like your GCC is not the Anaconda-shipped one, which will be problematic.

Note that weave is end of life, so this is unlikely to get fixed.

@rgommers
Copy link
Member

@Krzysiaczek99 Anaconda just reverted a change to how DLL loading works. Can you try if conda update python fixes this issue for you?

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

No branches or pull requests

2 participants