Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Crashing R #9

Open
ashgreat opened this issue Aug 2, 2020 · 3 comments
Open

Crashing R #9

ashgreat opened this issue Aug 2, 2020 · 3 comments

Comments

@ashgreat
Copy link

ashgreat commented Aug 2, 2020

I am unable to execute the example you provide as the package crashes my R session immediately. I can't generate a reprex to reproduce this issue because R session is aborted.

This is my session info:

R version 4.0.0 (2020-04-24)
Platform: x86_64-apple-darwin17.0 (64-bit)
Running under: macOS Catalina 10.15.6

Matrix products: default
BLAS:   /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib
LAPACK: /Library/Frameworks/R.framework/Versions/4.0/Resources/lib/libRlapack.dylib

locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8

This is a MacBook Pro with the following configuration:

Processor - 3.9 GHz 6-Core Intel Core i9
Memory - 32 GB 2400 MHz DDR4

@jwijffels
Copy link
Contributor

If you want help, you don't need to provide a reprex, just run R code from the R console, not RStudio and provide the output.

@ashgreat
Copy link
Author

ashgreat commented Aug 3, 2020

There is no output because R crashes immediately. It doesn't matter whether it's run from R console or from RStudio.

I am running this code:

library(golgotha)
model <- transformer("bert-base-multilingual-uncased")
x <- data.frame(doc_id = c("doc_1", "doc_2"),
                text = c("give me back my money or i'll call the police.",
                         "talk to the hand because the face don't want to hear it any more."),
                stringsAsFactors = FALSE)

embedding <- predict(model, x, type = "embed-sentence")

The last line leads to immediate crashing. I captured the crash in this video. As you can see, there is literally nothing after it crashes R. MacOS generated a long log after that. I can share it if you need it.

Crash video:

https://youtu.be/balOg525ye8

@jwijffels
Copy link
Contributor

Package has only been tested on Windows & Linux, I don't have a Mac.
It's unclear where the crash is coming from. Probably from the reticulate package.
Why don't you provide the debug trace of a call to gdb with the R code that you just provided. That will show where the error is coming from.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants