Open ShuvenduRoy opened 7 years ago
Windows ... I'm not sure... I havnet tried. There are a few parts:
I think everything else should be fine. Do you want to try, see how far you can get, report any issues that arise? You'll probably need to fix the issues yourself, but I might be able to give some pointers, possibly.
Edit:
Sticky progress update, using msvc 2015, on branch winbuild of coriander, doc at https://github.com/hughperkins/coriander/blob/winbuild/doc/installation_windows_inprogress.md:
cocl
libraryir-to-opencl
toolpatch-hostside
toolcocl
script etc, from bash to pythonoh wait, this is the tensorflow repository. Hmmm... well... I think the first thing would be to try to get coriander working first, ie https://github.com/hughperkins/coriander . Once we have coriander working, we can think about tensorflow itself. How does that sound?
(seems like tensorflow itself supports windows , https://www.tensorflow.org/install/install_windows , so as long as coriander works ok on windows, we should stand a chance that tf-coriander
works too)
I don't really know how to build tf-coriander on windows either...
Step 1: download clew, https://github.com/hughperkins/clew check that does/doesn't build, report any issues here.
On 8 June 2017 06:49:19 BST, Eldath notifications@github.com wrote:
I don't really know how to build tf-coriander on windows either...
-- You are receiving this because you commented. Reply to this email directly or view it on GitHub: https://github.com/hughperkins/tf-coriander/issues/38#issuecomment-307005340
-- Sent from my Android device with K-9 Mail. Please excuse my brevity.
Yeah, I build clew successfully. clewTest
returned num platforms: 1
that looks like a normal return.
What should I do next ?
Cool :-) . Next would be to try the next level up:
https://github.com/hughperkins/EasyCL
(EasyCL uses clew, under the hood)
Still build successfully, and gpuinfo
return correct devices info.
Next ?
cool :-) . Next one will be harder :P :
https://github.com/hughperkins/coriander
No-one has built this on Windows yet, as far as I know. You are entering uncharted territory :-)
Finally, it generated cocl
and cocl_wrapped
file in dist
and when I execute it in Cygwin it return:
Eldath@DESKTOP-RB6STNM ~ $ /cygdrive/f/Code/Research/coriander-master/dist/bin/cocl_wrapped
cocl args:
Usage: /cygdrive/f/Code/Research/coriander-master/dist/bin/cocl_wrapped [-c] [-g] [[-Iincludepath]...] [-o outfile] [infile.cu]
I don't know this means build successfully or not ;-)
You're saying, the cmake
and build bit finished successfully? (I know cocl
wont run yet, but I'm quite pleasantly surprised if the cmake
and build bit finished.
How are you building by the way? cygwin? mingsys? visual studio? something else?
oh, cygdrive
:-)
Hmmmm
Well, then there's a good chance many things will work as-is. You can test by doing things like:
git pull
make tests
make run-cuda_sample
edit: or simply:
../bin/cocl ../test/cocl/cuda_sample.cu
./cuda_sample
The cmake
works fine. It returns
Configuring done
Generating done
And when I build the project with cmake -DBUILD_TYPE=Release -P cmake_install.cmake
(after solve a lot of problems) then it noticed me
CMake Error at cmake_install.cmake:202 (file):
file INSTALL cannot find
"F:/Code/Research/coriander-master/build/Release/cocl.dll".
All right I'll test it first.
cocl
is a linux bash file so I only can run this in WSL...
but console return an error:
./cocl: line 373: /usr/lib/llvm-3.6/bin/clang++: No such file or directory
How to fix ? And wether run in WSL is equals to run in Windows ?
make install
d /usr/local/bin/cocl
, this is just a wrapper that sets CLANG_HOME
, then calls /usr/local/bin/cocl_wrapped
(or similar)../bin/cocl
directly, you need to define CLANG_HOME=wherever/llvm-4.0/is
cmake
, you can define CLANG_HOME
inside the ccmake
curses uiIn your case, you probably need to set CLANG_HOME
to point to wherever llvm-4.0
directory is, and you probably need to download this first.
(Just in case it's useful, I created a Dockerfile, https://github.com/hughperkins/tf-coriander/blob/master/docker/Dockerfile It wont be useful for running of course, since wont be able to use opencl, but does show a full download, build, for ubuntu 16.04. might be helpful-ish? )
I run command in Windows PowerShell manual but when I execute
bazel build ${LOCALRESOURCES} ${BUILDTYPE} @grpc//:grpc_cpp_plugin
bazel build ${LOCALRESOURCES} ${BUILDTYPE} @protobuf//:protoc
it returns:
ERROR: no such package '@grpc//': The repository could not be resolved.
INFO: Elapsed time: 0.739s
and:
ERROR: no such package '@protobuf//': The repository could not be resolved.
INFO: Elapsed time: 0.850s
How to solve this? ;-|
Thats a bazel issue. How sure are you coriander is working first? I mean, fixing coriander won't fix this bug. But I'd rather go bit by bit. Can you run all the tests included with coriander, and provide the results please?
On 9 June 2017 07:47:11 BST, Eldath notifications@github.com wrote:
I run command in Windows PowerShell manual but when I execute
bazel build ${LOCALRESOURCES} ${BUILDTYPE} @grpc//:grpc_cpp_plugin bazel build ${LOCALRESOURCES} ${BUILDTYPE} @protobuf//:protoc
it returns:
ERROR: no such package '@grpc//': The repository could not be resolved. INFO: Elapsed time: 0.739s
and:
ERROR: no such package '@protobuf//': The repository could not be resolved. INFO: Elapsed time: 0.850s
How to solve this? ;-|
-- You are receiving this because you commented. Reply to this email directly or view it on GitHub: https://github.com/hughperkins/tf-coriander/issues/38#issuecomment-307309862
-- Sent from my Android device with K-9 Mail. Please excuse my brevity.
Hi @hughperkins Does https://github.com/hughperkins/clew must need VS2010 on windows? Is there any lighter substituter ?
@eromoe Should build on anything I would think. Might need -std=c++
, but some base c++ might be sufficient actually. [edit: actually, c99 is probably sufficient, dont think it uses c++ at all actually]
That's probably true for EasyCL too. [edit: well, easycl uses c++, probably c++98 is sufficient though, no need for -std=c++11
Coriander needs -std=c++11
. So msvc2010 is not sufficinet. You probably need msvc2015, if you're giong to go msvc route. Otherwise, you could use cygwin or msys, if you prefer, plausibly.
What compiler do you normally prefer to use? Or, do you mean, you'd prefer to have pre-built Windows binaries?
Actually, I am not familiar with c++. I know cygwin ad msys are something linux emulators. But they looks lighter than msvc2015 , so I may prefer to. But I wonder , are the building steps as same as ubuntu if I choose cygwin or msys? I just hope it is not so complex.
PS: The building enviroment usually make me headache. There are many different settings or dependencies on each platfom/env . I always admire your guys who can write the right config and steps . What I know is just follow the installation guide, once got error directly game over and cry for help. Do you have any suggesttion for my situation?
Looks like there are commandline tools available, dont need full ide, http://landinghub.visualstudio.com/visual-cpp-build-tools
Note: Coriadne build on Windows is in progress on branch 'winbuild', of Coriander, https://github.com/hughperkins/coriander/tree/winbuild
Update:
Hmmm, as far as which compiler to use when building application source-code...
Seems like the clang++
, from http://releases.llvm.org/download.html#4.0.0 can at least build cuda_sample.cu into NVIDIA® CUDA™ bytecode, using msvc 2015 headers:
Warnings are ok, compile errors would be less good.
Coriander binaries are building ok now, on Windows 64-bit, using msvc2015.
Next step is to modify the bash script at https://github.com/hughperkins/coriander/blob/master/bin/cocl , to be a python script.
Update: on the winbuild
branch, there is a new command available cocl_py
, instead of cocl
, which uses python, instead of bash, so should be portable, cross-platform. The endtoend
coriander tests pass using this. The eigen tests fail for some reason. I'm not going to look into why just now, but some simple comparison of the options being fed to clang++
in one with those fed to clang++
by the other should be sufficient to fix that. I think I'm going to take a braek from the Windows thing for a while, and look at eg thrust instead, so please feel free to pick up the reins on this for a bit :-)
(Edit: by the way, this commit reverts from using cocl_py
as the default, back to cocl
, so I can merge to master-ish. To set it to default, once it's fully working on eigne tests, just do the reverse of what is in this commit basically)
(finally I have merged winbuild
branch onto master, with the cocl
script now marked as deprecated, and cocl_py
the preferred entrypoint)
This issue is about 3 months old, so I am not going to read each comment, but is tf-coriander working on Windows yet? Thanks!
It was briefly working somewhat, but I havent been checking it continues working on Windows, so it might need a bit of love to get it working again plausibly.
@hughperkins Is it pretty easy to get working, or does it require quite a bit of tweaking?
The latter.
@hughperkins Do you think you could write a small tutorial, or is it too complicated?
@hughperkins I'm getting an error on step 14 of installing coriander. In CMake I am getting this error:
CMake Error at test/CMakeLists.txt:22 (cocl_add_executable): Unknown CMake command "cocl_add_executable". Call Stack (most recent call first): CMakeLists.txt:294 (include)
Hi ! I would like to know if anyone as compile this on Windows ? :)
I'm using python 27 and vs2015 as installed by npm install --global windows-build-tools
. Just because I already had these already. Compiled LLVM with cmake 3.10.3 without issues by command line
cmake-gui ...
msbuild LLVM.sln
msbuild INSTALL.vcxproj # as admin
On step 14 I'm getting:
CMake Error at test/eigen/CMakeLists.txt:37 (include):
include could not find load file:
/coriander/lib/coriander_plugins/corianderclblast-targets.cmake
Tried to install that plugin first to no avail. I think my issue is that I can't really understand what to put as CMAKE_INSTALL_PREFIX
which defaults to /coriander
.
Any clues?
Update: tried to disable test building. Now configure and generate worked fine but I've got compile issues - https://paste.fedoraproject.org/paste/OVkJvgstvqUPoHeLsQ-GMw . Here is short version for when pastebin expires:
Build FAILED.
"C:\Users\pesho\Downloads\repos\coriander\build\cocl.vcxproj" (default target) (1) ->
"C:\Users\pesho\Downloads\repos\coriander\build\easycl.vcxproj" (default target) (4) ->
(ClCompile target) ->
c:\users\pesho\downloads\repos\coriander\src\easycl\util/easycl_stringhelper.h(22): warning C4091: '__declspec(dllexp
ort)': ignored on left of 'easycl::IHasToString' when no variable is declared [C:\Users\pesho\Downloads\repos\coriander
\build\easycl.vcxproj]
c:\users\pesho\downloads\repos\coriander\src\easycl\util/easycl_stringhelper.h(22): warning C4091: '__declspec(dllexp
ort)': ignored on left of 'easycl::IHasToString' when no variable is declared [C:\Users\pesho\Downloads\repos\coriander
\build\easycl.vcxproj]
c:\users\pesho\downloads\repos\coriander\src\easycl\util/easycl_stringhelper.h(22): warning C4091: '__declspec(dllexp
ort)': ignored on left of 'easycl::IHasToString' when no variable is declared [C:\Users\pesho\Downloads\repos\coriander
\build\easycl.vcxproj]
C:\Users\pesho\Downloads\repos\coriander\src\EasyCL\util/easycl_stringhelper.h(22): warning C4091: '__declspec(dllexp
ort)': ignored on left of 'easycl::IHasToString' when no variable is declared [C:\Users\pesho\Downloads\repos\coriander
\build\easycl.vcxproj]
"C:\Users\pesho\Downloads\repos\coriander\build\cocl.vcxproj" (default target) (1) ->
"C:\Users\pesho\Downloads\repos\coriander\build\easycl.vcxproj" (default target) (4) ->
(ClCompile target) ->
C:\Users\pesho\Downloads\repos\coriander\src\EasyCL\CLKernel.cpp(366): error C2131: expression did not evaluate to a
constant [C:\Users\pesho\Downloads\repos\coriander\build\easycl.vcxproj]
C:\Users\pesho\Downloads\repos\coriander\src\EasyCL\CLKernel.cpp(372): error C2664: 'cl_int (cl_event)': cannot conve
rt argument 1 from 'cl_event [numOutputBuffers]' to 'cl_event' [C:\Users\pesho\Downloads\repos\coriander\build\easycl.v
cxproj]
4 Warning(s)
2 Error(s)
P.S. I see in hughperkins/coriander#62 that somebody had some success on windows.
I have Radoen Rx 470 gpu install on windows 10. Do i have any option for running tensorflow on this gpu