Giter Club home page Giter Club logo

Comments (15)

hnmn avatar hnmn commented on May 22, 2024 2

hi there
cannot load pbdZMQ
Error : .onLoad failed in loadNamespace() for 'pbdZMQ', details: call: fun(libname, pkgname) error: Could not load /data/data/com.termux/files/usr/lib/R/library/pbdZMQ/libs/libzmq.so : Error in dyn.load(dn.file, local = FALSE) : unable to load shared object '/data/data/com.termux/files/usr/lib/R/library/pbdZMQ/libs/libzmq.so': dlopen failed: cannot locate symbol "R_registerRoutines" referenced by "/data/data/com.termux/files/usr/lib/R/library/pbdZMQ/libs/libzmq.so"... ERROR: lazy loading failed for package ‘IRkernel’ removing ‘/data/data/com.termux/files/usr/lib/R/library/IRkernel

from gcc_termux.

namdnguyen avatar namdnguyen commented on May 22, 2024 1

Hi @yoshimoncho, It is possible to install IRkernel. I wish I had made notes about the process, so maybe if you could try to install it and let us know what errors you are running into. I'll list some of the steps that I do remember, many of which had errors installing dependencies that had to be resolved. The steps come from the IRkernel installation instructions (https://github.com/IRkernel/IRkernel), but have comments about changes I had to make.

  1. Install devtools in R: install.packages('devtools')
  2. I couldn't get the recommended step of using devtools::install_github to work, so I had to download IRkernel and installed locally. Download the zip of IRkernel from the master branch or the latest release, such as IRkernel-0.8.11.zip.
  3. Run devtools::install_local('IRkernel-master.zip'), if the zip file is in your R working directory. Otherwise, include the path or start R from the same directory as the zip file. If you run into problems with the zip file, you can unzip and run devtools::install_local('IRkernel-master') for the path where you extracted the archive.
  4. Run IRkernel::installspec()

I was able to install the tidyverse packages, which I could load and use from a R Jupyter Notebook. Let me know if you get stuck!

from gcc_termux.

richgoldberg avatar richgoldberg commented on May 22, 2024 1

Also, if your R kernel dies because of missing X-11, check out this GitHub thread. The last recommendation to add option(bitmapType="cairo") to the kernel.json file fixed it for me.

from gcc_termux.

its-pointless avatar its-pointless commented on May 22, 2024 1

k got it working
may have to install Cairo in R and that needs env variables set
export CAIRO_LIBS="-lcairo"
export CAIRO_CFLAGS="-I$PREFIX/include/cairo"
then install Cairo in R
install.packages('Cairo')
then exit R and do this
cat > $PREFIX/share/jupyter/kernels/opt-r-3.5.0/kernel.json <<EOF
{
"argv": ["$PREFIX/lib/R/bin/R", "--slave", "-e", "options(bitmapType='cairo') ; IRkernel::main()", "--args", "{connection_file}"],
"display_name": "R 3.5.0",
"language": "R"
}
EOF

this should be enough to get it to work

from gcc_termux.

miferg avatar miferg commented on May 22, 2024 1

HI, I am unable install IRkernel because of this error when the install.packages function tries to load pbdZMQ:

.onLoad failed in loadNamespace() for 'pbdZMQ', details:
 call: fun(libname, pkgname)
 error: Could not load /data/data/com.termux/files/usr/lib/R/library/pbdZMQ/libs/libzmq.so : Error in dyn.load(dn.file, local = FALSE) :
 unable to load shared object '/data/data/com.termux/files/usr/lib/R/library/pbdZMQ/libs/libzmq.so':
 dlopen failed: cannot locate symbol "R_registerRoutines" referenced by "/data/data/com.termux/files/usr/lib/R/library/pbdZMQ/libs/libzmq.so"... 

from gcc_termux.

clancia avatar clancia commented on May 22, 2024

Hi there, I got stuck at point 3

> devtools::install_local('IRkernel-master')
Installing IRkernel
Installation failed: error in running command

DId you encounter the same error as well?

Thanks in advance!

from gcc_termux.

namdnguyen avatar namdnguyen commented on May 22, 2024

Hi @clancia. I may have gotten that as well. If I did, I don't recall how I fixed it. Let me find another device and try to install it again to see if there are any missing steps from the original set of instructions.

from gcc_termux.

clancia avatar clancia commented on May 22, 2024

from gcc_termux.

richgoldberg avatar richgoldberg commented on May 22, 2024

Before trying to install from GitHub using devtools, try setting R to use its internal unzip function:
options(unzip = "internal")

from gcc_termux.

clancia avatar clancia commented on May 22, 2024

from gcc_termux.

its-pointless avatar its-pointless commented on May 22, 2024

yes im getting the same thing
will have a look see if i cant get working
amusingly i have got julia working in jupyter-notebook.

from gcc_termux.

its-pointless avatar its-pointless commented on May 22, 2024

i guess i should do a bit of a tutorial about installing packages in julia as well at some point...

from gcc_termux.

ajrathod avatar ajrathod commented on May 22, 2024

IS there any way we can check the logs ? Above fix did not work for me.

devtools::install_local('IRkernel-IRkernel-97c492b')
Installing IRkernel
Installation failed: error in running command

I installed Cairo and also made changes to kernel.json but no luck. it simply fails with error with no logs..

from gcc_termux.

ferroao avatar ferroao commented on May 22, 2024

After installing successfully Cairo package (except for an Rconn "no") and IRkernel, I got this while using jupyter:

unable to load shared object '/data/data/com.termux/files/usr/lib/R/library/grDevices/libs///cairo.so':
dlopen failed: cannot locate symbol "jpeg_std_error" referenced by "<...>libs/cairo.so"...
In ok_device(filename,...) : failed to load cairo DLL.

Any ideas?

from gcc_termux.

YvesAD avatar YvesAD commented on May 22, 2024

I just ran into the same issue with "libcairo":

unable to load shared object '/data/data/com.termux/files/usr/lib/R/library/grDevices/libs///cairo.so':
dlopen failed: cannot locate symbol "jpeg_std_error" referenced by "<...>libs/cairo.so"...
In ok_device(filename,...) : failed to load cairo DLL.

After 2 days of loading libraries, recompiling etc, I installed the juniper kernel:
https://github.com/JuniperKernel/JuniperKernel

Just installed from CRAN as advised in the top of the READ ME.md :

install.packages("JuniperKernel")
library(JuniperKernel)
installJuniper(useJupyterDefault = TRUE) # install into default Jupyter kernel location

Works like a charm!
(Haven't tried anything fancy yet though, only "1+1". But the kernel doesn't die !)

from gcc_termux.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.