RosettaCommons / RosettaCommons/PyRosetta.notebooks

ERROR/warning when read pdb files

Open
#91 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Jupyter Notebook
Stars
709
Forks
173
Avg merge
5m
Merged PRs (30d)
2

Description

I want to know whether the following ERROR/warning matters when I mutate amino acids in pyrosetta:

core.import_pose.import_pose: File '/data2/rjli/test_dataset/1amk/1amk_protein.pdb' automatically determined to be of type PDB
core.io.pdb.HeaderInformation: [ WARNING ] Deposition day not in range [1, 31]: 0
core.io.pdb.HeaderInformation: [ WARNING ] Unrecognized month in HEADER deposition date             
core.io.pdb.HeaderInformation: [ ERROR ] Malformed Compound record found: ' 1AMK_PROTEIN'
core.io.pose_from_sfr.PoseFromSFRBuilder: [ WARNING ] discarding 4 atoms at position 1 in file /data2/rjli/test_dataset/1amk/1amk_protein.pdb. Best match rsd_type:  SER:NtermProteinFull

THE PYTHON CODE :

import os
from pyrosetta import *
from pyrosetta.rosetta.protocols.simple_moves import MutateResidue
init()

source_folder = '/data2/rjli/test_dataset'

for id in os.listdir(source_folder):
    folder_path = os.path.join(source_folder, id)
    if os.path.isdir(folder_path):
        for file in os.listdir(folder_path):
            if file.endswith('protein.pdb'):
                protein_file = os.path.join(folder_path, file)
                pose = pose_from_pdb(protein_file)
                n_res = pose.total_residue()
                # loop over all residues
                for i in range(1, n_res + 1):
                    res = pose.residue(i)
                    if res.name() == "ASN":
                        # create a MutateResidue mover to mutate Asn to Leu
                        mut = MutateResidue(i, "LEU")
                        mut.apply(pose)
                    if res.name() == "GLN":
                        # create a MutateResidue mover to mutate GLN to Leu
                        mut = MutateResidue(i, "LEU")
                        mut.apply(pose)
                output_file = os.path.join(folder_path, f'{id}_mutate0_protein.pdb')
                pose.dump_pdb(output_file)

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the supplied Python loop and its pose_from_pdb call, then inspect the input PDB header and compound records alongside the reported discarded atoms. Determine whether the warnings change the loaded pose or the subsequent mutations; the issue is done when the impact of each message and any required input correction are documented.

Written by the indexing model from the issue text.

Assessment

Tech stack
jupyter-notebook, python
Domain
bioinformatics
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
20/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.