Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

high memory consumption and nonetype error #341

Open
wangjiawen2013 opened this issue Mar 21, 2024 · 0 comments
Open

high memory consumption and nonetype error #341

wangjiawen2013 opened this issue Mar 21, 2024 · 0 comments

Comments

@wangjiawen2013
Copy link

Hi,
I tried to export adata object to mtx format (matrix.mtx, genes.tsv, barcodes.tsv) using besca.export.X_to_mtx while finding that it took a lot o memory. Are there any ways to reduce the memory usage ?
image

Besides, sometimes the following error occured, how to keep avoid of it ?

In [28]: bc.export.X_to_mtx(adata)
writing out matrix.mtx ...
adata.X successfully written to matrix.mtx.
---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call last)
Cell In[28], line 1
----> 1 bc.export.X_to_mtx(adata)

File ~/programs/miniconda3/envs/py311/lib/python3.11/site-packages/besca/export/_export.py:124, in X_to_mtx(adata, outpath, write_metadata, geneannotation, additional_geneannotation)
    122         fp.write(ENSEMBL + "\t" + symbol + "\t" + feature + "\n")
    123 else:
--> 124     for ENSEMBL, symbol in zip(genes_ENSEMBL, genes_SYMBOL):
    125         fp.write(ENSEMBL + "\t" + symbol + "\n")
    126 fp.close()

TypeError: 'NoneType' object is not iterable
@wangjiawen2013 wangjiawen2013 changed the title high memory consumption high memory consumption and nonetype error Mar 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant