bnosac / ruimtehol

R package to Embed All the Things! using StarSpace
Mozilla Public License 2.0
99 stars 13 forks source link

R CMD check FAIL on r-devel windows #39

Open jwijffels opened 1 year ago

jwijffels commented 1 year ago

Windows with gcc 12.2 (Rtools43), so in R-devel (to become R 4.3)

using R Under development (unstable) (2023-01-04 r83561 ucrt)
using platform: x86_64-w64-mingw32 (64-bit)
R was compiled by
    gcc.exe (GCC) 12.2.0
    GNU Fortran (GCC) 12.2.0
running under: Windows Server x64 (build 20348)
using session charset: UTF-8
checking for file 'ruimtehol/DESCRIPTION' ... OK
checking extension type ... Package
this is package 'ruimtehol' version '0.3'
package encoding: UTF-8
checking package namespace information ... OK
checking package dependencies ... OK
checking if this is a source package ... OK
checking if there is a namespace ... OK
checking for hidden files and directories ... OK
checking for portable file names ... OK
checking whether package 'ruimtehol' can be installed ... OK
used C++ compiler: 'g++.exe (GCC) 12.2.0'
checking installed package size ... NOTE
  installed size is 5.7Mb
  sub-directories of 1Mb or more:
    data 3.8Mb
    libs 1.4Mb
checking package directory ... OK
checking 'build' directory ... OK
checking DESCRIPTION meta-information ... OK
checking top-level files ... OK
checking for left-over files ... OK
checking index information ... OK
checking package subdirectories ... OK
checking R files for non-ASCII characters ... OK
checking R files for syntax errors ... OK
checking whether the package can be loaded ... [1s] OK
checking whether the package can be loaded with stated dependencies ... [1s] OK
checking whether the package can be unloaded cleanly ... [1s] OK
checking whether the namespace can be loaded with stated dependencies ... [1s] OK
checking whether the namespace can be unloaded cleanly ... [1s] OK
checking loading without being on the library search path ... [1s] OK
checking use of S3 registration ... OK
checking dependencies in R code ... OK
checking S3 generic/method consistency ... OK
checking replacement functions ... OK
checking foreign function calls ... OK
checking R code for possible problems ... [5s] OK
checking Rd files ... [1s] OK
checking Rd metadata ... OK
checking Rd cross-references ... OK
checking for missing documentation entries ... OK
checking for code/documentation mismatches ... OK
checking Rd \usage sections ... OK
checking Rd contents ... OK
checking for unstated dependencies in examples ... OK
checking contents of 'data' directory ... OK
checking data for non-ASCII characters ... [1s] OK
checking LazyData ... OK
checking data for ASCII and uncompressed saves ... OK
checking line endings in C/C++/Fortran sources/headers ... OK
checking line endings in Makefiles ... OK
checking compilation flags in Makevars ... OK
checking for GNU extensions in Makefiles ... OK
checking for portable use of $(BLAS_LIBS) and $(LAPACK_LIBS) ... OK
checking use of PKG_*FLAGS in Makefiles ... OK
checking include directives in Makefiles ... OK
checking pragmas in C/C++ headers and code ... OK
checking compiled code ... OK
checking sizes of PDF files under 'inst/doc' ... OK
checking installed files from 'inst/doc' ... OK
checking files in 'vignettes' ... OK
checking examples ...
Check process probably crashed or hung up for 20 minutes ... killed
Most likely this happened in the example checks (?),
if not, ignore the following last lines of example output:
>
> ## Don't show:
> if(require(udpipe)){
+ ## End(Don't show)
+ library(udpipe)
+ data(brussels_reviews_anno, package = "udpipe")
+ x <- subset(brussels_reviews_anno, language == "nl")
+ x$token <- x$lemma
+ x <- x[, c("doc_id", "sentence_id", "token")]
+ set.seed(123456789)
+ model <- embed_articlespace(x, early_stopping = 1,
+ dim = 25, epoch = 25, minCount = 2,
+ negSearchLimit = 1, maxNegSamples = 2)
+ plot(model)
+ sentences <- c("ook de keuken zijn zeer goed uitgerust .",
+ "het appartement zijn met veel smaak inrichten en zeer proper .")
+ predict(model, sentences, type = "embedding")
+ starspace_embedding(model, sentences)
+ ## Don't show:
+ } # End of main if statement running only if the required packages are installed
Loading required package: udpipe
Start to initialize starspace model.
Build dict from input file : D:\temp\RtmpCmjMu3\textspace_2a4984ad938f4.txt

Read 0M words
Number of words in dictionary: 1273
Number of labels in dictionary: 0
Loading data from file : D:\temp\RtmpCmjMu3\textspace_2a4984ad938f4.txt
Total number of examples loaded : 470
2023-01-05 12:58:12 Initialising with learning rate 0.01
======== End of example output (where/before crash/hang up occured ?) ========
jwijffels commented 1 year ago

We can just truncate instead of in a different thread, in the main thread So this https://github.com/bnosac/ruimtehol/blob/master/src/Starspace/src/model.cpp#L377-L383 would be

doneTraining = true;
normThread();