Class HaddockExpertInterface
source code
object --+
|
HaddockEasyInterface --+
|
HaddockExpertInterface
Spyder-generated class
module haddock
file /home/sjoerd/data/Spyder-devel/haddock/haddock.spy
Description
Web form for the HADDOCK server Expert Interface
Wiki
http://www.spyderware.nl/wiki/classes/HaddockExpertInterface
Validate block
>>>
if solvent != None: assert solvent in ("water", "dmso")
has_r1 = (p1.r != None and (len(p1.r.activereslist) > 0 or len(p1.r.passivereslist) > 0))
has_r2 = (p2.r != None and (len(p2.r.activereslist) > 0 or len(p2.r.passivereslist) > 0))
if has_r1 != has_r2: raise HaddockValidationError("You must supply either active and passive residues for both proteins or for neither of them.")
if has_r1 == (tblfile != None or unambigtblfile != None):
if not has_r1:
if ranair == False and cmrest == False and surfrest == False:
raise HaddockValidationError("You can define active and passive residues for both proteins. Alternatively, in Expert/Guru mode, you can also define a restraints table, random restraints, or center-of-mass restraints.\nHADDOCK cannot run without this. Please provide one of the two.")
if has_r1 == (tblfile != None):
if has_r1:
raise HaddockValidationError("You can define active and passive residues for both proteins. Alternatively, in Expert/Guru mode, you can also define a restraints table, random restraints, or center-of-mass restraints. These options are mutually exclusive, but both have been defined here.\nPlease remove either the restraints table or the active and passive residues.")
if has_r1:
if len(p1.r.activereslist) == 0 and len(p2.r.activereslist) == 0:
raise HaddockValidationError("You have defined only passive residues. HADDOCK needs at least one active residue to drive the docking.")
if len(p1.r.activereslist) == 0 and len(p2.r.passivereslist) > 0:
raise HaddockValidationError("Protein 1 has no active residues defined. Therefore, it is meaningless to define passive residues on protein 2. Please remove the passive residues on protein 2.")
if len(p2.r.activereslist) == 0 and len(p1.r.passivereslist) > 0:
raise HaddockValidationError("Protein 2 has no active residues defined. Therefore, it is meaningless to define passive residues on protein 1. Please remove the passive residues on protein 1.")
restcount = 0
if ranair == True: restcount += 1
if has_r1 or tblfile != None or unambigtblfile != None: restcount += 1
if restcount > 1:
raise HaddockValidationError("Manual restraints and random patches are mutually exclusive")
if not (p1.segid == None or (p1.segid != p2.segid)):
raise HaddockValidationError("You must supply segids for every PDB and they must be different")
if not (structures_0 > 0): raise HaddockValidationError("At least one rigid body (it0) structure must be generated, increase the number of structures")
if structures_1 > structures_0:
raise HaddockValidationError("You cannot generate more structures in it1 than in it0")
if waterrefine > structures_1:
raise HaddockValidationError("You cannot generate more structures in the water refinement than in it1")
if ncvpart <= 1:
raise HaddockValidationError("The number of crossvalidation partitions may be fractional, but must be larger than 1")
if ncvpart - int(ncvpart) > 0:
if tblfile != None:
raise HaddockValidationError("The number of crossvalidation partitions may be fractional, but not if a restraints table is supplied")
if runname != None:
runname = runname.strip()
self.runname = runname
if not runname.replace("_","").replace("-","").isalnum():
raise HaddockValidationError("The name of your run may contain only letters, digits, _ and -")
>>>
Form block
>>>
HEADER runname You may supply a name for your docking run (one word)
runname Name
p1 First molecule
p2 Second molecule
HEADER username Username and password
TYPE username required
username Username
TYPE password password
password Password
OPTION solvent "water", "dmso"
>>>
Converters
Can be converted to:
Can be converted from:
|
Inherited from object:
__delattr__,
__format__,
__getattribute__,
__hash__,
__init__,
__new__,
__reduce__,
__reduce_ex__,
__repr__,
__setattr__,
__sizeof__,
__str__,
__subclasshook__
|
|
Inherited from object:
__class__
|