我尝试在Heroku中使用Tensorflow部署我的AI应用程序。我得到错误,如Failed to load the native Tensor Flow runtime
。Django webapplication无法加载本地TensorFlow运行时。在Heroku
在此先感谢。
我尝试在Heroku中使用Tensorflow部署我的AI应用程序。我得到错误,如Failed to load the native Tensor Flow runtime
。Django webapplication无法加载本地TensorFlow运行时。在Heroku
在此先感谢。
还有ImportError:PyUnicodeUCS4_FromString根据堆栈跟踪。
当您安装了多个版本的Python时会发生这种情况,您可能正在使用与编译该模块的解释器不同的解释器运行编译后的模块。
Python可以使用UCS2或UCS4的内部Unicode表示形式构建。
Newly created Python applications on Heroku default uses the Python 3.6.2 runtime.
You can specify an arbitrary version of Python to be used to run your application. read docs python-runtimes heroku devcenter
它不止于此。它不是Python版本,但通常是由Python 2.7版本的Python二进制文件构建的,该版本在安装时定义了不同的Unicode字符集宽度,而不是目标Python 2.7使用的版本。您可以在http://blog.dscpl.com.au/2015/06/installing-custom-python-version-into.html –
的“Unicode字符集”一节中看到有关此问题的讨论。奇怪的是,由于UCS4通常用于Linux,因此这表明正在使用的Python 2.7安装已针对UCS2进行了配置。如果Heroku提供UCS2编译的Python,这与Linux发行版的典型做法背道而驰。假设在PyPi上的二进制Linux轮子将全部是UCS4,如果它们有问题会导致很多问题。 –
@GrahamDumpleton您可以编辑我的答案并添加这些信息。可能会有帮助。 – Satendra