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

tf_result_explanations - AttributeError: module 'networkx' has no attribute 'read_gpickle' #38

Open
sngholee opened this issue Feb 1, 2024 · 1 comment

Comments

@sngholee
Copy link

sngholee commented Feb 1, 2024

Hello,

I'm attempting to run tf_results_explanations. I successfully ran the previous two steps

tf_result_explanations -p 0.01 -d High_ATAC_0_peaks_vs_High_ATAC_24_peaks_differential_md_scores.txt -o High_0vs24_explanations

But I get this error:

Traceback (most recent call last): File "/public/home/slee393/miniconda3/bin/tf_result_explanations", line 8, in <module> sys.exit(tf_result_explanations()) ^^^^^^^^^^^^^^^^^^^^^^^^ File "/public/home/slee393/miniconda3/lib/python3.11/site-packages/DAStk/__init__.py", line 21, in tf_result_explanations e.main() ^^^^^^^^ File "/public/home/slee393/miniconda3/lib/python3.11/site-packages/DAStk/tf_result_explanations.py", line 36, in main G = nx.read_gpickle(KNOWLEDGE_GRAPH) ^^^^^^^^^^^^^^^ AttributeError: module 'networkx' has no attribute 'read_gpickle'

Any help would be appreciated. Is this a Python version issue?

@ignaciot
Copy link
Collaborator

ignaciot commented Feb 1, 2024

It looks like the networkX library changed the methods to read/write pickled graphs in version 3.0. I'll be pushing an update to support this, but in the meantime you can test downgrading your networkx version to any one 2.9 or lower.

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

2 participants