* using log directory ‘/data/blackswan/ripley/R/packages/tests-devel/resautonet.Rcheck’ * using R Under development (unstable) (2020-07-16 r78868) * using platform: x86_64-pc-linux-gnu (64-bit) * using session charset: UTF-8 * checking for file ‘resautonet/DESCRIPTION’ ... OK * checking extension type ... Package * this is package ‘resautonet’ version ‘1.0’ * 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 executable files ... OK * checking for hidden files and directories ... OK * checking for portable file names ... OK * checking for sufficient/correct file permissions ... OK * checking whether package ‘resautonet’ can be installed ... [24s/24s] OK * checking package 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 ... OK * checking whether the package can be loaded with stated dependencies ... OK * checking whether the package can be unloaded cleanly ... OK * checking whether the namespace can be loaded with stated dependencies ... OK * checking whether the namespace can be unloaded cleanly ... OK * checking loading without being on the library search path ... OK * checking dependencies in R code ... NOTE Namespace in Imports field not imported from: ‘dplyr’ All declared Imports should be used. * checking S3 generic/method consistency ... OK * checking replacement functions ... OK * checking foreign function calls ... OK * checking R code for possible problems ... OK * checking Rd files ... OK * checking Rd metadata ... OK * checking Rd line widths ... 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 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 use of SHLIB_OPENMP_*FLAGS in Makefiles ... OK * checking compilation flags used ... OK * checking compiled code ... OK * checking examples ... OK * checking examples with --run-donttest ... ERROR Running examples in ‘resautonet-Ex.R’ failed The error most likely occurred in: > ### Name: resautonet-package > ### Title: Autoencoder-based Residual Deep Network with Keras Support > ### Aliases: resautonet-package resautonet > ### Keywords: package > > ### ** Examples > > ## No test: > ###### Generate the data > #Sample size > library(dplyr) Attaching package: ‘dplyr’ The following objects are masked from ‘package:stats’: filter, lag The following objects are masked from ‘package:base’: intersect, setdiff, setequal, union > > n=4000 > #Number of features > nfea=4 > #Generate the dataset with normalization of the covariates > cmdStr="data.frame(" > for(i in c(1:nfea)){ + var=runif(n,runif(1,1,5),runif(1,100,200)) + varName=paste("x",i,sep="") + assign(varName,var) + cmdStr=paste(cmdStr,varName,"n=(",varName,"-mean(",varName,"))/sd(",varName,")",sep="") + if(i cmdStr=paste(cmdStr,")",sep="") > dataset=eval(expr=parse(text=cmdStr)) > y=sin(x1)+2*cos(x2)+x3^2+sqrt(x4)+rnorm(n) > #Normalization of y > yn=(y-mean(y))/sd(y) > #Obtain the index of training and test samples > prop=0.2 > test_index=sample(c(1:n),size=ceiling(n*prop)) > train_index=setdiff(c(1:n),test_index) > > #Obtain the training and test dataset > x_train=as.matrix(dataset[train_index,]) > y_train=as.vector(yn[train_index]) > > x_test=as.matrix(dataset[test_index,]) > y_test=as.vector(yn[test_index]) > > #Define the metric, r2 in keras > metric_r2= keras::custom_metric("rsquared", function(y_true, y_pred) { + SS_res =keras::k_sum(keras::k_square(y_true-y_pred )) + SS_tot =keras::k_sum(keras::k_square(( y_true - keras::k_mean(y_true)))) + return ( 1 - SS_res/(SS_tot + keras::k_epsilon())) + }) > > #Define the autoencoder-based deep network > nout=1;nodes=c(16,8,4,2);mdropout=0.2;isres=TRUE;outtype=0;fact="linear" > acts=rep("relu",length(nodes));fact="linear";reg=NULL;batchnorm=TRUE > autoresmodel=resautonet::AutoEncoderModel(nfea,nout,nodes, + acts,mdropout,reg,batchnorm,isres,outtype,fact=fact) Error: Installation of TensorFlow not found. Python environments searched for 'tensorflow' package: /usr/bin/python3.8 /usr/bin/python3.8 You can install TensorFlow using the install_tensorflow() function. Execution halted * checking PDF version of manual ... OK * checking for non-standard things in the check directory ... OK * checking for detritus in the temp directory ... OK * DONE Status: 1 ERROR, 1 NOTE See ‘/data/blackswan/ripley/R/packages/tests-devel/resautonet.Rcheck/00check.log’ for details. Command exited with non-zero status 1 Time 0:48.25, 44.31 + 8.48