Skip to content

Commit

Permalink
updated script
Browse files Browse the repository at this point in the history
  • Loading branch information
eweine committed Jan 4, 2024
1 parent 07983de commit ced5370
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 8 deletions.
7 changes: 3 additions & 4 deletions inst/experiments/fit_droplets_glmpca.R
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
command_args = commandArgs(trailingOnly = TRUE)
n_factor = as.integer(command_args[1])
n_iter = as.integer(command_args[2])

load("/project2/mstephens/pcarbo/git/fastTopics-experiments/data/droplet.RData")

Expand All @@ -20,8 +19,8 @@ fit <- glmpca::glmpca(
optimizer = optimizer,
minibatch = minibatch,
ctl = list(
minIter = n_iter - 1,
maxIter = n_iter,
minIter = 1e8 - 1,
maxIter = 1e8,
verbose = TRUE,
tol = .Machine$double.eps,
lr = 1e-4
Expand All @@ -34,5 +33,5 @@ fit <- glmpca::glmpca(

readr::write_rds(
fit,
glue::glue("droplets_glmpca_fit_{n_factor}_factors_{n_iter}_iter_avagrad_optimizer_minibatch_stochastic_dec_23.rds")
glue::glue("droplets_glmpca_fit_{n_factor}_factors_10_hrs_avagrad_optimizer_minibatch_stochastic_dec_23.rds")
)
7 changes: 3 additions & 4 deletions inst/experiments/fit_pbmc_glmpca.R
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
command_args = commandArgs(trailingOnly = TRUE)
n_factor = as.integer(command_args[1])
n_iter = as.integer(command_args[2])

load("/project2/mstephens/pcarbo/git/fastTopics-experiments/data/pbmc_68k.RData")

Expand All @@ -20,8 +19,8 @@ fit <- glmpca::glmpca(
optimizer = optimizer,
minibatch = minibatch,
ctl = list(
minIter = n_iter - 1,
maxIter = n_iter,
minIter = 1e8 - 1,
maxIter = 1e8,
verbose = TRUE,
tol = .Machine$double.eps,
lr = 1e-4
Expand All @@ -34,5 +33,5 @@ fit <- glmpca::glmpca(

readr::write_rds(
fit,
glue::glue("pbmc_glmpca_fit_{n_factor}_factors_{n_iter}_iter_avagrad_optimizer_minibatch_stochastic_dec_23.rds")
glue::glue("pbmc_glmpca_fit_{n_factor}_factors_10_hrs_avagrad_optimizer_minibatch_stochastic_dec_23.rds")
)

0 comments on commit ced5370

Please sign in to comment.