BinPro / CONCOCT

Clustering cONtigs with COverage and ComposiTion
Other
119 stars 48 forks source link

KeyError when using fasta_to_features.py #249

Closed Ash1One closed 5 years ago

Ash1One commented 5 years ago

Hello, error returned when I try to generate composition table

Traceback (most recent call last):
  File "/home/biosoft/CONCOCT/scripts/fasta_to_features.py", line 56, in <module>
    generate_features_from_fasta(fasta_file,nr_datapoints,kmer_len,outfile)
  File "/home/biosoft/CONCOCT/scripts/fasta_to_features.py", line 40, in generate_features_from_fasta
    contigs[i,kmer_dict["".join(kmer_tuple)]] += 1
KeyError: 'AAGR'

should I replace the letters other than ATCG in my co-assembly file ? Thanks!

alneberg commented 5 years ago

Hello @Ash1One, yes concoct can only use the standard kmers currently, so replacing the non-ATCG characters is needed. Are some assembly programs actually giving out such contig sequences?

Ash1One commented 5 years ago

Hi @alneberg ,actually the contig sequences is goldStandAssemly.fasta from CAMI. Thank you for your answer.😀