GithubHelp home page GithubHelp logo

Comments (2)

sokrypton avatar sokrypton commented on May 9, 2024

Thanks! Do you have an example input where this change is needed?

from colabdesign.

data2code avatar data2code commented on May 9, 2024

1crn.pdb.txt

Using the following toy example, the output from fix_partial_contigs becomes A1-44, and this then leads to incorrect output for fix_pdb, (chain E should have been renamed to B, but it is renamed to chain A by mistake).

If you change fix_partial_contigs to fix_contigs, the behavior is correct.

from inference.utils import parse_pdb
from colabdesign.rf.utils import fix_contigs, fix_partial_contigs, fix_pdb
parsed_pdb = parse_pdb('1crn.pdb')

pdb_str=open(f"1crn.pdb").read()
contigs = fix_partial_contigs(['A1-7/A10-44', 'E'], parsed_pdb)
print(contigs)
print("\n".join(fix_pdb(pdb_str, contigs).split("\n")[-6:]))

output:

['A1-44', 'E45-46']
ATOM    323  CB  ASN A  44      12.266   4.769  13.501  1.00  7.27      A    C
ATOM    324  CG  ASN A  44      12.538   4.304  14.922  1.00  7.98      A    C
ATOM    325  ND2 ASN A  44      13.407   3.298  15.015  1.00 10.32      A    N
ATOM    326  OD1 ASN A  44      11.982   4.849  15.886  1.00 11.00      A    O
ATOM    327  OXT ASN A  44      12.703   4.973  10.746  1.00  7.86      A    O1-
TER

from colabdesign.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.