Comments (7)
Guys, I could figure out what the problem is. I normally use VS code for writing R scripts, but if I want to install/update packages I usually do this in the R console (this tiny GUI that comes with R for Mac). It seems this caused all my problems. When I use the standard terminal and start R, RcppParallel::defaultNumThreads()
works absolutely fine and I also could install Quanteda from source without problems.
So, this is kind of weird, but using the R console can't be recommended...
Thanks a lot for your efforts!
from quanteda.
Did you update Rcpp and RcppParallel?
from quanteda.
Did you update Rcpp and RcppParallel?
Yes. All packages are up to date.
from quanteda.
I use the same platform (macOS, M1 Max) and it installs fine. Could you include the output of sessionInfo()
?
from quanteda.
I use the same platform (macOS, M1 Max) and it installs fine. Could you include the output of
sessionInfo()
?
That is my setting:
> sessionInfo()
R version 4.3.1 (2023-06-16)
Platform: aarch64-apple-darwin20 (64-bit)
Running under: macOS Sonoma 14.1.1
Matrix products: default
BLAS: /Library/Frameworks/R.framework/Versions/4.3-arm64/Resources/lib/libRblas.0.dylib
LAPACK: /Library/Frameworks/R.framework/Versions/4.3-arm64/Resources/lib/libRlapack.dylib; LAPACK version 3.11.0
locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8
time zone: Europe/Berlin
tzcode source: internal
attached base packages:
[1] stats graphics grDevices utils datasets methods base
loaded via a namespace (and not attached):
[1] compiler_4.3.1
from quanteda.
After a few hours of further investigation I could collect some more details, that might be interesting. First, when I use CRAN to install Quanteda, the segfault issue during loading Quanteda is directly linked to the RcppParallel package. The RcppParallel::defaultNumThreads()
method itself produces the segfault, even though I set the number of threads before. Here is what I tested:
> library("RcppParallel")
> setThreadOptions(numThreads=4)
> defaultNumThreads()
*** caught segfault ***
address 0x245, cause 'invalid permissions'
RcppParallel is up to date and I also tried to reinstall it from source. However, the issue with defaultNumThreads()
couldn't be fixed by reinstalling.
Second, if I try to install different versions of Quanteda from source, I always get the 'non-zero exit code' message. Although I can install Quanteda 3.3.1 from CRAN without problems, building the same version of Quanteda from source
> require(devtools)
> Sys.setenv("R_REMOTES_NO_ERRORS_FROM_WARNINGS" = "true")
> remotes::install_github("quanteda/quanteda", ref="v3_3")
fails with non-zero exit code.
Is it possible, that RcppParallel
is somehow the reason for both problems?
from quanteda.
That's strange! Might have to do with different environment variables. There are also sometimes differences on where packages get installed, and I remember an issue where some were in system directories and some in user directories - and I even had two versions (one in each place) depending on how I'd installed them. I changed this by fixing my .libPaths() setting to a single installation folder. And by checking them using View(installed.packages())
.
from quanteda.
Related Issues (20)
- tbb::parallel_for crash
- Changes to generics and UseMethod in R development version breaking tokens generic
- NOTE created by clean script not removing Makevars.win
- Create safe pattern converter
- Install failure Fedora 39 g++ 13.2.1 quanteda 4.0.0; configure.ac error HOT 11
- TBB requirements need updating
- Homebrew installation of TBB still not found on macOS when compiling HOT 1
- quanteda cannot be updated HOT 1
- configure script could use tidying up HOT 1
- "randomly" failing test-fcm HOT 2
- Remove links to quanteda.textstats
- rolling stylometry HOT 2
- Quanteda build_tokens error when using rsplit from collapse package HOT 2
- Inconsistent results of corpus_reshape(to="sentences") HOT 1
- Consider passing ... to print
- Make tokens_substitute() to replace characters in tokens?
- Add more explicit information on enabling parallelization in quanteda >v4.0.0 HOT 1
- Experiencing problem with textmodel_mlp
- Add apply_if to tokens_ngrams()
- Error in parallel computing HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from quanteda.