Rosetta  2021.16
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | Static Public Attributes | List of all members
pyrosetta.distributed.cluster.core.PyRosettaCluster Class Reference
Inheritance diagram for pyrosetta.distributed.cluster.core.PyRosettaCluster:
Inheritance graph
[legend]

Public Member Functions

def __attrs_post_init__
 
def distribute
 
- Public Member Functions inherited from pyrosetta.distributed.cluster.logging_support.LoggingSupport
def __init__
 

Static Public Attributes

tuple tasks
 
tuple nstruct
 
tuple tasks_size
 
tuple input_packed_pose
 
tuple seeds
 
tuple decoy_ids
 
tuple client
 
tuple scheduler
 
tuple cores
 
tuple processes
 
tuple memory
 
tuple scratch_dir
 
tuple min_workers
 
tuple max_workers
 
tuple dashboard_address
 
tuple project_name
 
tuple simulation_name
 
tuple output_path
 
tuple scorefile_name
 
tuple scorefile_path
 
tuple simulation_records_in_scorefile
 
tuple decoy_dir_name
 
tuple decoy_path
 
tuple logs_dir_name
 
tuple logs_path
 
tuple logging_level
 
tuple logging_file
 
tuple compressed
 
tuple sha1
 
tuple ignore_errors
 
tuple timeout
 
tuple save_all
 
tuple dry_run
 
tuple protocols_key
 
tuple system_info
 
tuple pyrosetta_build
 
tuple environment
 
tuple environment_file
 
- Static Public Attributes inherited from pyrosetta.distributed.cluster.io.IO
tuple instance_state = dict(zip(self.__slots__, self.__getstate__()))
 
tuple instance_kwargs = copy.deepcopy(instance_state)
 
list out = [cls._format_result(results)]
 
- Static Public Attributes inherited from pyrosetta.distributed.cluster.base.TaskBase
tuple protocol = protocols.pop(0)
 
tuple seed = self._get_seed(protocols)
 
tuple kwargs = self._setup_seed(kwargs, seed)
 
string jran = f" -run:constant_seed 1 -run:jran {seed}"
 
string split_str = " -run:constant_seed 1 -run:jran "
 
tuple flags = pyrosetta.distributed._normflags(kwargs["extra_options"])
 

Additional Inherited Members

- Public Attributes inherited from pyrosetta.distributed.cluster.utilities.SchedulerManager
 scheduler
 

Member Function Documentation

def pyrosetta.distributed.cluster.core.PyRosettaCluster.__attrs_post_init__ (   self)
def pyrosetta.distributed.cluster.core.PyRosettaCluster.distribute (   self,
  args 
)

Member Data Documentation

tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.client
static
tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.compressed
static
Initial value:
1 = attr.ib(
2  type=bool,
3  default=True,
4  validator=attr.validators.instance_of(bool),
5  converter=attr.converters.default_if_none(default=True),
6  )

Referenced by pyrosetta.distributed.cluster.io.IO._save_results().

tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.cores
static
Initial value:
1 = attr.ib(
2  type=int,
3  default=1,
4  validator=[_validate_int, attr.validators.instance_of(int)],
5  converter=attr.converters.default_if_none(default=1),
6  )
tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.dashboard_address
static
Initial value:
1 = attr.ib(
2  type=str,
3  default=":8787",
4  validator=attr.validators.instance_of(str),
5  converter=attr.converters.default_if_none(default=":8787"),
6  )

Referenced by pyrosetta.distributed.cluster.utilities.SchedulerManager._get_cluster().

tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.decoy_dir_name
static
Initial value:
1 = attr.ib(
2  type=str,
3  default="decoys",
4  validator=attr.validators.instance_of(str),
5  converter=attr.converters.default_if_none(default="decoys"),
6  )
tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.decoy_ids
static
Initial value:
1 = attr.ib(
2  type=list,
3  default=None,
4  validator=attr.validators.optional(attr.validators.instance_of(list)),
5  converter=attr.converters.optional(_parse_decoy_ids),
6  )

Referenced by pyrosetta.distributed.cluster.core.PyRosettaCluster.distribute().

tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.decoy_path
static
Initial value:
1 = attr.ib(
2  type=str,
3  default=attr.Factory(
4  lambda self: os.path.abspath(
5  os.path.join(self.output_path, self.decoy_dir_name)
6  ),
7  takes_self=True,
8  ),
9  init=False,
10  validator=attr.validators.instance_of(str),
11  )

Referenced by pyrosetta.distributed.cluster.io.IO._save_results().

tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.dry_run
static
Initial value:
1 = attr.ib(
2  type=bool,
3  default=False,
4  validator=attr.validators.instance_of(bool),
5  converter=attr.converters.default_if_none(False),
6  )

Referenced by pyrosetta.distributed.cluster.io.IO._save_results(), and pyrosetta.distributed.cluster.io.IO._write_environment_file().

tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.environment
static
Initial value:
1 = attr.ib(
2  type=str,
3  default=None,
4  validator=attr.validators.instance_of(str),
5  converter=_parse_environment,
6  )

Referenced by pyrosetta.distributed.cluster.io.IO._write_environment_file().

tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.environment_file
static
Initial value:
1 = attr.ib(
2  type=str,
3  default=attr.Factory(
4  lambda self: os.path.join(
5  self.output_path,
6  "_".join(
7  [
8  self.project_name.replace(" ", "-"),
9  self.simulation_name.replace(" ", "-"),
10  "environment.yml",
11  ]
12  ),
13  ),
14  takes_self=True,
15  ),
16  init=False,
17  validator=attr.validators.instance_of(str),
18  )

Referenced by pyrosetta.distributed.cluster.core.PyRosettaCluster.__attrs_post_init__(), and pyrosetta.distributed.cluster.io.IO._save_results().

tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.ignore_errors
static
Initial value:
1 = attr.ib(
2  type=bool,
3  default=False,
4  validator=attr.validators.instance_of(bool),
5  converter=attr.converters.default_if_none(default=False),
6  )

Referenced by pyrosetta.distributed.cluster.core.PyRosettaCluster.distribute().

tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.input_packed_pose
static
Initial value:
1 = attr.ib(
2  type=PackedPose,
3  default=None,
4  validator=attr.validators.optional(attr.validators.instance_of(PackedPose)),
5  converter=_parse_input_packed_pose,
6  )

Referenced by pyrosetta.distributed.cluster.core.PyRosettaCluster.distribute().

tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.logging_file
static
Initial value:
1 = attr.ib(
2  type=str,
3  default=attr.Factory(
4  lambda self: os.path.join(
5  self.logs_path,
6  "_".join(
7  [
8  self.project_name.replace(" ", "-"),
9  self.simulation_name.replace(" ", "-") + ".log",
10  ]
11  ),
12  ),
13  takes_self=True,
14  ),
15  init=False,
16  validator=attr.validators.instance_of(str),
17  )

Referenced by pyrosetta.distributed.cluster.base.TaskBase._setup_initial_kwargs(), and pyrosetta.distributed.cluster.core.PyRosettaCluster.distribute().

tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.logging_level
static
Initial value:
1 = attr.ib(
2  type=str,
3  default="INFO",
4  validator=[
5  attr.validators.in_(
6  ["NOTSET", "DEBUG", "INFO", "WARNING", "ERROR", "CRITICAL"]
7  ),
8  attr.validators.instance_of(str),
9  ],
10  converter=attr.converters.default_if_none(default="NOTSET"),
11  )

Referenced by pyrosetta.distributed.cluster.logging_support.LoggingSupport._setup_logger(), and pyrosetta.distributed.cluster.core.PyRosettaCluster.distribute().

tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.logs_dir_name
static
Initial value:
1 = attr.ib(
2  type=str,
3  default="logs",
4  validator=attr.validators.instance_of(str),
5  converter=attr.converters.default_if_none(default="logs"),
6  )
tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.logs_path
static
Initial value:
1 = attr.ib(
2  type=str,
3  default=attr.Factory(
4  lambda self: os.path.abspath(
5  os.path.join(self.output_path, self.logs_dir_name)
6  ),
7  takes_self=True,
8  ),
9  init=False,
10  validator=attr.validators.instance_of(str),
11  )

Referenced by pyrosetta.distributed.cluster.logging_support.LoggingSupport._setup_logger().

tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.max_workers
static
Initial value:
1 = attr.ib(
2  type=int,
3  default=attr.Factory(
4  lambda self: 1000 if (self.tasks_size < 1000) else self.tasks_size,
5  takes_self=True,
6  ),
7  validator=[_validate_int, attr.validators.instance_of(int)],
8  converter=attr.converters.default_if_none(default=1000),
9  )

Referenced by pyrosetta.distributed.cluster.utilities.SchedulerManager._get_cluster(), pyrosetta.distributed.cluster.utilities.SchedulerManager._maybe_adapt(), and pyrosetta.distributed.cluster.utilities.SchedulerManager._setup_client_cluster_adaptive().

tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.memory
static
Initial value:
1 = attr.ib(
2  type=str,
3  default="4g",
4  validator=attr.validators.optional(attr.validators.instance_of(str)),
5  converter=attr.converters.default_if_none(default="4g"),
6  )
tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.min_workers
static
Initial value:
1 = attr.ib(
2  type=int,
3  default=1,
4  validator=[_validate_int, attr.validators.instance_of(int)],
5  converter=attr.converters.default_if_none(default=1),
6  )

Referenced by pyrosetta.distributed.cluster.utilities.SchedulerManager._setup_client_cluster_adaptive().

tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.nstruct
static
Initial value:
1 = attr.ib(
2  type=int,
3  default=1,
4  validator=[_validate_int, attr.validators.instance_of(int)],
5  converter=attr.converters.default_if_none(default=1),
6  )

Referenced by pyrosetta.distributed.cluster.core.PyRosettaCluster.distribute(), and pyrosetta.toolbox.py_jobdistributor.PyJobDistributor.output_decoy().

tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.output_path
static
Initial value:
1 = attr.ib(
2  type=str,
3  default=os.path.abspath(os.path.join(os.getcwd(), "outputs")),
4  validator=[_validate_dirs, attr.validators.instance_of(str)],
5  converter=attr.converters.default_if_none(
6  default=os.path.abspath(os.path.join(os.getcwd(), "outputs"))
7  ),
8  )
tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.processes
static
Initial value:
1 = attr.ib(
2  type=int,
3  default=1,
4  validator=[_validate_int, attr.validators.instance_of(int)],
5  converter=attr.converters.default_if_none(default=1),
6  )
tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.project_name
static
Initial value:
1 = attr.ib(
2  type=str,
3  default=datetime.now().strftime("%Y.%m.%d.%H.%M.%S.%f"),
4  validator=attr.validators.optional(attr.validators.instance_of(str)),
5  converter=attr.converters.default_if_none(default="PyRosettaCluster"),
6  )
tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.protocols_key
static
Initial value:
1 = attr.ib(
2  type=str,
3  default="PyRosettaCluster_protocols_container",
4  init=False,
5  validator=attr.validators.instance_of(str),
6  )

Referenced by pyrosetta.distributed.cluster.io.IO._process_kwargs(), pyrosetta.distributed.cluster.base.TaskBase._setup_initial_kwargs(), pyrosetta.distributed.cluster.base.TaskBase._setup_kwargs(), and pyrosetta.distributed.cluster.core.PyRosettaCluster.distribute().

tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.pyrosetta_build
static
Initial value:
1 = attr.ib(
2  type=str,
3  default=None,
4  validator=attr.validators.instance_of(str),
5  converter=_parse_pyrosetta_build,
6  )
tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.save_all
static
Initial value:
1 = attr.ib(
2  type=bool,
3  default=False,
4  validator=attr.validators.instance_of(bool),
5  converter=attr.converters.default_if_none(default=False),
6  )

Referenced by pyrosetta.distributed.cluster.core.PyRosettaCluster.distribute().

tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.scheduler
static
Initial value:
1 = attr.ib(
2  type=str,
3  default=None,
4  validator=attr.validators.optional(
5  [attr.validators.in_(["sge", "slurm"]), attr.validators.instance_of(str),],
6  ),
7  )

Referenced by pyrosetta.distributed.cluster.utilities.SchedulerManager._get_cluster(), pyrosetta.distributed.cluster.utilities.SchedulerManager._maybe_adapt(), and pyrosetta.distributed.cluster.utilities.SchedulerManager._setup_client_cluster_adaptive().

tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.scorefile_name
static
Initial value:
1 = attr.ib(
2  type=str,
3  default="scores.json",
4  validator=attr.validators.instance_of(str),
5  converter=attr.converters.default_if_none(default="scores.json"),
6  )
tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.scorefile_path
static
Initial value:
1 = attr.ib(
2  type=str,
3  default=attr.Factory(
4  lambda self: os.path.abspath(
5  os.path.join(self.output_path, self.scorefile_name)
6  ),
7  takes_self=True,
8  ),
9  init=False,
10  validator=attr.validators.instance_of(str),
11  )

Referenced by pyrosetta.distributed.cluster.io.IO._save_results().

tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.scratch_dir
static
Initial value:
1 = attr.ib(
2  type=str,
3  default=None,
4  validator=[_validate_dir, attr.validators.instance_of(str)],
5  converter=_parse_scratch_dir,
6  )

Referenced by pyrosetta.distributed.cluster.utilities.SchedulerManager._get_cluster().

tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.seeds
static
Initial value:
1 = attr.ib(
2  type=list,
3  default=None,
4  validator=attr.validators.optional(attr.validators.instance_of(list)),
5  converter=attr.converters.optional(_parse_seeds),
6  )

Referenced by pyrosetta.distributed.cluster.base.TaskBase._get_seed().

tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.sha1
static
Initial value:
1 = attr.ib(
2  type=str,
3  default="",
4  validator=attr.validators.instance_of(str),
5  converter=_parse_sha1,
6  )
tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.simulation_name
static
Initial value:
1 = attr.ib(
2  type=str,
3  default=attr.Factory(lambda self: self.project_name, takes_self=True),
4  validator=attr.validators.instance_of(str),
5  converter=attr.converters.default_if_none(default="PyRosettaCluster"),
6  )

Referenced by pyrosetta.distributed.cluster.io.IO._save_results().

tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.simulation_records_in_scorefile
static
Initial value:
1 = attr.ib(
2  type=bool,
3  default=False,
4  validator=attr.validators.instance_of(bool),
5  converter=attr.converters.default_if_none(default=False),
6  )

Referenced by pyrosetta.distributed.cluster.io.IO._save_results(), and pyrosetta.distributed.cluster.io.IO._write_environment_file().

tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.system_info
static
Initial value:
1 = attr.ib(
2  type=dict,
3  default=None,
4  validator=attr.validators.instance_of(dict),
5  converter=_parse_system_info,
6  )
tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.tasks
static
Initial value:
1 = attr.ib(
2  type=list,
3  default=[{}],
4  validator=attr.validators.deep_iterable(
5  member_validator=attr.validators.instance_of(dict),
6  iterable_validator=attr.validators.instance_of(list),
7  ),
8  converter=_parse_tasks,
9  )

Referenced by pyrosetta.distributed.cluster.core.PyRosettaCluster.distribute().

tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.tasks_size
static
Initial value:
1 = attr.ib(
2  type=int,
3  default=attr.Factory(
4  lambda self: toolz.itertoolz.count(self.tasks) * self.nstruct,
5  takes_self=True,
6  ),
7  init=False,
8  validator=attr.validators.instance_of(int),
9  )

Referenced by pyrosetta.distributed.cluster.utilities.SchedulerManager._maybe_adapt(), and pyrosetta.distributed.cluster.core.PyRosettaCluster.distribute().

tuple pyrosetta.distributed.cluster.core.PyRosettaCluster.timeout
static
Initial value:
1 = attr.ib(
2  type=float,
3  default=0.5,
4  validator=[_validate_float, attr.validators.instance_of((float, int))],
5  converter=attr.converters.default_if_none(default=0.5),
6  )

Referenced by pyrosetta.distributed.cluster.core.PyRosettaCluster.distribute().


The documentation for this class was generated from the following file: