![](/img/trans.png)
[英]R keras package: Python module tensorflow.contrib.keras.python.keras was not found
[英]Inform the R package keras of the correct location of Python
我在R 3.3.3 Windows 64位中安裝了keras
和TensorFlow:
devtools::install_github("rstudio/keras")
library(keras)
install_tensorflow()
它沒有問過我Python的位置。 Python的正確位置在我的PATH
和PYTHONPATH
作為D:/Python35/
。
但是當我去使用像keras
功能時
model <- keras_model_sequential()
它會拋出錯誤消息,說它無法找到DLL並將AppData中的路徑提供給Anaconda Python的舊的已刪除副本。
py_initialize出錯(config $ python,config $ libpython,config $ pythonhome,:
C:/Users/hackr/AppData/Local/CONTIN〜1/ANACON〜1/python35.dll - 找不到指定的過程。
如何告訴它使用正確的Python安裝?
這是很好的描述在這里
您可以使用:
library(reticulate)
use_python("D:/Python35/")
而設置RETICULATE_PYTHON
環境變量到D:/Python35
。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.