* using log directory ‘/Users/ripley/R/packages/tests-Accelerate/spacesXYZ.Rcheck’ * using R Under development (unstable) (2023-09-17 r85158) * using platform: aarch64-apple-darwin22.6.0 * R was compiled by Apple clang version 15.0.0 (clang-1500.0.40.1) GNU Fortran (GCC) 12.2.0 * running under: macOS Ventura 13.5.2 * using session charset: UTF-8 * using option ‘--no-stop-on-test-error’ * checking for file ‘spacesXYZ/DESCRIPTION’ ... OK * checking extension type ... Package * this is package ‘spacesXYZ’ version ‘1.2-1’ * package encoding: UTF-8 * checking package namespace information ... NOTE Found export directive that requires package ‘methods’: ‘exportClasses’ Remove all such namespace directives (if obsolete) or ensure that the DESCRIPTION Depends or Imports field contains ‘methods’. * 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 ‘spacesXYZ’ can be installed ... OK * checking installed package size ... OK * 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 ... 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 whether startup messages can be suppressed ... 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 ... OK * checking Rd files ... 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 ... OK * checking LazyData ... OK * checking data for ASCII and uncompressed saves ... OK * checking R/sysdata.rda ... OK * checking sizes of PDF files under ‘inst/doc’ ... OK * checking installed files from ‘inst/doc’ ... OK * checking files in ‘vignettes’ ... OK * checking examples ... OK * checking for unstated dependencies in ‘tests’ ... OK * checking tests ... Running ‘test-CCT.R’ Running ‘test-DeltaE.R’ Running ‘test-adaptations.R’ Running ‘test-conversions.R’ ERROR Running the tests in ‘tests/test-adaptations.R’ failed. Complete output: > > > library( spacesXYZ ) > > options( width=144 ) > > printf <- function( msg, ... ) + { + mess = sprintf( msg[1], ... ) # should this really be msg[1] ? + cat( mess, '\n' ) #, file=stderr() ) + } > > > testFundamental <- function() + { + printf( "\n--------------------- testFundamental() -----------------------" ) + + C = standardXYZ( 'C' ) + D65 = standardXYZ( 'D65' ) + + # xyY_D65 = xyYfromXYZ( D65 ) + + for( method in c( "Bradford", "VonKries", "MCAT02", "Bianco", "scaling" ) ) + { + CtoD65 = CAT( C, D65, method=method ) + + xyY_gray = xyYfromXYZ( adaptXYZ(CtoD65,C) ) + + delta = max( abs(adaptXYZ(CtoD65,C) - D65) ) + + printf( "method='%s'. delta=%g", method, delta ) + + if( 5.e-16 < delta ) + { + printf( "Adaptation accuracy failed for method='%s'. delta=%g", method, delta ) + return(FALSE) + } + } + + return( TRUE ) + } > > > > testSymmetry <- function() + { + printf( "\n--------------------- testSymmetry() -----------------------" ) + + I3 = diag(3) + + for( method in c( "Bradford", "VonKries", "MCAT02", "Bianco", "scaling" ) ) + { + AtoB = CAT( 'A', 'B', method=method ) + + BtoA = CAT( 'B', 'A', method=method ) + + # the product of the Ms must be I + delta = max( abs(AtoB$M %*% BtoA$M - I3) ) # print(delta) + + printf( "method='%s'. delta=%g", method, delta ) + + if( 5.e-15 < delta ) + { + printf( "Adaptation symmetry failed for method='%s'. delta=%g", method, delta ) + return(FALSE) + } + } + + return( TRUE ) + } > > > testCommutativity <- function() + { + printf( "\n--------------- testCommutativity() -----------------------" ) + + for( method in c( "Bradford", "VonKries", "MCAT02", "Bianco", "scaling" ) ) + { + AtoB = CAT( 'A', 'B', method=method ) + + BtoC = CAT( 'B', 'C', method=method ) + + AtoC = CAT( 'A', 'C', method=method ) + + # compare matrix product + delta = max( abs(BtoC$M %*% AtoB$M - AtoC$M) ) + + printf( "method='%s'. delta=%g", method, delta ) + + if( 5.e-15 < delta ) + { + printf( "Adaptation commutativity failed for method='%s'. delta=%g", method, delta ) + return(FALSE) + } + } + + return( TRUE ) + } > > > > if( ! testFundamental() ) stop( "testFundamental() failed !", call.=FALSE ) --------------------- testFundamental() ----------------------- method='Bradford'. delta=2.22045e-16 method='VonKries'. delta=5.55112e-16 Adaptation accuracy failed for method='VonKries'. delta=5.55112e-16 Error: testFundamental() failed ! Execution halted * checking for unstated dependencies in vignettes ... OK * checking package vignettes in ‘inst/doc’ ... OK * checking re-building of vignette outputs ... OK * checking PDF version of manual ... OK * checking HTML version of manual ... OK * checking for detritus in the temp directory ... OK * DONE Status: 1 ERROR, 1 NOTE See ‘/Users/ripley/R/packages/tests-Accelerate/spacesXYZ.Rcheck/00check.log’ for details. 17.77 real 13.86 user 3.26 sys