Objective Class

  • java.lang.Object
    • com.azure.resourcemanager.machinelearning.models.Objective

Implements

public final class Objective
implements JsonSerializable<Objective>

Optimization objective.

Constructor Summary

Constructor Description
Objective()

Creates an instance of Objective class.

Method Summary

Modifier and Type Method and Description
static Objective fromJson(JsonReader jsonReader)

Reads an instance of Objective from the JsonReader.

Goal goal()

Get the goal property: [Required] Defines supported metric goals for hyperparameter tuning.

String primaryMetric()

Get the primaryMetric property: [Required] Name of the metric to optimize.

JsonWriter toJson(JsonWriter jsonWriter)
void validate()

Validates the instance.

Objective withGoal(Goal goal)

Set the goal property: [Required] Defines supported metric goals for hyperparameter tuning.

Objective withPrimaryMetric(String primaryMetric)

Set the primaryMetric property: [Required] Name of the metric to optimize.

Methods inherited from java.lang.Object

Constructor Details

Objective

public Objective()

Creates an instance of Objective class.

Method Details

fromJson

public static Objective fromJson(JsonReader jsonReader)

Reads an instance of Objective from the JsonReader.

Parameters:

jsonReader - The JsonReader being read.

Returns:

An instance of Objective if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.

Throws:

IOException

- If the deserialized JSON object was missing any required properties.

goal

public Goal goal()

Get the goal property: [Required] Defines supported metric goals for hyperparameter tuning.

Returns:

the goal value.

primaryMetric

public String primaryMetric()

Get the primaryMetric property: [Required] Name of the metric to optimize.

Returns:

the primaryMetric value.

toJson

public JsonWriter toJson(JsonWriter jsonWriter)

Parameters:

jsonWriter

Throws:

validate

public void validate()

Validates the instance.

withGoal

public Objective withGoal(Goal goal)

Set the goal property: [Required] Defines supported metric goals for hyperparameter tuning.

Parameters:

goal - the goal value to set.

Returns:

the Objective object itself.

withPrimaryMetric

public Objective withPrimaryMetric(String primaryMetric)

Set the primaryMetric property: [Required] Name of the metric to optimize.

Parameters:

primaryMetric - the primaryMetric value to set.

Returns:

the Objective object itself.

Applies to