Can't install xaringan in ubuntu 20.04 within Github Actions [closed] - r

Closed. This question is not reproducible or was caused by typos. It is not currently accepting answers.
This question was caused by a typo or a problem that can no longer be reproduced. While similar questions may be on-topic here, this one was resolved in a way less likely to help future readers.
Closed 1 year ago.
Improve this question
I'm trying to use Github Actions to build a Xaringan presentation.
But it seems that it can't find xaringan.
Other dependencies are installed correctly, even xaringanthemer (see logs link below) !
I tried to see if there is some missing dependencies but even after fiwing that, xaringan is still missing.
Infos
Env: Github Actions
OS: Ubuntu 20.04
R: 4.1.0
REPO_NAME: "https://packagemanager.rstudio.com/all/__linux__/focal/latest"
Config file: https://github.com/gflowiz/article_foss4g2021/blob/presentation_FOSS4G2021/.github/workflows/render-xaringan.yaml
How to reproduce:
clone repo and trigger build
Ideas of possible fix
Signal to Rstudio and wait for a fix ?
That's strange because Xaringan seems to be present on the repo: https://packagemanager.rstudio.com/client/#/repos/1/packages/xaringan
Change repo
Can I change to CRAN instead of packagemanager.rstudio.com ? What's the URL to use ?
Other packages seems to be downloaded from https://cloud.r-project.org/src/contrib

Your issue came from the spelling: you are using xarigan instead of xaringan in your workflow file at line 48
Therefore, when you try installing the package, you got:
In your last workflow run.
Here is a workflow run using the correct syntax
, but it seems to return another error related to a .gitignore file missing after generating the FOSS4G2021_presentation.html output file:
I'll let you handle it from here (as I've never used these tools before) :D

Related

Rstudio won't interpret latex/RMarkDown

I've had a functioning RStudio setup for a while, on a Manjaro machine.
But suddenly it seems to no longer to able to interpret latex code. (Or is this an RMarkdown issue?). When I try to Knitr a pdf, I now get the following error message in the 'render' window:
You may need to add $ $ around a certain inline R expression r in Labb2New.Rmd (see the above hint). See https://github.com/rstudio/rmarkdown/issues/385 for more info.
Error: LaTeX failed to compile Labb2New.tex. See https://yihui.org/tinytex/r/#debugging for debugging tips. See Labb2New.log for more info.
Execution halted
What could be the issue here?
I've done no installation or updates (that I'm aware of) since Rstudio last worked.
There's tons of ways that you can compile Latex inside RMarkdown in RStudio, it can be confusing... so personally I did this:
Be sure to install everything in ONE SINGLE USER and not in the system, it could cause directory conflict and MiKtex somehow doesn't work for the whole systems, i read other comments where they can't solve that problem, me neither xD.
You should have all this requirements
R (you already installed it)
RStudio
MikTex
TeX Live
Install from CRAN
install.extras(repos = "http://cran.us.r-project.org")
THEN
## Install from CRAN
install.packages('rmarkdown')
Everything should work, you should have enough space memory to do this though. I just had this exact same problem yesterday so i reviewed my history x3
anyway if you have other problem with this process please feel free to tell me, be sure to read the documentations for what I listed there's lots of requirements inside, so probably is that!

Using the GPU backend in h2o.xgboost in a rocker based Docker container [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 4 years ago.
Improve this question
I've been trying to get GPU support to work for xgboost via h2o in a rocker docker container with little success. Progress so far: GitHub, Docker Hub
I have installed CUDA + nvidia-docker on the host machine and CUDA (9.0 - 9.2) in the container. I'm running the container with the following,
nvidia-docker run -d -p 8787:8787 -e USER=tidyverse-gpu -e PASSWORD=tidyverse-gpu --name tidyverse-gpu seabbs/tidyverse-gpu
Base Xgboost works with GPU support in both R and Python (and nvidia-smi returns usage stats etc when run inside the container). When the GPU backend is enabled in h2o.xgboost the following error is returned.
Illegal argument(s) for XGBoost model: XGBoost_model_R_1548450637489_3. Details: ERRR on field: _backend: GPU backend (gpu_id: 0) is not functional. Check CUDA_PATH and/or GPU installation.
Initially I had not added the CUDA_PATH in the Dockerfile but testing adding this has had no effect.
Sys.getenv("CUDA_PATH")
[1] "/usr/local/cuda"
The h2o startup logs show no issue with the xgboost module (that I can see). I've tried rolling back to CUDA 8.0 but this errors in the latest rocker containers as the gcc version being used is not supported by xgboost.
Any help would be much appreciated as I don't have a clue :)

Is it possible to find all the executables with the same name? [closed]

Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 5 years ago.
Improve this question
What I'm doing I'm writing a CMakeLists.txt to build a C++ project that will need to use R.
what is my problem Usually, when I would like to find a package/program, I would use find_package/program function. But this only finds the first one in the path. What if I want to find all the executables with the same name?
For example, if somebody has multiple versions of R installed on the computer, can I find them all and return a list? An alternative can be that is there a way to detect if there are multiple R executables installed?
Thank you!
As #Tsyvarev has answered there is not build-in way in cmake, but you can always do this within a loop.
So here is my cross-platform version of the missing find_program_all() CMake function:
CMakeLists.txt
cmake_minimum_required(VERSION 3.3)
project(TestFindProgramAll NONE)
function(find_program_all _var)
if (NOT DEFINED ${_var})
while(1)
unset(_found CACHE)
find_program(_found ${ARGN})
if (_found AND NOT _found IN_LIST ${_var})
set(${_var} "${${_var}};${_found}" CACHE FILEPATH "Path to a program." FORCE)
# ignore with the next try
get_filename_component(_dir "${_found}" DIRECTORY)
list(APPEND CMAKE_IGNORE_PATH "${_dir}")
else()
unset(_found CACHE)
break()
endif()
endwhile()
endif()
endfunction()
find_program_all(_gcc "gcc")
message(STATUS "_gcc = ${_gcc}")
It mimics the find_program() behavior and caches the result.
Tested it with my multiple gcc installations.
References
CMAKE_IGNORE_PATH
Environment variable used by CMake to detect Visual C++ compiler tools for Ninja
CMake has no ready-to-use functionality to return list of matched programs.
You may iterate over search paths manually, or use other utilities, like which -a suggested by #BenBolker in the comments.

Install previous versions of R on ubuntu [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 9 years ago.
Improve this question
I am wanting to use RHadoop packages(rmr, rhdfs, rhbase) on my ubuntu server. These only work with the older version of R 2.15.0 and not on the current 3.0.1 version. I have created a mirror which allowed me to install the 3.0.1 version.
sudo apt-get install r-base-dev
What do I need to change here to get the 2.15.0 version of R?
I have tried using the links but i think I might need to access a new mirror since the link to both downloads are different.
current mirror:
deb http://cran.cnr.berkeley.edu/bin/linux/ubuntu precise/
I assume its getting the most recent file and executing it:
http: //cran.cnr.berkeley.edu/bin/linux/ubuntu/precise/r-base-dev_3.0.1-5precise0_all.deb
The link I want it to follow and install
http: //cran.cnr.berkeley.edu/src/base/R-2/R-2.15.0.tar.gz
After berkeley.edu it is all different but in my mirror it would stay the same. I have tried changing my mirror but haven't had any luck.
If anyone has any suggestions or can lead me down the right path that would greatly help.
-Joey
You will find previous binary builds for Ubuntu in the standard directory, just by hand:
https://cran.r-project.org/bin/linux/ubuntu/
You can always download them manually and then tell the package management system to put them 'on hold', ie to not upgrade. See eg man dpkg for the dpkg --set-selection and the hold state.
You find outdated versions of R at the CRAN page:
http://cran.r-project.org/sources.html
Following a couple of links:
http://cran.r-project.org/src/base/R-2/R-2.15.0.tar.gz
I suppose it is possible that that Debian/Ubuntu repository has the Make files to drive the compilation from source. If not, you can probably find one on the R-Debian mailing list.

/usr/share/zoneinfo epic fail [closed]

Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 11 years ago.
Improve this question
I have just, in my groggy morning state, reversed & confused the arguments to ln, replacing /usr/share/zoneinfo/America/Toronto with a link to the non-existant /etc/localtime, when I really wanted to link /etc/localtime to Toronto. Now I have no timezone file for where I live. Does anybody have a copy or know where I could get one? It's just instructions on how to translate unix time into toronto time, but I cat'd a few of the other files, and they don't seem like something I'm up to the task of writing by hand.
I know. At least I've never rm -r'd my /
edit:
Before anybody asks, I just tried sudo dpkg-reconfigure tzdata, gleefully entered "America" then "Toronto", only to crash and read, cp: cannot stat '/usr/share/zoneinfo/America/Toronto': no such file or directory. ARGH.
apt-get install --reinstall tzdata
Depending on which GNU/Linux distro you're using, you may be able to just re-download the whole of the tzdata package using its package manager. I know ArchLinux has a package for the time zone data and so does Debian.
However, you can also manually download the whole package and extract the time zone file that you want.
http://www.246tnt.com/files/Toronto

Resources