當前位置: 首頁>>代碼示例>>Python>>正文


Python EDrestraint.makeEDrestraintFromMap方法代碼示例

本文整理匯總了Python中restraints.EDrestraint.makeEDrestraintFromMap方法的典型用法代碼示例。如果您正苦於以下問題:Python EDrestraint.makeEDrestraintFromMap方法的具體用法?Python EDrestraint.makeEDrestraintFromMap怎麽用?Python EDrestraint.makeEDrestraintFromMap使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在restraints.EDrestraint的用法示例。


在下文中一共展示了EDrestraint.makeEDrestraintFromMap方法的8個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。

示例1: calcCC

# 需要導入模塊: from restraints import EDrestraint [as 別名]
# 或者: from restraints.EDrestraint import makeEDrestraintFromMap [as 別名]
def calcCC(crdlist,pts,mapfile,esmin,esmax):
    crdlist1 = VecVecFloat(crdlist)
    pis = VecInt( range(crdlist1.size()) )
    from restraints import EDrestraint
    er  = EDrestraint.makeEDrestraintFromMap(pis, "Xranker", mapfile, esmin, esmax, esmax)
    xcorr = EDrestraint.findBadfit1(mtzfn, f1label, pts, ptinds)
    print "xcor",xcorr,resids[ri]
    return xcorr
開發者ID:swanandgore,項目名稱:rappertk,代碼行數:10,代碼來源:emrefine.py

示例2: getTime

# 需要導入模塊: from restraints import EDrestraint [as 別名]
# 或者: from restraints.EDrestraint import makeEDrestraintFromMap [as 別名]
def getTime(sf,pdb):
    xrayRestGen = []
    prot = protein(pdb, read_hydrogens=0, read_waters=0, read_hets=0)
    res, resids, resnums, resns, chids, inscodes, pts = prot2res.readProtRes(prot)
    esmin, esmax, esmean, rcmult, xscoreCutoff = .000, 5., .0, 5, 0.9
    pis = VecInt(resids.keys())
    er = EDrestraint.makeEDrestraintFromMap(pis, "Xranker", phasedmtz, esmin, esmax, smax)
    score = er.scoreAll(VecVecFloat(pts))
    print score
開發者ID:swanandgore,項目名稱:rappertk,代碼行數:11,代碼來源:stumpTESTING.py

示例3: score

# 需要導入模塊: from restraints import EDrestraint [as 別名]
# 或者: from restraints.EDrestraint import makeEDrestraintFromMap [as 別名]
 def score(s, crdlist, pis=None) :
     crdlist1 = VecVecFloat(crdlist)
     #print "-----------------------------------"
     #for ci in range(crdlist1.size()) :
     #    print crdlist1[ci][0] , crdlist1[ci][0] , crdlist1[ci][0]
     if not pis : pis = VecInt( range(crdlist1.size()) )
     else : pis = VecInt( range(pis) )
     if re.compile("\.map$").search(s.phasedmtz) :
         er = EDrestraint.makeEDrestraintFromMap(pis, "Xranker", s.phasedmtz, s.esmin, s.esmax, s.esmax)
     else :
         er = EDrestraint.makeEDrestraintFromMTZ(pis, "Xranker", s.phasedmtz, s.fplabel, s.fclabel, s.philabel, s.maptype, s.esmin, s.esmax, s.esmax)
     return -1*er.scoreAround(crdlist1)
開發者ID:swanandgore,項目名稱:rappertk,代碼行數:14,代碼來源:xcheck.py

示例4: generateMAP

# 需要導入模塊: from restraints import EDrestraint [as 別名]
# 或者: from restraints.EDrestraint import makeEDrestraintFromMap [as 別名]
 def generateMAP(s, blist, aiSC) :
     print s.mapfn, s.min, s.max, s.mean
     erlist = []
     for b in blist :
         bop = b.getOP()
         edrIP = []
         for i in range(bop.size()) :
             if aiSC[bop[i]] != -1 : edrIP.append(bop[i])
         rstr = "XEnvelopeRestraint on op of %s" % b.name()
         print s.mapfn, s.min, s.max, s.mean
         erlist.append( EDrestraint.makeEDrestraintFromMap(VecInt(edrIP), rstr, s.mapfn, s.min, s.max, s.mean) )
     return erlist
開發者ID:swanandgore,項目名稱:rappertk,代碼行數:14,代碼來源:prepareChain.py

示例5: createXEnvelopeRestraints

# 需要導入模塊: from restraints import EDrestraint [as 別名]
# 或者: from restraints.EDrestraint import makeEDrestraintFromMap [as 別名]
def createXEnvelopeRestraints(blist, mapfile, aiSC) :
    from restraints import EDrestraint
    erlist = []
    for b in blist :
        bop = b.getOP()
        edrIP = []
        for i in range(bop.size()) :
            if aiSC[bop[i]] != -1 : edrIP.append(bop[i])
        rstr = "XEnvelopeRestraint on op of %s" % b.name()
        esmin, esmax, esmean, rcmult = .000, 5., .0, 5
        erlist.append( EDrestraint.makeEDrestraintFromMap(VecInt(edrIP), rstr, mapfile,esmin, esmax, esmean) )
    return erlist
開發者ID:swanandgore,項目名稱:rappertk,代碼行數:14,代碼來源:betaBuilderAK.py

示例6: createXEnvelopeRestraintsCA

# 需要導入模塊: from restraints import EDrestraint [as 別名]
# 或者: from restraints.EDrestraint import makeEDrestraintFromMap [as 別名]
def createXEnvelopeRestraintsCA(blist, mapfile, aiSC) :
    from restraints import EDrestraint
    erlist = []
    for b in blist :
        bop = b.getOP()
        edrIP = []
        if "Pept" in b.name() or "anchor" in b.name(): 
            for i in range(bop.size()) :
                print bop[i]
                #if aiSC[bop[i]] != -1 :
                edrIP.append(bop[i])
                rstr = "XEnvelopeRestraint on op of %s" % b.name()
            esmin, esmax, esmean, rcmult = .000, 5., .0, 5
            erlist.append( EDrestraint.makeEDrestraintFromMap(VecInt(edrIP), rstr, mapfile,esmin, esmax, esmean) )
        else :
            print "DDD", b.name() 
            continue

    return erlist
開發者ID:swanandgore,項目名稱:rappertk,代碼行數:21,代碼來源:betaBuilderAK.py

示例7: createXEnvelopeRestraints2

# 需要導入模塊: from restraints import EDrestraint [as 別名]
# 或者: from restraints.EDrestraint import makeEDrestraintFromMap [as 別名]
def createXEnvelopeRestraints2(blist, mapfile, aiSC,ncDummies) :
    from restraints import EDrestraint
    erlist = []
    
    print "aiSC",aiSC
    print "NCD",ncDummies
    for b in blist :
        bop = b.getOP()
        edrIP = []
        rstr = "XEnvelopeRestraint on op of %s" % b.name()
        print rstr
        for i in range(bop.size()) :
            print i , bop[i]

            if aiSC[bop[i]] != -1 :
                edrIP.append(bop[i])

        esmin, esmax, esmean, rcmult = .000, 5., .0, 5
        erlist.append( EDrestraint.makeEDrestraintFromMap(VecInt(edrIP), rstr, mapfile,esmin, esmax, esmean) )
    return erlist
開發者ID:swanandgore,項目名稱:rappertk,代碼行數:22,代碼來源:betaBuilderAK.py

示例8: main

# 需要導入模塊: from restraints import EDrestraint [as 別名]
# 或者: from restraints.EDrestraint import makeEDrestraintFromMap [as 別名]

#.........這裏部分代碼省略.........
            ml.cellsym = None

            #ml.ranker = None
            
            if cycle >= 14 and cycle <= 19 : 
                restraintList = ssList

            if cycle > 19 and cycle <= 30 : 
                restraintList = []
                
            else : ## for cycle > 30 , loose cm will come into play
                restraintList = ssList + resList
                



            #if cycle >= 15 and cycle <=25: 
            #    ml.ranker.rankGivenEnsemble =  None
            #else :
            #    ml.ranker.rankGivenEnsemble =  1
            if options.debug == 1:
                erlist = []
                for k, v in res.items():
                    resmcpts = []  ;                    resscpts = []
                    for a , b in v.items():
                        if a in [' CA ', ' N  ',' C  ',' O  '] : 
                            resmcpts.append(b)
                            descr1 = "ED on %s ca"%resids[k] 
                        
                        else:
                            resscpts.append(b)
                            descr2 = "ED on %s sc"%resids[k]
                    if len(resmcpts) !=0 :
                        erlist.append( EDrestraint.makeEDrestraintFromMap(VecInt(resmcpts), descr1, options.map, esmin, esmax, esmean) )
                    if len(resscpts) !=0 :                    
                        erlist.append( EDrestraint.makeEDrestraintFromMap(VecInt(resscpts), descr2, options.map, esmin, esmax, esmean) )
                        
                for er in erlist :
                    print er.describe();
                    print er.satisfied(VecVecFloat(pts))
                    print "========================="
                for sr in resList :
                    print sr.describe();sr.satisfied(VecVecFloat(pts))
                    
                for sr in ssList :
                    print sr.describe();sr.satisfied(VecVecFloat(pts))

                sys.exit()

            nb,notbuilt = ml.run('CA',restraintList,0)




            
    ### preFinal round to rebuild helices that have become loopxs

                
    loops , looptypes, midloops, badloops = [],[],[],[]
    for hh in  helices:
        hstart = hh[1][0]
        hstop = hh[1][1]
        loops.append([hstart,hstop])
        looptypes.append("loop")
        midloops.append(None)
                
開發者ID:swanandgore,項目名稱:rappertk,代碼行數:69,代碼來源:emrefine.py


注:本文中的restraints.EDrestraint.makeEDrestraintFromMap方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。