Cell_BLAST icon indicating copy to clipboard operation
Cell_BLAST copied to clipboard

Cross-Species Celltype Annotation

Open CHANG-Shaole opened this issue 11 months ago • 5 comments

Hi, Cell BLAST team!

Recently, I wanted to use your method to perform the Cross-species cell type annotation tasks. However, I cannot see any cross-species cell type annotation examples on the Cell BLAST tutorial page.

So, I want to know if there are any exps I can do quickly to start the cross-species cell type annotation task by using your great method.

CHANG-Shaole avatar Feb 29 '24 03:02 CHANG-Shaole

Hi @CHANG-Shaole. Thanks for your interest in Cell BLAST!

To perform cross-species cell type annotation with Cell BLAST, you would need to align the gene names across species using ortholog relations first. For close species like human and mouse, I'd recommend keeping just the one-to-one orthologs, and rename genes of one species into the other before feeding the data to the model.

For evolutionally more distant species where the number of one-to-one orthologs is limited, the integration can be more challenging. In that case I'd recommend trying other methods like CAME or SAMap, which were designed to better address this challenge.

Let me know if there were further issues.

Jeff1995 avatar Feb 29 '24 06:02 Jeff1995

Thank you for your in-time reply! I will give it a try.

CHANG-Shaole avatar Feb 29 '24 07:02 CHANG-Shaole

Sorry for bothering you again. It seems that the links of exp data-Baron_human.h5ad and Lawlor.h5ad are invalid. I would much appreciate it if you could give me another link for the data download.

CHANG-Shaole avatar Feb 29 '24 08:02 CHANG-Shaole

I tried downloading them, and they seem to be working just fine. Could you try a different browser, or use command line tools like wget or curl?

Jeff1995 avatar Mar 06 '24 12:03 Jeff1995

Thank you for the reply! Recently I tried to follow your demo. But whenever I run such a block:

blast = cb.blast.BLAST(models, baron_human)

it came with an error:

TypingError: Failed in nopython mode pipeline (step: nopython frontend)
No implementation of function Function(<function wasserstein_distance at 0x0000014F81236C10>) found for signature:
 
 >>> wasserstein_distance(array(float64, 1d, C), array(float64, 1d, C))
 
There are 2 candidate implementations:
   - Of which 2 did not match due to:
   Overload of function 'wasserstein_distance': File: Cell_BLAST\blast.py: Line 48.
     With argument(s): '(array(float64, 1d, C), array(float64, 1d, C))':
    No match.

During: resolving callee type: Function(<function wasserstein_distance at 0x0000014F81236C10>)
During: typing of call at [d:\Anaconda3\envs\cb\lib\site-packages\Cell_BLAST\blast.py](file:///D:/Anaconda3/envs/cb/lib/site-packages/Cell_BLAST/blast.py) (229)


File "d:\Anaconda3\envs\cb\lib\site-packages\Cell_BLAST\blast.py", line 229:
def npd_v1(
    <source elided>
    return 0.5 * (
        scipy.stats.wasserstein_distance(
        ^

Could you tell me what the error is and how to solve it?

I am sure everything follows your demo, and I tried it on both Windows and Linux OS.

CHANG-Shaole avatar Mar 14 '24 06:03 CHANG-Shaole