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

Assertion Error #57

Open
akashbahai opened this issue Jul 31, 2023 · 4 comments
Open

Assertion Error #57

akashbahai opened this issue Jul 31, 2023 · 4 comments

Comments

@akashbahai
Copy link

Hi,
I am trying to predict a few RNA structures. This tool is running fine for some targets, but it's running into some kind of error for other targets. The error is as follows:

Traceback (most recent call last):
File "/home/project/12003580/RoseTTAFold2NA/network/predict.py", line 374, in
pred.predict(inputs=args.inputs, out_prefix=args.prefix, ffdb=ffdb)
File "/home/project/12003580/RoseTTAFold2NA/network/predict.py", line 160, in predict
msa_i, ins_i = parse_fasta(a3m_i, rna_alphabet=is_rna, dna_alphabet=is_dna)
File "/data/projects/12003580/RoseTTAFold2NA/network/parsers.py", line 119, in parse_fasta
assert (np.all(msa<=31))
AssertionError

The RNA sequence:

8D9L_3|Chain C|Lys-tRNA|Homo sapiens (9606)
GCCCGGAUAGCUCAGUCGGUAGAGCAUCAGACUUUUAAUCUGAGGGUCCAGGGUUCAAGUCCCUGUUCGGGCG

Can you please provide me with some pointers on how to resolve this assertion error?

Best,
Akash

@akashbahai
Copy link
Author

I checked the code for the previous version and it seems that previous parsers.py didn't have this assert condition.
The new version (paersers.py, line 119) will cause an assertion error if the length of the MSA is <=31. Is that intentional?

@bifxcore
Copy link

bifxcore commented Aug 1, 2023

@akashbahai Have you checked the sequences in your MSA? I got that error because my MSA contained RNA sequences with non-standard bases, see #27

@akashbahai
Copy link
Author

@bifxcore Thanks for your comment. You were right about the presence of non-standard bases. Removing them from the alignment does seem to fix the issue.
Interestingly, the previous version used to run just fine for the same targets.

@akashbahai
Copy link
Author

If someone is still facing the same issue, they can look at this pull request pull request. I have added a script to cleanup the MSA, if it contains non-standard bases.

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