Open jefferyUstc opened 1 year ago
Hi @jefferyUstc
The regression model doesn't have a cell-specific normalisation parameter detection_y_c
- only a batch-specific normalisation parameter detection_y_e
(called h_e
in equation 28 in Supplementary Methods https://static-content.springer.com/esm/art%3A10.1038%2Fs41587-021-01139-4/MediaObjects/41587_2021_1139_MOESM1_ESM.pdf).
All results presented in the paper as well as in the tutorial are not scaling the reference expression signatures by normalisation parameter (average across batches). This scaling is not important because it is just a scalar value which is used to scale all values in the reference expression signature matrix (multiplication by a constant).
What's important is that the reference signatures are estimated while accounting for the technical effects (everything in equation 28). This is done when the model is trained, so the output reference signatures are already corrected.
I will change the default to scale_average_detection=False
.
Hi, cell2locatiob team,
I noticed that there’s param named
scale_average_detection
in methodRegressionModel.export_posterior()
source code. whenscale_average_detection=True
, this seems to correct the inference signature based on the "expected detection sensitivity" described in the manuscript. However, in the source code export_posterior, there's adetection_y_c
for this purpose. Following the official tutorial, in actually, this step does not happen, cause nodetection_y_c
inself.samples["post_sample_means"].keys()
.BTW, how can I get the result of
detection_y_c
?