Hi Andy, I think I have done this on the base project? Here is what I have done:
#install.packages("remotes")
setwd("/cloud/project")
reticulate::install_miniconda("miniconda")
Sys.setenv(WORKON_HOME = "virtualenvs")
reticulate::virtualenv_create("r-reticulate", python = "miniconda/bin/python")
keras::install_keras(
method = "virtualenv",
conda = "miniconda/bin/conda",
envname = "r-reticulate",
tensorflow = "1.13.1",
restart_session = FALSE
)
line <- "WORKON_HOME=/cloud/project/virtualenvs"
writeLines(line, ".Renviron")
rstudioapi::restartSession()
Opening a new project does then include the above file structure and files, but when I run both of these commands and check for python availability FALSE
is returned.
reticulate::use_virtualenv("r-reticulate")
reticulate::py_available()
reticulate::use_python(python = "miniconda/bin/python")
reticulate::py_available()
This is the space URL if that helps
https://rstudio.cloud/spaces/212980/project/3520381