`library(Seurat)
library(ggplot2)
library(patchwork)
library(dplyr)
library(hdf5r)
data.image = Read10X_Image("/home/bao_jingyi/bjyspace/spatial/",
image.name = "tissue_hires_image.png")
data <- Load10X_Spatial(
data.dir = "/home/bao_jingyi/bjyspace/",
filename = "filtered_feature_bc_matrix.h5",
assay = "Spatial",
slice = "LC-156519-BC-swollen2-edge3-liver5",
image = data.image
)
data
An object of class Seurat
18085 features across 203083 samples within 1 assay
Active assay: Spatial (18085 features, 0 variable features)
1 layer present: counts
1 spatial field of view present: LC.156519.BC.swollen2.edge3.liver5
data<- SCTransform(data, assay = "Spatial", verbose = FALSE)
vst.flavor is set to 'v2' but could not find glmGamPoi installed.
Please install the glmGamPoi package for much faster estimation.
install.packages('BiocManager')
BiocManager::install('glmGamPoi')
Falling back to native (slower) implementation.
Error in make_cell_attr(umi, cell_attr, latent_var, batch_var, latent_var_nonreg, :
cell attribute "log_umi" contains NA, NaN, or infinite value`

I have tried a variety of methods but can't solve this error, please give a solution or suggestion to solve this error, thank you.