Rule | R Documentation |
The SageMaker Debugger Rule class configures *debugging* rules to debug your training job. The debugging rules analyze tensor outputs from your training job and monitor conditions that are critical for the success of the training job. SageMaker Debugger comes pre-packaged with built-in *debugging* rules. For example, the debugging rules can detect whether gradients are getting too large or too small, or if a model is overfitting. For a full list of built-in rules for debugging, see 'List of Debugger Built-in Rules' https://docs.aws.amazon.com/sagemaker/latest/dg/debugger-built-in-rules.html. You can also write your own rules using the custom rule classmethod.
sagemaker.common::RuleBase
-> Rule
collection_configs
A list of :class:'~sagemaker.debugger.CollectionConfig
actions
Placeholder
new()
Configure the debugging rules using the following classmethods.
Rule$new( name = NULL, image_uri = NULL, instance_type = NULL, container_local_output_path = NULL, s3_output_path = NULL, volume_size_in_gb = NULL, rule_parameters = NULL, collections_to_save = NULL, actions = NULL )
name
(str): The name of the rule.
image_uri
(str): The image URI to use the rule.
instance_type
(str): Type of EC2 instance to use. For example, 'ml.c4.xlarge'.
container_local_output_path
(str): The local path to store the Rule output.
s3_output_path
(str): The location in S3 to store the output.
volume_size_in_gb
(int): Size in GB of the EBS volume to use for storing data.
rule_parameters
(dict): A dictionary of parameters for the rule.
collections_to_save
([sagemaker.debugger.CollectionConfig]): Optional. A list of :class:'~sagemaker.debugger.CollectionConfig' objects to be saved.
actions
:
sagemaker()
Initialize a “Rule“ object for a built-in
debugging rule.
Rule$sagemaker( base_config, name = NULL, container_local_output_path = NULL, s3_output_path = NULL, other_trials_s3_input_paths = NULL, rule_parameters = NULL, collections_to_save = NULL, actions = NULL )
base_config
(dict): Required. This is the base rule config dictionary returned from the
:class:sagemaker.debugger
method.
For example, sagemaker.debugger::dead_relu()
.
For a full list of built-in rules for debugging, see
'List of Debugger Built-in Rules'
https://docs.aws.amazon.com/sagemaker/latest/dg/debugger-built-in-rules.html.
name
(str): Optional. The name of the debugger rule. If one is not provided, the name of the base_config will be used.
container_local_output_path
(str): Optional. The local path in the rule processing container.
s3_output_path
(str): Optional. The location in Amazon S3 to store the output tensors. The default Debugger output path for debugging data is created under the default output path of the :class:'~sagemaker.estimator.Estimator' class. For example, s3://sagemaker-<region>-<12digit_account_id>/<training-job-name>/debug-output/.
other_trials_s3_input_paths
([str]): Optional. The Amazon S3 input paths of other trials to use the SimilarAcrossRuns rule.
rule_parameters
(dict): Optional. A dictionary of parameters for the rule.
collections_to_save
(:class:sagemaker.debugger::CollectionConfig
):
Optional. A list
of :class:sagemaker.debugger::CollectionConfig
objects to be saved.
actions
:
:class:'~sagemaker.debugger.Rule': An instance of the built-in rule.
custom()
Initialize a “Rule“ object for a *custom* debugging rule. You can create a custom rule that analyzes tensors emitted during the training of a model and monitors conditions that are critical for the success of a training job. For more information, see 'Create Debugger Custom Rules for Training Job Analysis' https://docs.aws.amazon.com/sagemaker/latest/dg/debugger-custom-rules.html.
Rule$custom( name, image_uri, instance_type, volume_size_in_gb, source = NULL, rule_to_invoke = NULL, container_local_output_path = NULL, s3_output_path = NULL, other_trials_s3_input_paths = NULL, rule_parameters = NULL, collections_to_save = NULL, actions = NULL )
name
(str): Required. The name of the debugger rule.
image_uri
(str): Required. The URI of the image to be used by the debugger rule.
instance_type
(str): Required. Type of EC2 instance to use, for example, 'ml.c4.xlarge'.
volume_size_in_gb
(int): Required. Size in GB of the EBS volume to use for storing data.
source
(str): Optional. A source file containing a rule to invoke. If provided, you must also provide rule_to_invoke. This can either be an S3 uri or a local path.
rule_to_invoke
(str): Optional. The name of the rule to invoke within the source. If provided, you must also provide source.
container_local_output_path
(str): Optional. The local path in the container.
s3_output_path
(str): Optional. The location in Amazon S3 to store the output tensors. The default Debugger output path for debugging data is created under the default output path of the :class:'~sagemaker.estimator.Estimator' class. For example, s3://sagemaker-<region>-<12digit_account_id>/<training-job-name>/debug-output/.
other_trials_s3_input_paths
([str]): Optional. The Amazon S3 input paths of other trials to use the SimilarAcrossRuns rule.
rule_parameters
(dict): Optional. A dictionary of parameters for the rule.
collections_to_save
([sagemaker.debugger.CollectionConfig]): Optional. A list of :class:'~sagemaker.debugger.CollectionConfig' objects to be saved.
actions
:
:class:'~sagemaker.debugger.Rule': The instance of the custom rule.
prepare_actions()
Prepare actions for Debugger Rule.
Rule$prepare_actions(training_job_name)
training_job_name
(str): The training job name. To be set as the default training job prefix for the StopTraining action if it is specified.
to_debugger_rule_config_list()
Generates a request dictionary using the parameters provided when initializing object.
Rule$to_debugger_rule_config_list()
dict: An portion of an API request as a dictionary.
clone()
The objects of this class are cloneable with this method.
Rule$clone(deep = FALSE)
deep
Whether to make a deep clone.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.