[Rcpp-devel] Rcpp-modules trouble on windows

Dmitriy Selivanov selivanov.dmitriy at gmail.com
Tue Oct 27 21:24:59 CET 2015


Finally I caught this issue. My bad - I used `.property` instead of
`.method` in RCPP_MODULE macro for function call (forgot to adjust it when
changed underlying c++ code).

2015-10-22 11:01 GMT+03:00 Dmitriy Selivanov <selivanov.dmitriy at gmail.com>:

> Hi, mailing list!
> I have issue  with  Rcpp modules on *windows only* (don't have any
> problems on linux and osx ). Don't really sure, whether it rcpp-modules
> related. Problem is following - when I try to get class to global
> environment - R crashes (actually freezes - cpu core load 100% and nothing
> happens).
> I'm developing package for text analysis and vectorization - text2vec
> <https://github.com/dselivanov/text2vec>. Here, for example, I have two
> classes
> <https://github.com/dselivanov/text2vec/blob/master/src/Corpus.cpp#L343-L366>,
> which I expose using Rcc-modules. Very similar to RcppAnnoy (I used it as
> example for rcpp-modules).
> Now consider following example
> <https://gist.github.com/dselivanov/ffb535ab1447956bb10f>:
> ```R
> library(devtools)
> library(magrittr)
> install_github("dselivanov/text2vec")
> data("movie_review")
> # this works fine:
> dtm <- create_dict_corpus(src = movie_review[['review']][1:100],
>                    preprocess_fun = tolower,
>                    tokenizer = regexp_tokenizer,
>                    batch_size = 100,
>                    progress = F) %>%
>   get_dtm(corpus = corp, type = "dgCMatrix")
> dim(dtm)
> #but this crashes:
> corp <- create_dict_corpus(src = movie_review[['review']][1:100],
>                    preprocess_fun = tolower,
>                    tokenizer = regexp_tokenizer,
>                    batch_size = 100,
>                    progress = F)
> str(corp)
> ```
>
> Any thoughts?
>
> --
> Regards
> Dmitriy Selivanov
>



-- 
Regards
Dmitriy Selivanov
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.r-forge.r-project.org/pipermail/rcpp-devel/attachments/20151027/f816d9e5/attachment.html>


More information about the Rcpp-devel mailing list