Closed sbrunk closed 6 years ago
@sbrunk Sorry about that. It's because I'm using the master
branch of TensorFlow, rather than the 1.3 release. I'll push a big set of changes soon (probably some time tomorrow) that add support for control flow ops (i.e., cond
and whileLoop
) and fix lots of the current issues. I'm sorry for the inconvenience and the small delay.
@sbrunk Could you please try again with the master branch? You can obtain the libtensorflow.so
and libtensorflow_framework.so
libraries by downloading extracting this jar file.
It finds the libraries but now I get the following error:
[info] [ 4%] Building CXX object CMakeFiles/tensorflow_ops.dir/ops/jvm_callback_op.cc.o
[info] /Library/Developer/CommandLineTools/usr/bin/c++ -Dtensorflow_ops_EXPORTS -I/Users/brunksn/repos/extern/tensorflow_scala/jni/src/main/native/. -I/Users/brunksn/repos/extern/tensorflow_scala/jni/src/main/native/./generated -I/Users/brunksn/repos/extern/tensorflow_scala/jni/src/main/native/./include -I/Users/brunksn/repos/extern/tensorflow_scala/jni/src/main/native/./ops -I/System/Library/Frameworks/JavaVM.framework/Headers -D_GLIBCXX_USE_CXX11_ABI=0 -O3 -DNDEBUG -fPIC -std=gnu++11 -o CMakeFiles/tensorflow_ops.dir/ops/jvm_callback_op.cc.o -c /Users/brunksn/repos/extern/tensorflow_scala/jni/src/main/native/ops/jvm_callback_op.cc
[error] /Users/brunksn/repos/extern/tensorflow_scala/jni/src/main/native/ops/jvm_callback_op.cc:188:53: error: use of undeclared identifier 'JNI_VERSION_1_8'
[error] int jvmEnvStatus = jvm_->GetEnv((void **) &env, JNI_VERSION_1_8);
[error] ^
[error] /Users/brunksn/repos/extern/tensorflow_scala/jni/src/main/native/ops/jvm_callback_op.cc:207:52: error: use of undeclared identifier 'JNI_VERSION_1_8'
[error] int jvmEnvStatus = jvm_->GetEnv((void**) &env, JNI_VERSION_1_8);
[error] ^
[error] 2 errors generated.
[error] make[2]: *** [CMakeFiles/tensorflow_ops.dir/ops/jvm_callback_op.cc.o] Error 1
[error] make[1]: *** [CMakeFiles/tensorflow_ops.dir/all] Error 2
[error] make: *** [all] Error 2
@sbrunk That's because the library required a newer version of JNI than the one you have. I pushed a small change that removes that requirement. Can you please check that it compiles fine now?
Working fine now :) Thanks for your help!
I’m happy to hear that! Please, let me know if you find any other issues. :)
On Oct 14, 2017, 4:17 PM -0400, Sören Brunk notifications@github.com, wrote:
Working fine now :) Thanks for your help! — You are receiving this because you commented. Reply to this email directly, view it on GitHub, or mute the thread.
@eaplatanios where do I find libtensorflow.so and libtensorflow_framework.so on my ubuntu?
@jS5t3r Have a look at the installation docs.
The easy way is to get the libraries is to download this jar (cpu / gpu) from sonatype and extract it. That's actually what happens automatically when you add the tensorflow dependency with the right classifier.
The other way, also decribed in the documentation, is to check out the tensorflow master branch and compile it yourself.
Just one suggestion: The gitter channel might be a better place to ask that kind of question instead of adding them to a closed issue. ;)
I finally had the time to have a look at your library again and I see you've made a lot of progress in the meantime!
I'm having a problem getting it to work on a new machine running OSX. I have installed libtensorflow 1.3.1 via homebrew. Now I'm getting the following error:
I'm a bit at a loss about where tensorflow_framework is supposed to come from. Any ideas what I'm missing?