Problems with PATH variable when installing the GPU version of tensorflow - r

I am currently working on installing the gpu version of tensorflow onto my computer; however, I am experiencing several difficulties. My initial problem was a relatively common problem where Tensorflow was not able to find the CUDA libraries during installation, and I found a very useful post here on StackOverflow that mentioned that by changing the 'CUDA_PATH' environment variable on my computer and adding the 'bin' folder to said variable's path, Tensorflow should be able to find the CUDA libraries.
This didn't work for me, and so I changed the name of the environment variable 'CUDA_PATH' to simply be 'PATH', since that was the environment variable name that was shown on the post I followed.
It didn't work either so I changed it back. Now, everytime I open RStudio, the following error message appears:
Error in Sys.setenv(PATH = new_path) : wrong length for argument
In addition: Warning message:
In system2(conda, c("run", in_env, run_args, shQuote(cmd), args), :
running command '"C:/Users/maria/AppData/Local/r-miniconda/condabin/conda.bat" run --prefix "C:\Users\maria\AppData\Local\r-miniconda\envs\r-reticulate" --no-capture-output "python" -c "import os; print(os.environ['PATH'])"' had status 1
I have tried uninstalling R, Rtools, Rstudio, miniconda and all my Nvidia GPU drivers, as well as CUDA and CUDANN. I then have re-downloaded every programme, and the error still appears whenever I start a session in Rstudio (before I can even do anything remotely related to tensorflow or before I even use R in any way).
If anyone has any suggestions I would greatly appreciate some help with this issue.
Thanks :)
P.S.: Please find below a screenshot of my RStudio upon opening the programme.

Related

Trying to add IJulia via the REPL: Unsatisfiable requirements detected for package

I keep trying to add IJulia in the REPL, and I keep getting this error message:
I tried installing JSON directly, but the REPL would say "The following packages names could not be resolved".
If it helps, I'm running a Windows 10 laptop with julia 1.0.5
Is there a fix to this? Should I install an earlier version to julia?
Appreciate the time.
It seems like you have outdated registries locally.
The registries are ~/.julia/registries, message like The following package names could not be resolved usually suggests that registry are not updated or somehow corrupted.
Delete them (the directory ~/.julia/registries/General) and then adding packages should cause the General registry to be downloaded, the newest version. Then you should be able to add IJulia without problem.
More people encountered this problem with messed up registry, see https://discourse.julialang.org/t/registry-failed-to-update/17840/10

Cannot open rstudio from command line though installation worked

I can't start rstudio from my linux terminal. It always shows me this message:
Unable to determine real path of R script /home/remi/anaconda3/bin/R (system error 2 (No such file or directory))
I have Kubuntu 18 and anaconda installed on it.
I had trouble with installing curl and other libraries that need curl.
Since it was maybe due to a problem of paths, I removed R and RStudio from my conda environment in order to work only on the R and RStudio installed in Kubuntu. Something must have gone wrong.
I have tried to remove and reinstall both R and RStudio but it didn't work.
Weirdly, I can launch RStudio from my application launcher and I was able to install all the libraries I needed.
I would like to be able to launch RStudio from the terminal without any problem.
Does someone know what the problem is ?
Thank you !

Unable to install Swirl Courses in RStudio

I'm trying to install Swirl courses in RStudio on 64-bit Ubuntu 15.10, and I am running across an error. I tried to install a course using the command install_from_swirl("Data_Analysis"), but the system either just hangs (R needs to be interrupted to recover from this), or I get the following error:
Error in unzip(path, list = TRUE) :
zip file '/home/xxxxx/R/x86_64-pc-linux-gnu-library/3.2/swirl/Courses
/temp.zip' cannot be opened
The temp.zip doesn't appear to be a zip archive (I'm unable to open in on the command line).
You actually helped me with the command! I used
install_course("Data Analysis")
but it didn't work, then I used
install_from_swirl("Data_Analysis")
and it worked! Try running the swirl library first:
library("swirl")
install_from_swirl("Data_Analysis") # CASE SENSITIVE!
swirl()
I wish you luck!

Why does building an R package stop my code from working?

It seams that upon installing my custom R package code stops to work? Why?
In detail, I have a tiny R package goEnrichment (click to see the Github repo). The R package includes just just two functions and some binary data.
Also there are two test R-scripts that I run after installing the R package with R CMD INSTALL goEnrichment. One test script fails while the other works.
The only difference between the two scripts is that in the working version I require the necessary libraries and source the functions file manually, while in the other failing script I require my goEnrichment library directly.
Note, that both scripts are started directly from their directory goEnrichment/exec.
Start the working test with cd goEnrichment/exec && Rscript testGoEnrichment_works.R. Excerpt:
# This is the WORKING version
require(GOstats)
require(GSEABase)
require(RMySQL)
source( "../R/goEnrichment.R" )
Start the failing test script with cd goEnrichment/exec && Rscript testGoEnrichment_fail.R. Excerpt:
# This version FAILS
require(goEnrichment)
The error I get is somewhat uninformative to me:
'dimnames' applied to non-array.
The built R package fails on two platforms, that is on Debian Wheezy 64 with R 3.0.2 and on Mac OS X Yosemite with R 3.1.1.
I really have no clue why this happens. I checked for file format and unexpected characters using Vim. The cause does not seem to be the DESCRIPTION file either, because all libraries, goEnrichment depends on, are imported.
Does any one have a clue what causes this very weird error? Help will be much appreciated.
After much testing I found the source of the problem.
For some reason when requiring my package with
require(goEnrichment)
the generic function
summary.GOHyperGResult
is not loaded, as it should be. The method however is available when the packages, goEnrichment depends upon, are required manually. As to why this is, I had no time to investigate. I believe the here reported error is related to this bug.
Thanks to Tyler for your efforts, very much!

Error in fetch(key) : internal error -3 in R_decompress1

I have the following problem:
I have some development version of my package loaded in R session
I edited the source file.
I detach it and do:
system("R CMD check realizedvolatility")
system("R CMD build realizedvolatility")
system("R CMD install realizedvolatility_0.1.tar.gz")
library(realizedvolatility)
Until now, everything works. Now, if I try to bring up help file, for example ?realizedvolatility , the error
Error in fetch(key) : internal error -3 in R_decompress1
occurs.
The remedy is to restart entirely the R session, then everything works. Is there any way to make it work within one session? I tried detaching from namespace, installing with various options, nothing worked.
I am using Mac OS X Lion, and R 2.14.1
I asked the same question in R-help and one R core replied "this is by design" which means you cannot do anything about it except restarting R: https://stat.ethz.ch/pipermail/r-help/2011-July/283916.html (although I still do not understand why this design cannot refresh the cache database...)

Resources