Skip to content

Commit

Permalink
#115 more irlba avoidance
Browse files Browse the repository at this point in the history
  • Loading branch information
jlmelville committed Apr 20, 2024
1 parent af96d1d commit f6e639a
Showing 1 changed file with 9 additions and 5 deletions.
14 changes: 9 additions & 5 deletions tests/testthat/test_output.R
Original file line number Diff line number Diff line change
Expand Up @@ -309,11 +309,15 @@ res <- umap(iris10,
expect_ok_matrix(res, nc = 1)

# enforce irlba for spectral initialization even if RSpectra is present
res <- umap(iris10,
n_components = 1, n_neighbors = 4, n_epochs = 2,
n_threads = 1, verbose = FALSE, init = "irlba_spectral"
)
expect_ok_matrix(res, nc = 1)
# 115: ensure irlba code path gets tested if we can avoid Matrix ABI issue
if (exists("Matrix.Version", envir = asNamespace("Matrix")) &&
Matrix::Matrix.Version()$package >= "1.6.3") {
res <- umap(iris10,
n_components = 1, n_neighbors = 4, n_epochs = 2,
n_threads = 1, verbose = FALSE, init = "irlba_spectral"
)
expect_ok_matrix(res, nc = 1)
}

# Supervised
set.seed(1337)
Expand Down

0 comments on commit f6e639a

Please sign in to comment.