Skip to content

Module zoo_calrissian_runner

Sub-modules

Variables

zoo

Classes

ResourceRequirement

class ResourceRequirement(
    coresMin=None,
    coresMax=None,
    ramMin=None,
    ramMax=None,
    tmpdirMin=None,
    tmpdirMax=None,
    outdirMin=None,
    outdirMax=None
)

Class variables

coresMax
coresMin
outdirMax
outdirMin
ramMax
ramMin
tmpdirMax
tmpdirMin

Static methods

from_dict

def from_dict(
    env
)

Workflow

class Workflow(
    cwl,
    workflow_id
)

Static methods

get_resource_requirement

def get_resource_requirement(
    elem
)

Gets the ResourceRequirement out of a CommandLineTool or Workflow

Parameters:

Name Type Description Default
elem CommandLineTool or Workflow CommandLineTool or Workflow None

Returns:

Type Description
None cwl_utils.parser.cwl_v1_2.ResourceRequirement or ResourceRequirement

has_scatter_requirement

def has_scatter_requirement(
    workflow
)

Methods

eval_resource

def eval_resource(
    self
)

get_object_by_id

def get_object_by_id(
    self,
    id
)

get_workflow

def get_workflow(
    self
) -> cwl_utils.parser.cwl_v1_0.Workflow

get_workflow_inputs

def get_workflow_inputs(
    self,
    mandatory=False
)

ZooCalrissianRunner

class ZooCalrissianRunner(
    cwl,
    conf,
    inputs,
    outputs,
    execution_handler: Optional[zoo_calrissian_runner.handlers.ExecutionHandler] = None
)

Static methods

shorten_namespace

def shorten_namespace(
    value: str
) -> str

shortens the namespace to 63 characters

Methods

assert_parameters

def assert_parameters(
    self
)

checks all mandatory processing parameters were provided

execute

def execute(
    self
)

get_max_cores

def get_max_cores(
    self
) -> int

returns the maximum number of cores that pods can use

get_max_ram

def get_max_ram(
    self
) -> str

returns the maximum RAM that pods can use

get_namespace_name

def get_namespace_name(
    self
)

creates or returns the namespace

get_processing_parameters

def get_processing_parameters(
    self
)

Gets the processing parameters from the zoo inputs

get_volume_size

def get_volume_size(
    self
) -> str

returns volume size that the pods share

get_workflow_id

def get_workflow_id(
    self
)

returns the workflow id (CWL entry point)

get_workflow_inputs

def get_workflow_inputs(
    self,
    mandatory=False
)

Returns the CWL workflow inputs

update_status

def update_status(
    self,
    progress: int,
    message: str = None
) -> None

updates the execution progress (%) and provides an optional message

wrap

def wrap(
    self
)

ZooConf

class ZooConf(
    conf
)

ZooInputs

class ZooInputs(
    inputs
)

Methods

get_input_value

def get_input_value(
    self,
    key
)

get_processing_parameters

def get_processing_parameters(
    self
)

Returns a list with the input parameters keys

ZooOutputs

class ZooOutputs(
    outputs
)

Methods

get_output_parameters

def get_output_parameters(
    self
)

Returns a list with the output parameters keys

set_output

def set_output(
    self,
    value
)

set the output result value

ZooStub

class ZooStub(

)

Methods

update_status

def update_status(
    self,
    conf,
    progress
)