I installed the tensorflow R package, then ran install_tensorflow(method = "conda")
.
I set the TENSORFLOW_PYTHON environmental variable in my .Rprofile.
When I start R in the terminal I am able to library(tensorflow)
and proceed normally.
When I try to load tensorflow in rstudio, I am unable to execute any other commands that depend on reticulate (e.g. py_config). The session always crashes.
I was formerly able to run tensorflow in rstudio with R version 3.5
output of py_discover_config
is identical in both R terminal and rstudio:
python: /opt/miniconda3/envs/r-tensorflow/bin/python
libpython: /opt/miniconda3/envs/r-tensorflow/lib/libpython3.7m.so
pythonhome: /opt/miniconda3/envs/r-tensorflow:/opt/miniconda3/envs/r-tensorflow
version: 3.7.3 | packaged by conda-forge | (default, Mar 27 2019, 23:01:00) [GCC 7.3.0]
numpy: /opt/miniconda3/envs/r-tensorflow/lib/python3.7/site-packages/numpy
numpy_version: 1.16.3
NOTE: Python version was forced by RETICULATE_PYTHON
output of py_config()
in R terminal:
python: /opt/miniconda3/envs/r-tensorflow/bin/python
libpython: /opt/miniconda3/envs/r-tensorflow/lib/libpython3.7m.so
pythonhome: /opt/miniconda3/envs/r-tensorflow:/opt/miniconda3/envs/r-tensorflow
version: 3.7.3 | packaged by conda-forge | (default, Mar 27 2019, 23:01:00) [GCC 7.3.0]
numpy: /opt/miniconda3/envs/r-tensorflow/lib/python3.7/site-packages/numpy
numpy_version: 1.16.3
tensorflow: /opt/miniconda3/envs/r-tensorflow/lib/python3.7/site-packages/tensorflow
NOTE: Python version was forced by RETICULATE_PYTHON