@Generated(value="com.amazonaws:aws-java-sdk-code-generator") public class MetricDefinition extends Object implements Serializable, Cloneable, StructuredPojo
Specifies a metric that the training algorithm writes to stderr
or stdout
. You can view
these logs to understand how your training job performs and check for any errors encountered during training.
SageMaker hyperparameter tuning captures all defined metrics. Specify one of the defined metrics to use as an
objective metric using the TuningObjective parameter in the HyperParameterTrainingJobDefinition
API to evaluate job
performance during hyperparameter tuning.
Constructor and Description |
---|
MetricDefinition() |
Modifier and Type | Method and Description |
---|---|
MetricDefinition |
clone() |
boolean |
equals(Object obj) |
String |
getName()
The name of the metric.
|
String |
getRegex()
A regular expression that searches the output of a training job and gets the value of the metric.
|
int |
hashCode() |
void |
marshall(ProtocolMarshaller protocolMarshaller)
Marshalls this structured data using the given
ProtocolMarshaller . |
void |
setName(String name)
The name of the metric.
|
void |
setRegex(String regex)
A regular expression that searches the output of a training job and gets the value of the metric.
|
String |
toString()
Returns a string representation of this object.
|
MetricDefinition |
withName(String name)
The name of the metric.
|
MetricDefinition |
withRegex(String regex)
A regular expression that searches the output of a training job and gets the value of the metric.
|
public void setName(String name)
The name of the metric.
name
- The name of the metric.public String getName()
The name of the metric.
public MetricDefinition withName(String name)
The name of the metric.
name
- The name of the metric.public void setRegex(String regex)
A regular expression that searches the output of a training job and gets the value of the metric. For more information about using regular expressions to define metrics, see Defining metrics and environment variables.
regex
- A regular expression that searches the output of a training job and gets the value of the metric. For more
information about using regular expressions to define metrics, see Defining metrics and environment variables.public String getRegex()
A regular expression that searches the output of a training job and gets the value of the metric. For more information about using regular expressions to define metrics, see Defining metrics and environment variables.
public MetricDefinition withRegex(String regex)
A regular expression that searches the output of a training job and gets the value of the metric. For more information about using regular expressions to define metrics, see Defining metrics and environment variables.
regex
- A regular expression that searches the output of a training job and gets the value of the metric. For more
information about using regular expressions to define metrics, see Defining metrics and environment variables.public String toString()
toString
in class Object
Object.toString()
public MetricDefinition clone()
public void marshall(ProtocolMarshaller protocolMarshaller)
StructuredPojo
ProtocolMarshaller
.marshall
in interface StructuredPojo
protocolMarshaller
- Implementation of ProtocolMarshaller
used to marshall this object's data.