You are here

clean_pdb_keep_ligand.py IndexError

2 posts / 0 new
Last post
clean_pdb_keep_ligand.py IndexError
#1

(base) ubun@ubun-System-Product-Name:~/relax/test$ python $ROSETTA/main/source/src/apps/public/relax_w_allatom_cst/clean_pdb_keep_ligand.py 01-MD-086DS.pdb -ignorechain
Traceback (most recent call last):
  File "/home/ubun/rosetta/main/source/src/apps/public/relax_w_allatom_cst/clean_pdb_keep_ligand.py", line 135, in <module>
    if (chainid == line[21] or ignorechain):
IndexError: string index out of range
 

The 01-MD-086DS.pdb file contains a substrate and a cofactor.

AttachmentSize
01-MD-086DS.pdb440.28 KB
Category: 
Post Situation: 
Sat, 2022-09-10 04:04
to-qinbin@163.com

The issue is that the script is expecting files with whitespace padding out to 80 columns (like the wwPDB provides). In your file, the CONECT records aren't whitespace padded. Luckily, Rosetta won't use the CONECT lines, so you can just manually delete them.

That said, Rosetta has gotten better at reading PDBs, and the PDB you procided is basically "clean" as it is. Honestly, I'd probably just recommend skipping the clean PDB step, and using your PDB as-is with Rosetta. (I believe that Rosetta should be able to handle the non-whitespace padded CONECT lines.)

Mon, 2022-09-12 06:58
rmoretti