
Run NMF (HALS) on the GPU over a set of single cells and genes
rs_nmf_single_sc_gpu.Rd
GPU counterpart of
bixverse::rs_nmf_single_sc(). The counts are loaded
from the binary store once, uploaded to the device, and the whole HALS loop
runs there. The NNDSVD initialisation stays on the host.
Usage
rs_nmf_single_sc_gpu(
f_path_gene,
gene_indices,
cell_indices,
k,
preprocessing,
use_second_layer,
nmf_hals_params,
seed,
verbose
)Arguments
- f_path_gene
Path to the
counts_genes.binfile.- gene_indices
Integer vector. 0-indexed(!) positions of the genes to include.
- cell_indices
Integer vector. 0-indexed(!) positions of cells to include in the analysis.
- k
Integer. Number of latent factors to return. At most 128, the GPU solver's rank cap.
- preprocessing
String. One of
c("none", "sd", "sqrt_sd"). Takes the data as is, or scales by standard deviation or squared standard deviation per feature.- use_second_layer
Boolean. If
TRUE, runs NMF on the normalised counts; ifFALSE, on the raw counts.- nmf_hals_params
Named list. Contains the NMF parameters.
- seed
Integer. Random seed for initialisation.
- verbose
Integer.
0L- quiet;1L- normal verbosity;2L- detailed verbosity.