TheoreticalEcology / s-jSDM

Scalable joint species distribution modeling
https://cran.r-project.org/web/packages/sjSDM/index.html
GNU General Public License v3.0
68 stars 14 forks source link

Dependencies not found for windows #81

Closed Zinco-Li closed 2 years ago

Zinco-Li commented 2 years ago

I tried to install automatically by "install_sjSDM(version = c("cpu"))", such error arose: The following packages are not available from current channels:

Then I tried to install manually in cmd, but it seemed like that: library(sjSDM) √ torch x torch_optimizer x pyro x madgrad

MaximilianPi commented 2 years ago

Hi @Zinco-Li,

it seems that the installation fails again

for a hot fix, do:

1) restart RStudio 2) reticulate::conda_remove('r-reticulate') 3) reticulate::conda_create('r-reticulate', python_version='3.8') 4) reticulate::conda_install('r-reticulate',packages = c("pytorch", "torchvision", "torchaudio" ,"-c", "pytorch")) 5) reticulate::conda_install('r-reticulate',packages = c("pyro-ppl", "torch_optimizer", "madgrad"), pip=TRUE)