fo40225 / tensorflow-windows-wheel

Tensorflow prebuilt binary for Windows
3.66k stars 1.53k forks source link

why there dont have libtensorflow-cpu-windows-x86_32-1.8.0-avx2.7z? just have libtensorflow-cpu-windows-x86_64-1.8.0-avx2.7z #145

Closed JaosonMa closed 4 years ago

JaosonMa commented 4 years ago

i want use tf .dll in c++ vs, i can run succ with libtensorflow-cpu-windows-x86_64-1.8.0-avx2.7z, but it is x64, my project is x86 , so i want use it in x86 project ? can you complie the libtensorflow-cpu-windows-x86_32-1.8.0-avx2.7z ? 我的工程师32位的,所以64位的没办法使用,可以编译一个 avx2的32位 dll吗?

我用 了 32位的 libtensorflow-cpu-windows-x86_32-1.8.0-sse2,但是 提示报错Your CPU supports instructions that this TensorFlow binary was not compiled to use:AVX AVX2

image

JaosonMa commented 4 years ago

@fo40225 can you help me with this problem? or tell me how to complie this , i can try to complie myself . or can you tell me how to slove the sse2 error ,

fo40225 commented 4 years ago

Your CPU supports instructions that this TensorFlow binary was not compiled to use: AVX AVX2 is an information message, not error.

JaosonMa commented 4 years ago

Your CPU supports instructions that this TensorFlow binary was not compiled to use: AVX AVX2 is an information message, not error.

c++ code https://github.com/zhangcliff/tensorflow-c-mnist/blob/master/tf.cpp i google this , it is not error, but with the debug ,it can not run succ, debug result: image

release resoult: image

i can not debug the code with debug , how can i slove this ? does it have the code like python

import os.

os.environ["TF_CPP_MIN_LOG_LEVEL"] = '2'

to jump this waring ,to run succ with debug? and i also wander will it be faster then sse2 if i can use the avx2 ,

fo40225 commented 4 years ago

The libtensorflow is release build.

I have never successfully built a debug version.

You can use _putenv_s to set environment variables.

JaosonMa commented 4 years ago

The libtensorflow is release build.

I have never successfully built a debug version.

You can use _putenv_s to set environment variables.

i got what you mean,but i dont know the environment var's name , i google this but nothing was helpful, do you know ? and can you tell me will you comlile libtensorflow-cpu-windows-x86_32-1.8.0-avx2.7z , best wishes to you !

fo40225 commented 4 years ago

TF_CPP_MIN_LOG_LEVEL is the environment variable's name.

Just use sse2 for maximum compatibility.

JaosonMa commented 4 years ago

TF_CPP_MIN_LOG_LEVEL

1、i got the log level image 2、add int res = _putenv("TF_CPP_MIN_LOG_LEVEL=3") nothing changed. it always error in image image

fo40225 commented 4 years ago

I can't confirm if https://github.com/zhangcliff/tensorflow-c-mnist/blob/master/tf.cpp compatible with tf 1.8.

You can try this https://github.com/tensorflow/tensorflow/blob/v1.8.0/tensorflow/cc/tutorials/example_trainer.cc

JaosonMa commented 4 years ago

I can't confirm if https://github.com/zhangcliff/tensorflow-c-mnist/blob/master/tf.cpp compatible with tf 1.8.

You can try this https://github.com/tensorflow/tensorflow/blob/v1.8.0/tensorflow/cc/tutorials/example_trainer.cc

i will try it, thanks a lot! c++ cpu use tensorflow is not a good choice!!!