Skip to content

Commit

Permalink
Insist on new Matrix version for irlba code paths
Browse files Browse the repository at this point in the history
  • Loading branch information
jlmelville committed May 15, 2024
1 parent d4c99fb commit 5b21d7d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion tests/testthat/test_normlaplacian.R
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ test_that("normalized laplacian", {

# 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") {
Matrix::Matrix.Version()$package >= "1.7.0") {
res <- irlba_tsvd_normalized_laplacian_init(sparse_m)
expect_equal(abs(res), abs_expected_norm_lap, tolerance = 0.2)

Expand Down
2 changes: 1 addition & 1 deletion tests/testthat/test_output.R
Original file line number Diff line number Diff line change
Expand Up @@ -311,7 +311,7 @@ expect_ok_matrix(res, nc = 1)
# enforce irlba for spectral initialization even if RSpectra is present
# 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") {
Matrix::Matrix.Version()$package >= "1.7.0") {
res <- umap(iris10,
n_components = 1, n_neighbors = 4, n_epochs = 2,
n_threads = 1, verbose = FALSE, init = "irlba_spectral"
Expand Down

0 comments on commit 5b21d7d

Please sign in to comment.