immunogenomics / symphony

Efficient and precise single-cell reference atlas mapping with Symphony
GNU General Public License v3.0
95 stars 22 forks source link

load harmonized embeddings into harmony object for use with Symphony #15

Closed hbandukw closed 2 years ago

hbandukw commented 2 years ago

Hello,

I have an atlas that was produced by integrating data with Harmony. I want to use the integrated data with Symphony's mapQuery function. The recommended option i.e. Option 1 listed on https://github.com/immunogenomics/symphony starts with an existing harmony object which is then used to make a Symphony reference using buildReferenceFromHarmonyObj.

I currently have the harmonized embeddings integrated into a .h5seurat file. Is there a way I can extract the necessary components from this file and load them into R as a harmony object?

Please note that I have also posted this issue on harmony: https://github.com/immunogenomics/harmony/issues/142

joycekang commented 2 years ago

Hi there,

Apologies for the delay in getting back to you. We currently do not have the ability to generate a Symphony reference using only the harmonized embedding, unfortunately. This is because the Symphony soft cluster centroids and "reference compression terms" are not saved into the Seurat object by default, and we currently don't have a way to back-calculate them after the fact. If you have the list of steps and parameters that were used to generate the Seurat object, I wonder if you can recreate it, then use the RunHarmony.Seurat function in vignettes/utils_seurat.R (following our Seurat tutorial).