Closed bytesByHarsh closed 5 years ago
did you forget to activate your miniconda environment and run ctest from there? You also need to run the initial cmake and build from your activated your miniconda environment otherwise it will not build the ell_py.pyd python module. If you did not run cmake from your miniconda environment you will need to delete your build folder and start over. cmake won't be able to change your build from non-python to python.
I had activated the miniconda environment and also the initial cmake and build were run.
Oh, one more thing, you need to make sure openblas is in your PATH environment, assuming you have a haswell CPU try this:
set PATH=%PATH%;E:\git\ELL\external\OpenBLASLibs.0.2.19.3\build\native\x64\haswell\bin;
For more info see "Path Environment" section of INSTALL-Windows.md
Yes I had done this also. And also included this path in PATH variable in properties of computer->advance settings->Environment Variables and then adding this address in PATH variable
can you show me the results of "dir E:\Git\ELL\build\interfaces\python\package\ell\release" ? You should see an _ell_py.pyd module there, and if you run the http://www.dependencywalker.com/ on this module you might find what is missing (ignore the errors reported about anything named API-MS-WIN-*, but if you see anything else missing then that will be it. I find the "View/Collapse All" option is handy. This is what I see on my machine:
Also I am using Intel(R) Core(TM) i5-8300H CPU @2.3GHz .
Interesting. I wonder then if you have a CPU that our OpenBlas doesn't support... Do you see output like this from cmake?
-- Processor family: 6, model: 58 -- Using OpenBLAS compiled for sandybridge -- Using BLAS include path: D:/git/ELL/ELL/external/OpenBLASLibs.0.2.19.3/build/native/x64/sandybridge/include -- Using BLAS library: D:/git/ELL/ELL/external/OpenBLASLibs.0.2.19.3/build/native/x64/sandybridge/lib/libopenblas.dll.a -- Using BLAS DLLs: libopenblas.dll;libgcc_s_seh-1.dll;libgfortran-3.dll;libquadmath-0.dll
When I run "cmake ." Following is a part of message that is shown
-- Processor family: 6, model: 158 -- Using OpenBLAS compiled for haswell -- Using BLAS include path: E:/Git/ELL/external/OpenBLASLibs.0.2.19.3/build/native/x64/haswell/include -- Using BLAS library: E:/Git/ELL/external/OpenBLASLibs.0.2.19.3/build/native/x64/haswell/lib/libopenblas.dll.a -- Using BLAS DLLs: libopenblas.dll;libgcc_s_seh-1.dll;libgfortran-3.dll;libquadmath-0.dll -- Found LLVM 6.0.1 -- Using LLVMConfig.cmake in: E:/Git/ELL/external/LLVMNativeWindowsLibs.x64.6.0.1/llvm-6.0/lib/cmake/llvm
Ok great, so OpenBlas should work, and depends.exe is finding your OpenBlas so all should be good. I also noticed you reported error "ModuleNotFoundError: No module named 'numpy'" -- so did you install OpenCV in your python environment? Installing OpenCV should also bring in numpy...
Yes opencv was installed it. I tried installing numpy using pip it showed that numpy was already installed, so it tried
conda install -c conda-forge numpy
still no use, same error is showing.
Just like I said earlier if type following in cmd line no error is shown:
python import numpy as np
I am able import numpy that means numpy is installed but while running the test it is showing this error
Sorry I missed your earlier comment about being able to import numpy, this is now really weird. You can import numpy, so why can't ell. Can you try this:
cd E:\Git\ELL\build\interfaces\python\package
python
import ell
If this fails with the same error then I may need to ask you to debug into this using VS code.
import ell
Traceback (most recent call last):
File "E:\Git\ELL\build\interfaces\python\package\ell\ell_py.py", line 14, in swig_import_helper
return importlib.import_module(mname)
File "C:\Users\harsh\Miniconda3\envs\py36\lib\importlib__init__.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "
Ah this is a clue:
ImportError: Module use of python37.dll conflicts with this version of Python.
it is odd this is mentioning python37 when your environment is "C:\Users\harsh\Miniconda3\envs\py36". Did you do a system wide install of python37? Perhaps it is finding that instead of your python36...
What do you get from "where python" ?
It is returning:
C:\Users\harsh\Miniconda3\python.exe C:\Users\harsh\AppData\Local\Programs\Python\Python36\python.exe
Oh yes Python 3.7.1 is installed in my system
<DIR>python
Python 3.7.1 (default, Dec 10 2018, 22:54:23) [MSC v.1915 64 bit (AMD64)] :: Anaconda, Inc. on win32
Type "help", "copyright", "credits" or "license" for more information.
After activating py36:
(py36) E:\Git\ELL\build\interfaces\python\package>python
Python 3.6.8 |Anaconda, Inc.| (default, Dec 30 2018, 18:50:55) [MSC v.1915 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
so "C:\Users\harsh\Miniconda3\python.exe" is a python 3.7 then eh? Can you remove C:\Users\harsh\Miniconda3\ from your PATH environment, and activate py36, and run the ELL rebuild.cmd ? I suspect something in there got confused about the presence of python 3.7 in your PATH...
After removing it from the path, following error message is shown after "import ell"
Traceback (most recent call last):
File "
Assuming "depends.exe" is still happy with _ell_py.pyd, this error is the one that normally means a DLL cannot be found, in debugging "import ell" in vs code if you break on all exceptions you might get more information.
So I deleted the build folder and started again and with response to my PR #189 changes have been made for the ctest command for windows as well and now 100% tests are passed. Still really not sure what caused the problem in the first place but now the problem is solved
Thanks for the help @lovettchris
Cool, thanks for the update.
Hi, I'm sorry for reopening this thread again but I'm having the exact same issue than harshmittal2210 but in Linux 18.04. Everything is point by point exactly the same as in the description he does of the problem. Have you released any solution for the ctests similar as you did for the windows version?
Thanks,
Jesus
While running
I am getting error
For detailed error I addded -VV in above commnd
Got the following error:
The below error is received which I am not able to understand that why it is coming as numpy is already installed in miniconda and I am able to import numpy as np normally in same cmd window after running python in it.