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

prune_ngsLD.py error #41

Open
Andrew-N-Black opened this issue Dec 19, 2022 · 1 comment
Open

prune_ngsLD.py error #41

Andrew-N-Black opened this issue Dec 19, 2022 · 1 comment

Comments

@Andrew-N-Black
Copy link

Hello, I'm receiving an error trying to prune sites in a conda env. Both pandas and graph-tool are loading, running python3. Can you help debug?

#Command
~/ngsLD/scripts/prune_ngsLD.py --input LD/test --max_dist 5000 --min_weight 0.5 --out LD/testLD_unlinked.pos

#stout
Checking if file is gzipped...
Reading in data...
Traceback (most recent call last):
File "/home/blackan/ngsLD/scripts/prune_ngsLD.py", line 94, in
G = load_graph_from_csv(args.input, directed = False,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/blackan/.conda/envs/cent7/2020.11-py38/ld/lib/python3.11/site-packages/graph_tool/init.py", line 3486, in load_graph_from_csv
name = g.add_edge_list(itertools.chain([line], r), hashed=hashed,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/blackan/.conda/envs/cent7/2020.11-py38/ld/lib/python3.11/site-packages/graph_tool/init.py", line 2507, in add_edge_list
libcore.add_edge_list_hashed(self.__graph, edge_list,
File "/home/blackan/.conda/envs/cent7/2020.11-py38/ld/lib/python3.11/site-packages/graph_tool/init.py", line 2493, in
yield (val if i < 2 else converti - 2
^^^^^^^^^^^^^^^^^^^
File "/home/blackan/.conda/envs/cent7/2020.11-py38/ld/lib/python3.11/site-packages/graph_tool/init.py", line 275, in convert
return vtype(val)
^^^^^^^^^^
ValueError: invalid literal for int() with base 10: 'dist'

@fgvieira
Copy link
Owner

I just released a more efficient alternative to the pruning scripts (check the README); do you think you could give it a try and see if you get the same error?

If you do, can you send me the input file you are using?

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