Package schrodinger :: Package ui :: Package qt :: Module appframework :: Class Host
[hide private]
[frames] | no frames]

Class Host

         object --+    
                  |    
job.jobcontrol.Host --+
                      |
                     Host

Extension of jobcontrol.Host class with GPUs.

Instance Methods [hide private]
 
__eq__(self, other)
Allows equality comparisons between two different host objects that represent the same host.
 
__init__(self, name, processors=0, num_gpus=0, gpulist=None)
Create a named Host object.
 
__repr__(self)
Return the formal string representation of the Host.
 
__str__(self)
Return the informal string representation of the Host -- a comma-separated list of "Key: value" attribute pairs.
 
autoSetGpuList(self)
 
hostType(self)
Used to determine what type of host this is.
 
label(self)
Returns the string to show in controls, etc.
 
maxNum(self)
Returns the number of processors for the type of host - for GPU host, return the number of GPUs, for non-GPU hosts, return the number of CPUs.
 
setGpuList(self, gpulist)
 
units(self)
Return the unit string for the type of processors provided by this host.

Inherited from job.jobcontrol.Host: getHost, isQueue, setHost, to_hostentry

Inherited from job.jobcontrol.Host (private): _hostLines

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __setattr__, __sizeof__, __subclasshook__

Class Methods [hide private]
 
fromJobControlHost(cls, jchost, ncpus)
Class Variables [hide private]
  CPUTYPE = 'cpu'
  GPUTYPE = 'gpu'
Properties [hide private]

Inherited from job.jobcontrol.Host: host

Inherited from object: __class__

Method Details [hide private]

__eq__(self, other)
(Equality operator)

 

Allows equality comparisons between two different host objects that represent the same host. This is necessary if get_hosts() is called two different times and hosts from one call are to be compared with hosts from the other call.

Hosts are considered equal if they have the same name and processors.

Parameters:
  • other (Host) - the host to be compared with self

__init__(self, name, processors=0, num_gpus=0, gpulist=None)
(Constructor)

 

Create a named Host object. The various host attributes must be set after object instatiation.

Only host-entry fields can be public attributes of a Host object. Attributes introduced to capture other information about the entry must be private (named with a leading underscore.)

Overrides: object.__init__
(inherited documentation)

__repr__(self)
(Representation operator)

 

Return the formal string representation of the Host.

Overrides: object.__repr__
(inherited documentation)

__str__(self)
(Informal representation operator)

 

Return the informal string representation of the Host -- a comma-separated list of "Key: value" attribute pairs.

Overrides: object.__str__
(inherited documentation)