Ejemplo n.º 1
0
def _get_process_url_schema():
    return OP.to_option_schema(
        _to_wopt_id("progress_status_url"),
        ("string", "null"),
        "Status Progress URL",
        "Post status progress updates to URL.",
        None,
    )
Ejemplo n.º 2
0
def _get_exit_on_failure():
    return OP.to_option_schema(
        _to_wopt_id("debug_mode"),
        "boolean",
        "Enable Debug Mode",
        "Debug will emit debug messages to Stdout and set the level in the master log to DEBUG.",
        GlobalConstants.DEBUG_MODE,
    )
Ejemplo n.º 3
0
def _to_max_nproc_option():
    return OP.to_option_schema(
        _to_wopt_id("max_total_nproc"),
        ("integer", "null"),
        "Maximum Total Number of Processors",
        "Maximum Total number of Processors/Slots the workflow engine will use (null means there is no limit).",
        GlobalConstants.MAX_TOTAL_NPROC,
    )
Ejemplo n.º 4
0
def _to_max_nproc_option():
    return OP.to_option_schema(
        _to_wopt_id("max_nproc"),
        "integer",
        "Maximum Total Number of Processors Per Task",
        "Maximum number of Processors per Task.",
        GlobalConstants.MAX_NPROC,
    )
Ejemplo n.º 5
0
def _get_workflow_option_schema():
    return OP.to_option_schema(
        _to_wopt_id("max_nworkers"),
        "integer",
        "Max Number of Workers",
        "Max Number of concurrently running tasks. (Note:  max_nproc will restrict the number of workers if max_nworkers * max_nproc > max_total_nproc)",
        GlobalConstants.MAX_NWORKERS,
    )
Ejemplo n.º 6
0
def _get_chunked_mode_schema():
    return OP.to_option_schema(
        _to_wopt_id("chunk_mode"),
        "boolean",
        "Chunked File Mode",
        "Enable file splitting (chunking) mode",
        GlobalConstants.CHUNKED_MODE,
    )
Ejemplo n.º 7
0
def _get_distributed_mode_schema():
    return OP.to_option_schema(
        _to_wopt_id("distributed_mode"),
        "boolean",
        "Distributed File Mode",
        "Enable Distributed mode to submit jobs to the cluster. (Must provide 'cluster_manager' path to cluster templates)",
        GlobalConstants.DISTRIBUTED_MODE,
    )
Ejemplo n.º 8
0
def _to_max_chunks_option():
    return OP.to_option_schema(
        _to_wopt_id("max_nchunks"),
        "integer",
        "Max Number of Chunks",
        "Max Number of chunks that a file will be scattered into",
        GlobalConstants.MAX_NCHUNKS,
    )
Ejemplo n.º 9
0
def _get_exit_on_failure():
    return OP.to_option_schema(
        _to_wopt_id("exit_on_failure"),
        "boolean",
        "Exit On Failure",
        "Immediately exit if a task fails (Instead of trying to run as many tasks as possible before exiting.)",
        GlobalConstants.EXIT_ON_FAILIURE,
    )
Ejemplo n.º 10
0
def _get_cluster_manager_schema():
    return OP.to_option_schema(
        _to_wopt_id("cluster_manager"),
        ("string", "null"),
        "Cluster Template Path",
        "Path to Cluster template files directory. The directory must contain 'start.tmpl', and 'stop.tmpl'"
        "Or the path can be provided to a python module (e.g., 'pbsmrtpipe.cluster_templates.sge')",
        "pbsmrtpipe.cluster_templates.sge_pacbio",
    )
Ejemplo n.º 11
0
def _get_node_tmp_dir_schema():
    return OP.to_option_schema(
        _to_wopt_id("tmp_dir"),
        ("string", "null"),
        "Temp directory",
        "Temporary directory (/tmp) on the execution node. If running in distributed mode, "
        "the tmp directory must be on the head node too.",
        GlobalConstants.TMP_DIR,
    )
Ejemplo n.º 12
0
def _get_simple_opts():
    # Util func to create an task option id 'pbsmrtpipe.task_options.dev.hello_message'
    oid = OP.to_opt_id('dev.hello_message')
    return {oid: OP.to_option_schema(oid, "string", 'Hello Message', "Hello Message for dev Task.", "Default Message")}
Ejemplo n.º 13
0
def _get_exit_on_failure():
    return OP.to_option_schema(_to_wopt_id("debug_mode"), "boolean", "Enable Debug Mode",
                               "Debug will emit debug messages to Stdout and set the level in the master log to DEBUG.", False)
import pbsmrtpipe.schema_opt_utils as OP
# generate a task option id
oid = OP.to_opt_id('dev.hello_message')
# generate a schema
s = OP.to_option_schema(oid, "string", 'Hello Message', "Hello Message for dev Task.", "Default Message")
print {oid: s}
Ejemplo n.º 15
0
def _get_workflow_option_schema():
    return OP.to_option_schema(
        _to_wopt_id("max_nworkers"), "integer", "Max Number of Workers",
        "Max Number of concurrently running tasks. (Note:  max_nproc will restrict the number of workers if max_nworkers * max_nproc > max_total_nproc)",
        GlobalConstants.MAX_NWORKERS)
Ejemplo n.º 16
0
def _get_chunked_mode_schema():
    return OP.to_option_schema(_to_wopt_id("chunk_mode"), "boolean",
                               "Chunked File Mode",
                               "Enable file splitting (chunking) mode",
                               GlobalConstants.CHUNKED_MODE)
Ejemplo n.º 17
0
def _get_distributed_mode_schema():
    return OP.to_option_schema(
        _to_wopt_id("distributed_mode"), "boolean", "Distributed File Mode",
        "Enable Distributed mode to submit jobs to the cluster. (Must provide 'cluster_manager' path to cluster templates)",
        GlobalConstants.DISTRIBUTED_MODE)
Ejemplo n.º 18
0
def _get_node_tmp_dir_schema():
    return OP.to_option_schema(
        _to_wopt_id("tmp_dir"), ("string", "null"), "Temp directory",
        "Temporary directory (/tmp) on the execution node. If running in distributed mode, "
        "the tmp directory must be on the head node too.",
        GlobalConstants.TMP_DIR)
Ejemplo n.º 19
0
def _to_max_nproc_option():
    return OP.to_option_schema(
        _to_wopt_id("max_total_nproc"), ("integer", "null"),
        "Maximum Total Number of Processors",
        "Maximum Total number of Processors/Slots the workflow engine will use (null means there is no limit).",
        GlobalConstants.MAX_TOTAL_NPROC)
Ejemplo n.º 20
0
def _get_chunked_mode_schema():
    return OP.to_option_schema(_to_wopt_id("chunk_mode"), "boolean",
                               "Chunked File Mode",
                               "Enable file splitting (chunking) mode", False)
Ejemplo n.º 21
0
def _get_exit_on_failure():
    return OP.to_option_schema(_to_wopt_id("exit_on_failure"), "boolean", "Exit On Failure",
                               "Immediately exit if a task fails (Instead of trying to run as many tasks as possible before exiting.", False)
Ejemplo n.º 22
0
def _get_exit_on_failure():
    return OP.to_option_schema(
        _to_wopt_id("exit_on_failure"), "boolean", "Exit On Failure",
        "Immediately exit if a task fails (Instead of trying to run as many tasks as possible before exiting.)",
        GlobalConstants.EXIT_ON_FAILIURE)
Ejemplo n.º 23
0
def _get_process_url_schema():
    return OP.to_option_schema(_to_wopt_id("progress_status_url"),
                               ("string", "null"), "Status Progress URL",
                               "Post status progress updates to URL.", None)
Ejemplo n.º 24
0
def _get_debug_model_option():
    return OP.to_option_schema(
        _to_wopt_id("debug_mode"), "boolean", "Enable Debug Mode",
        "Debug will emit debug messages to Stdout and set the level in the master log to DEBUG.",
        GlobalConstants.DEBUG_MODE)
Ejemplo n.º 25
0
def _get_cluster_manager_schema():
    return OP.to_option_schema(_to_wopt_id("cluster_manager"), ("string", "null"),
                               "Cluster Template Path",
                               "Path to Cluster template files directory. The directory must contain 'start.tmpl', 'interactive.tmpl' and 'kill.tmpl' "
                               "Or path to python module (e.g., 'pbsmrtpipe.cluster_templates.sge')", "pbsmrtpipe.cluster_templates.sge_pacbio")
Ejemplo n.º 26
0
def _to_max_chunks_option():
    return OP.to_option_schema(
        _to_wopt_id("max_nchunks"), "integer", "Max Number of Chunks",
        "Max Number of chunks that a file will be scattered into",
        GlobalConstants.MAX_NCHUNKS)
Ejemplo n.º 27
0
def _to_max_nproc_option():
    return OP.to_option_schema(_to_wopt_id("max_nproc"), "integer",
                               "Maximum Total Number of Processors Per Task",
                               "Maximum number of Processors per Task.",
                               GlobalConstants.MAX_NPROC)
Ejemplo n.º 28
0
def _get_opts():
    oid = OP.to_opt_id('dev.hello_message')
    return {oid: OP.to_option_schema(oid, "string", 'Hello Message', "Hello Message for dev Task.", "Default Message")}
Ejemplo n.º 29
0
def _to_max_chunks_option():
    return OP.to_option_schema(_to_wopt_id("max_nchunks"), "integer", "Max Number of Chunks",
                               "Max Number of chunks that a file will be scattered into", 10)