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

An error occurred when I use ananse influence with -w #211

Open
socialtree-yt opened this issue Dec 7, 2023 · 5 comments
Open

An error occurred when I use ananse influence with -w #211

socialtree-yt opened this issue Dec 7, 2023 · 5 comments

Comments

@socialtree-yt
Copy link

socialtree-yt commented Dec 7, 2023

I use ananse influence to compare two networks successfully but failed when I add a white list of genes. My list goes as follow:
image

And the error is :

An error has been caught in function '<module>', process 'MainProcess' (71394), thread 'MainThread' (139919365887808):

Traceback (most recent call last):

> File "/mnt/dfc_data1/home/yanteng/micromamba/envs/ananse/bin/ananse", line 609, in <module>
    args.func(args)
    │    │    └ Namespace(target_file='KF_enhancer_network.tsv', expression='/mnt/dfc_data2/project/yanteng/human.aging/GSE163973.keloidscRNA...
    │    └ <function influence at 0x7f3eb9c21a20>
    └ Namespace(target_file='KF_enhancer_network.tsv', expression='/mnt/dfc_data2/project/yanteng/human.aging/GSE163973.keloidscRNA...
  File "/mnt/dfc_data1/home/yanteng/micromamba/envs/ananse/lib/python3.10/site-packages/ananse/commands/influence.py", line 9, in influence
    a = ananse.influence.Influence(
        │      │         └ <class 'ananse.influence.Influence'>
        │      └ <module 'ananse.influence' from '/mnt/dfc_data1/home/yanteng/micromamba/envs/ananse/lib/python3.10/site-packages/ananse/influ...
        └ <module 'ananse' from '/mnt/dfc_data1/home/yanteng/micromamba/envs/ananse/lib/python3.10/site-packages/ananse/__init__.py'>
  File "/mnt/dfc_data1/home/yanteng/micromamba/envs/ananse/lib/python3.10/site-packages/ananse/influence.py", line 368, in __init__
    self.read_networks(
    │    └ <function Influence.read_networks at 0x7f3ec5374700>
    └ <ananse.influence.Influence object at 0x7f3eb923b040>
  File "/mnt/dfc_data1/home/yanteng/micromamba/envs/ananse/lib/python3.10/site-packages/ananse/influence.py", line 403, in read_networks
    self.grn = difference(
    │    │     └ <function difference at 0x7f3ec5374280>
    │    └ None
    └ <ananse.influence.Influence object at 0x7f3eb923b040>
  File "/mnt/dfc_data1/home/yanteng/micromamba/envs/ananse/lib/python3.10/site-packages/ananse/influence.py", line 163, in difference
    diff_network = _filter_network_edges(diff_network, sort_by, edges, whitelist)
                   │                     │             │        │      └ ('A2M', 'ABI3BP', 'ACAN', 'ADAM10', 'ADAM11', 'ADAM12', 'ADAM15', 'ADAM17', 'ADAM19', 'ADAM22', 'ADAM23', 'ADAM28', 'ADAM30',...
                   │                     │             │        └ 500000
                   │                     │             └ 'prob'
                   │                     └                         weight
                   │                       tf_target
                   │                       HOXC12—LINC00316  3.000000e-08
                   │                       LEF1—AL512598.1   3.000000e-08
                   │                       N...
                   └ <function _filter_network_edges at 0x7f3ec5374310>
  File "/mnt/dfc_data1/home/yanteng/micromamba/envs/ananse/lib/python3.10/site-packages/ananse/influence.py", line 191, in _filter_network_edges
    tfs = set(df.index.str.startswith(whitelist).index)
              │  │                    └ ('A2M', 'ABI3BP', 'ACAN', 'ADAM10', 'ADAM11', 'ADAM12', 'ADAM15', 'ADAM17', 'ADAM19', 'ADAM22', 'ADAM23', 'ADAM28', 'ADAM30',...
              │  └ <pandas._libs.properties.AxisProperty object at 0x7f3ecb106260>
              └                         weight
                tf_target
                HOXC12—LINC00316  3.000000e-08
                LEF1—AL512598.1   3.000000e-08
                N...

AttributeError: 'numpy.ndarray' object has no attribute 'index'
@siebrenf
Copy link
Member

Found the issue! It was a very silly coding mistake by me :o The fix is on the develop branch now. Install it with

pip install git+https://github.com/vanheeringen-lab/ANANSE.git@develop

@socialtree-yt
Copy link
Author

I tried some times but if failed. Can I upgrade it through conda? The error is as follow:
(ananse) [yanteng@compute-0-2 ~]$ pip install git+https://github.com/vanheeringen-lab/ANANSE.git@develop
Collecting git+https://github.com/vanheeringen-lab/ANANSE.git@develop
Cloning https://github.com/vanheeringen-lab/ANANSE.git (to revision develop) to /tmp/pip-req-build-t7myh_f2
Running command git clone --quiet https://github.com/vanheeringen-lab/ANANSE.git /tmp/pip-req-build-t7myh_f2
error: RPC failed; curl 18 transfer closed with outstanding read data remaining
fatal: The remote end hung up unexpectedly
fatal: early EOF
fatal: index-pack failed
error: subprocess-exited-with-error

× git clone --quiet https://github.com/vanheeringen-lab/ANANSE.git /tmp/pip-req-build-t7myh_f2 did not run successfully.
│ exit code: 128
╰─> See above for output.

note: This error originates from a subprocess, and is likely not a problem with pip.
error: subprocess-exited-with-error

× git clone --quiet https://github.com/vanheeringen-lab/ANANSE.git /tmp/pip-req-build-t7myh_f2 did not run successfully.
│ exit code: 128
╰─> See above for output.

note: This error originates from a subprocess, and is likely not a problem with pip.

@Roki12543
Copy link

Have you fixed this issue? I'm having the same problem as you

@siebrenf
Copy link
Member

I'll create a hotfix release, but that error message suggests there was an issue with the connection!

@siebrenf
Copy link
Member

Conda update will be available shortly after this PR is merged!

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

3 participants