Giter VIP home page Giter VIP logo

mousipy's People

Contributors

stefanpeidli avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

wgsim rnaimehaom

mousipy's Issues

FileNotFoundError when loading

Hi all,

After installing mousipy with pip, I ran the recommended code and received this error:

import scvelo as scv
from mousipy import translate

FileNotFoundError: [Errno 2] No such file or directory: 'src/mousipy/biomart/human_to_mouse_biomart_export.csv'

Do I need to download this csv?

from human to mouse

Hi!
Are you planning to add a function that can translate from human genes to mouse genes?
Best, Sandra

Error: 'numpy.ndarray' object has no attribute 'A'

Could you please help?
import scvelo as scv
from mousipy import translate
humanized_mdata = translate(mdata)

AttributeError Traceback (most recent call last)
Input In [219], in <cell line: 3>()
1 import scvelo as scv
2 from mousipy import translate
----> 3 humanized_mdata = translate(mdata)

File ~/ENTER/lib/python3.9/site-packages/mousipy/mousipy.py:196, in translate(adata, stay_sparse)
193 # for those with an entry but no ortholog we assume that there really is no known ortholog
194 # which means we ignore genes in m2h_no_hit
195 bdata = translate_direct(adata, direct, no_index)
--> 196 bdata = translate_multiple(bdata, adata, multiple, stay_sparse=stay_sparse)
197 bdata = collapse_duplicate_genes(bdata, stay_sparse=stay_sparse)
198 return bdata

File ~/ENTER/lib/python3.9/site-packages/mousipy/mousipy.py:122, in translate_multiple(adata, original_data, multiple, stay_sparse)
106 """Adds the counts of multiple-hit genes to ALL their orthologs.
107 Parameters
108 ----------
(...)
119 Updated original adata.
120 """
121 from scipy.sparse import csr_matrix, hstack
--> 122 X = adata.X.copy() if stay_sparse else adata.X.A.copy()
123 var = adata.var.copy()
124 for mgene, hgenes in tqdm(multiple.items(), leave=False):

AttributeError: 'numpy.ndarray' object has no attribute 'A'

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.