Train model
GSG.GSG_batch_effect_train
GSG_batch_effect_train is a function to train the generative self-supervised graph learning model for the merged data.
The inputs of this function are the anndata object returned by the GSG.Graph_Get_And_Data_Charge, including the dgl object two_graph, and the args object which saves the training parameters of the model, using this function to train the model using the gene expression information and spatial location information in the spatial transcriptome, and saving the feature embedding obtained from the training in the anndata object, and the results returned by the function are anndata object and the generative self-supervised graph learning model saved by training.
Parameters
args: argparse
The arguments of constructing graph.
two_graph: dgl object
The neighbor structure of the graph with spatial information.
Returns
model: Generative self-supervised graph learning model for the merged data.