chengyuan / reago-1.1

19 stars 12 forks source link

REAGO fails with error "TypeError: object of type 'dictionary-keyiterator' has no len()" #19

Open mpjuers opened 7 years ago

mpjuers commented 7 years ago
$ python reago.py filtered.fasta out -l 150

...

Traceback (most recent call last):
    File "reago.py",line 823 , in <module>
        correct_sequencing_error(subgraph,5)
    File "reago.py", line 137, in correct_sequencing_error
        if len(G.predecessors(node_str__ == 0:
TypeError: object of type 'dictionary-keyiterator' has no len()

Any ideas on how to begin to troubleshoot this? I can provide some data if it helps. It seems to be sensitive to read length, i.e., if I use a longer, erroneous read length, I don't get the error, but then of course it doesn't work for other reasons.

filip-husnik commented 7 years ago

I'm getting exactly the same error. All my reads are 126 bp [-l 126]. My guess is that reago.py doesn't work with longer reads...

HRGV commented 6 years ago

I have the same problem here on the provided sample data The filtering was done with

$ ./filter_input.py sample_1.fasta sample_2.fasta test_dir ./cm/ ba 6

and seemed to have worked

$ ./reago.py ./test_dir/filtered.fasta final_output -l 101

led to

Tue Nov 21 13:54:16 2017 REAGO (v1.10) started...
Input file: ./test_dir/filtered.fasta
Parameters:
-e 0.05
-f 1350
-b 10
-l 101.0
-o 0.7
-t 30
Tue Nov 21 13:54:16 2017 Reading input file...
Tue Nov 21 13:54:16 2017 Initializing overlap graph...
Tue Nov 21 13:54:17 2017 Recovering 16S rRNAs...
Traceback (most recent call last):
  File "./reago.py", line 856, in <module>
    correct_sequencing_error(subgraph, 5)
  File "./reago.py", line 170, in correct_sequencing_error
    if len(G.predecessors(node_str)) == 0:
TypeError: object of type 'dictionary-keyiterator' has no len()
filip-husnik commented 6 years ago

I've tried to contact the author about this issue by email a month ago, but with no success. It seems to me that REAGO is no longer maintained/supported which is unfortunate given that it can sometimes outperform EMIRGE [btw, I'm a big fan of your PhyloFlash and using it a lot].

biofuture commented 6 years ago

I guess the problem is from the version of networkx, you can install networkx version lower than 2.0 then this problem could be removed, However I still got another error: networkx.exception.NetworkXError: The node 1700.2 is not in the digraph.

This tool looks fancy however the document about the software is not that friendly written.

biofuture commented 6 years ago

Currently, after quality control, the length of reads are not uniform. I do not know whether this tool support variant length of reads or not.

RobertBakaric commented 5 years ago

No support, no licence, well than no paper citations , fair enough ? I also have a lot of problems with the tool (all of the above stated) plus extra ones and have been trying to debug it but finally quit fixing it ... EMIRGE seams to the the only solution on the market ...