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

Reopen #7: pLDDT not writing to PDB #191

Open
LandonGetz opened this issue Jan 26, 2025 · 1 comment
Open

Reopen #7: pLDDT not writing to PDB #191

LandonGetz opened this issue Jan 26, 2025 · 1 comment

Comments

@LandonGetz
Copy link

I am having the same issue as was previously reported in #7, where all pLDDT values are being stored as 1.00. Including print(protein.plddt) provides the per-residue tensor values for pLDDT (values less than 1), so I know the model is generating them. I am running code that is very similar to #7.

Am I missing something obvious or has that previous bug popped back up?

@LandonGetz
Copy link
Author

LandonGetz commented Jan 26, 2025

I think this issue is in handling of the protein_complex into .to_pdb. If I print the output of

protein_complex= protein.to_protein_complex()
for chain in protein_complex.chain_iter():
    print(chain.confidence)

I get an array of 1's (which is what is being output into the b-factor column of my PDBs). I've managed to hack my way out of this by running protein.to_pdb_string() and then writing the PDB file manually:

scaled_plddt = protein.plddt * 100
 protein_chain = protein.to_protein_chain()
 protein_chain.confidence = scaled_plddt.detach().cpu().numpy()
 pdb_string = protein_chain.to_pdb_string()
 with open(out_pdb, "w") as f:
        f.write(pdb_string)

Let me know if I'm just missing something silly, or if this is a bona fide bug

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

1 participant