All Downloads are FREE. Search and download functionalities are using the official Maven repository.

software.amazon.awssdk.services.sagemaker.model.DescribeHyperParameterTuningJobResponse Maven / Gradle / Ivy

Go to download

The AWS Java SDK for Amazon SageMaker module holds the client classes that are used for communicating with Amazon SageMaker Service

There is a newer version: 2.28.4
Show newest version
/*
 * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
 * 
 * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance with
 * the License. A copy of the License is located at
 * 
 * http://aws.amazon.com/apache2.0
 * 
 * or in the "license" file accompanying this file. This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
 * CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions
 * and limitations under the License.
 */

package software.amazon.awssdk.services.sagemaker.model;

import java.time.Instant;
import java.util.Arrays;
import java.util.Collection;
import java.util.Collections;
import java.util.List;
import java.util.Objects;
import java.util.Optional;
import java.util.function.BiConsumer;
import java.util.function.Consumer;
import java.util.function.Function;
import java.util.stream.Collectors;
import java.util.stream.Stream;
import software.amazon.awssdk.annotations.Generated;
import software.amazon.awssdk.core.SdkField;
import software.amazon.awssdk.core.SdkPojo;
import software.amazon.awssdk.core.protocol.MarshallLocation;
import software.amazon.awssdk.core.protocol.MarshallingType;
import software.amazon.awssdk.core.traits.ListTrait;
import software.amazon.awssdk.core.traits.LocationTrait;
import software.amazon.awssdk.core.util.DefaultSdkAutoConstructList;
import software.amazon.awssdk.core.util.SdkAutoConstructList;
import software.amazon.awssdk.utils.ToString;
import software.amazon.awssdk.utils.builder.CopyableBuilder;
import software.amazon.awssdk.utils.builder.ToCopyableBuilder;

/**
 */
@Generated("software.amazon.awssdk:codegen")
public final class DescribeHyperParameterTuningJobResponse extends SageMakerResponse implements
        ToCopyableBuilder {
    private static final SdkField HYPER_PARAMETER_TUNING_JOB_NAME_FIELD = SdkField
            . builder(MarshallingType.STRING)
            .memberName("HyperParameterTuningJobName")
            .getter(getter(DescribeHyperParameterTuningJobResponse::hyperParameterTuningJobName))
            .setter(setter(Builder::hyperParameterTuningJobName))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("HyperParameterTuningJobName")
                    .build()).build();

    private static final SdkField HYPER_PARAMETER_TUNING_JOB_ARN_FIELD = SdkField
            . builder(MarshallingType.STRING)
            .memberName("HyperParameterTuningJobArn")
            .getter(getter(DescribeHyperParameterTuningJobResponse::hyperParameterTuningJobArn))
            .setter(setter(Builder::hyperParameterTuningJobArn))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("HyperParameterTuningJobArn").build())
            .build();

    private static final SdkField HYPER_PARAMETER_TUNING_JOB_CONFIG_FIELD = SdkField
            . builder(MarshallingType.SDK_POJO)
            .memberName("HyperParameterTuningJobConfig")
            .getter(getter(DescribeHyperParameterTuningJobResponse::hyperParameterTuningJobConfig))
            .setter(setter(Builder::hyperParameterTuningJobConfig))
            .constructor(HyperParameterTuningJobConfig::builder)
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("HyperParameterTuningJobConfig")
                    .build()).build();

    private static final SdkField TRAINING_JOB_DEFINITION_FIELD = SdkField
            . builder(MarshallingType.SDK_POJO).memberName("TrainingJobDefinition")
            .getter(getter(DescribeHyperParameterTuningJobResponse::trainingJobDefinition))
            .setter(setter(Builder::trainingJobDefinition)).constructor(HyperParameterTrainingJobDefinition::builder)
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("TrainingJobDefinition").build())
            .build();

    private static final SdkField> TRAINING_JOB_DEFINITIONS_FIELD = SdkField
            .> builder(MarshallingType.LIST)
            .memberName("TrainingJobDefinitions")
            .getter(getter(DescribeHyperParameterTuningJobResponse::trainingJobDefinitions))
            .setter(setter(Builder::trainingJobDefinitions))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("TrainingJobDefinitions").build(),
                    ListTrait
                            .builder()
                            .memberLocationName(null)
                            .memberFieldInfo(
                                    SdkField. builder(MarshallingType.SDK_POJO)
                                            .constructor(HyperParameterTrainingJobDefinition::builder)
                                            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD)
                                                    .locationName("member").build()).build()).build()).build();

    private static final SdkField HYPER_PARAMETER_TUNING_JOB_STATUS_FIELD = SdkField
            . builder(MarshallingType.STRING)
            .memberName("HyperParameterTuningJobStatus")
            .getter(getter(DescribeHyperParameterTuningJobResponse::hyperParameterTuningJobStatusAsString))
            .setter(setter(Builder::hyperParameterTuningJobStatus))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("HyperParameterTuningJobStatus")
                    .build()).build();

    private static final SdkField CREATION_TIME_FIELD = SdkField. builder(MarshallingType.INSTANT)
            .memberName("CreationTime").getter(getter(DescribeHyperParameterTuningJobResponse::creationTime))
            .setter(setter(Builder::creationTime))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("CreationTime").build()).build();

    private static final SdkField HYPER_PARAMETER_TUNING_END_TIME_FIELD = SdkField
            . builder(MarshallingType.INSTANT)
            .memberName("HyperParameterTuningEndTime")
            .getter(getter(DescribeHyperParameterTuningJobResponse::hyperParameterTuningEndTime))
            .setter(setter(Builder::hyperParameterTuningEndTime))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("HyperParameterTuningEndTime")
                    .build()).build();

    private static final SdkField LAST_MODIFIED_TIME_FIELD = SdkField. builder(MarshallingType.INSTANT)
            .memberName("LastModifiedTime").getter(getter(DescribeHyperParameterTuningJobResponse::lastModifiedTime))
            .setter(setter(Builder::lastModifiedTime))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("LastModifiedTime").build()).build();

    private static final SdkField TRAINING_JOB_STATUS_COUNTERS_FIELD = SdkField
            . builder(MarshallingType.SDK_POJO).memberName("TrainingJobStatusCounters")
            .getter(getter(DescribeHyperParameterTuningJobResponse::trainingJobStatusCounters))
            .setter(setter(Builder::trainingJobStatusCounters)).constructor(TrainingJobStatusCounters::builder)
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("TrainingJobStatusCounters").build())
            .build();

    private static final SdkField OBJECTIVE_STATUS_COUNTERS_FIELD = SdkField
            . builder(MarshallingType.SDK_POJO).memberName("ObjectiveStatusCounters")
            .getter(getter(DescribeHyperParameterTuningJobResponse::objectiveStatusCounters))
            .setter(setter(Builder::objectiveStatusCounters)).constructor(ObjectiveStatusCounters::builder)
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("ObjectiveStatusCounters").build())
            .build();

    private static final SdkField BEST_TRAINING_JOB_FIELD = SdkField
            . builder(MarshallingType.SDK_POJO).memberName("BestTrainingJob")
            .getter(getter(DescribeHyperParameterTuningJobResponse::bestTrainingJob)).setter(setter(Builder::bestTrainingJob))
            .constructor(HyperParameterTrainingJobSummary::builder)
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("BestTrainingJob").build()).build();

    private static final SdkField OVERALL_BEST_TRAINING_JOB_FIELD = SdkField
            . builder(MarshallingType.SDK_POJO).memberName("OverallBestTrainingJob")
            .getter(getter(DescribeHyperParameterTuningJobResponse::overallBestTrainingJob))
            .setter(setter(Builder::overallBestTrainingJob)).constructor(HyperParameterTrainingJobSummary::builder)
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("OverallBestTrainingJob").build())
            .build();

    private static final SdkField WARM_START_CONFIG_FIELD = SdkField
            . builder(MarshallingType.SDK_POJO).memberName("WarmStartConfig")
            .getter(getter(DescribeHyperParameterTuningJobResponse::warmStartConfig)).setter(setter(Builder::warmStartConfig))
            .constructor(HyperParameterTuningJobWarmStartConfig::builder)
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("WarmStartConfig").build()).build();

    private static final SdkField AUTOTUNE_FIELD = SdkField. builder(MarshallingType.SDK_POJO)
            .memberName("Autotune").getter(getter(DescribeHyperParameterTuningJobResponse::autotune))
            .setter(setter(Builder::autotune)).constructor(Autotune::builder)
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("Autotune").build()).build();

    private static final SdkField FAILURE_REASON_FIELD = SdkField. builder(MarshallingType.STRING)
            .memberName("FailureReason").getter(getter(DescribeHyperParameterTuningJobResponse::failureReason))
            .setter(setter(Builder::failureReason))
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("FailureReason").build()).build();

    private static final SdkField TUNING_JOB_COMPLETION_DETAILS_FIELD = SdkField
            . builder(MarshallingType.SDK_POJO)
            .memberName("TuningJobCompletionDetails")
            .getter(getter(DescribeHyperParameterTuningJobResponse::tuningJobCompletionDetails))
            .setter(setter(Builder::tuningJobCompletionDetails))
            .constructor(HyperParameterTuningJobCompletionDetails::builder)
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("TuningJobCompletionDetails").build())
            .build();

    private static final SdkField CONSUMED_RESOURCES_FIELD = SdkField
            . builder(MarshallingType.SDK_POJO).memberName("ConsumedResources")
            .getter(getter(DescribeHyperParameterTuningJobResponse::consumedResources))
            .setter(setter(Builder::consumedResources)).constructor(HyperParameterTuningJobConsumedResources::builder)
            .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("ConsumedResources").build()).build();

    private static final List> SDK_FIELDS = Collections.unmodifiableList(Arrays.asList(
            HYPER_PARAMETER_TUNING_JOB_NAME_FIELD, HYPER_PARAMETER_TUNING_JOB_ARN_FIELD, HYPER_PARAMETER_TUNING_JOB_CONFIG_FIELD,
            TRAINING_JOB_DEFINITION_FIELD, TRAINING_JOB_DEFINITIONS_FIELD, HYPER_PARAMETER_TUNING_JOB_STATUS_FIELD,
            CREATION_TIME_FIELD, HYPER_PARAMETER_TUNING_END_TIME_FIELD, LAST_MODIFIED_TIME_FIELD,
            TRAINING_JOB_STATUS_COUNTERS_FIELD, OBJECTIVE_STATUS_COUNTERS_FIELD, BEST_TRAINING_JOB_FIELD,
            OVERALL_BEST_TRAINING_JOB_FIELD, WARM_START_CONFIG_FIELD, AUTOTUNE_FIELD, FAILURE_REASON_FIELD,
            TUNING_JOB_COMPLETION_DETAILS_FIELD, CONSUMED_RESOURCES_FIELD));

    private final String hyperParameterTuningJobName;

    private final String hyperParameterTuningJobArn;

    private final HyperParameterTuningJobConfig hyperParameterTuningJobConfig;

    private final HyperParameterTrainingJobDefinition trainingJobDefinition;

    private final List trainingJobDefinitions;

    private final String hyperParameterTuningJobStatus;

    private final Instant creationTime;

    private final Instant hyperParameterTuningEndTime;

    private final Instant lastModifiedTime;

    private final TrainingJobStatusCounters trainingJobStatusCounters;

    private final ObjectiveStatusCounters objectiveStatusCounters;

    private final HyperParameterTrainingJobSummary bestTrainingJob;

    private final HyperParameterTrainingJobSummary overallBestTrainingJob;

    private final HyperParameterTuningJobWarmStartConfig warmStartConfig;

    private final Autotune autotune;

    private final String failureReason;

    private final HyperParameterTuningJobCompletionDetails tuningJobCompletionDetails;

    private final HyperParameterTuningJobConsumedResources consumedResources;

    private DescribeHyperParameterTuningJobResponse(BuilderImpl builder) {
        super(builder);
        this.hyperParameterTuningJobName = builder.hyperParameterTuningJobName;
        this.hyperParameterTuningJobArn = builder.hyperParameterTuningJobArn;
        this.hyperParameterTuningJobConfig = builder.hyperParameterTuningJobConfig;
        this.trainingJobDefinition = builder.trainingJobDefinition;
        this.trainingJobDefinitions = builder.trainingJobDefinitions;
        this.hyperParameterTuningJobStatus = builder.hyperParameterTuningJobStatus;
        this.creationTime = builder.creationTime;
        this.hyperParameterTuningEndTime = builder.hyperParameterTuningEndTime;
        this.lastModifiedTime = builder.lastModifiedTime;
        this.trainingJobStatusCounters = builder.trainingJobStatusCounters;
        this.objectiveStatusCounters = builder.objectiveStatusCounters;
        this.bestTrainingJob = builder.bestTrainingJob;
        this.overallBestTrainingJob = builder.overallBestTrainingJob;
        this.warmStartConfig = builder.warmStartConfig;
        this.autotune = builder.autotune;
        this.failureReason = builder.failureReason;
        this.tuningJobCompletionDetails = builder.tuningJobCompletionDetails;
        this.consumedResources = builder.consumedResources;
    }

    /**
     * 

* The name of the hyperparameter tuning job. *

* * @return The name of the hyperparameter tuning job. */ public final String hyperParameterTuningJobName() { return hyperParameterTuningJobName; } /** *

* The Amazon Resource Name (ARN) of the tuning job. *

* * @return The Amazon Resource Name (ARN) of the tuning job. */ public final String hyperParameterTuningJobArn() { return hyperParameterTuningJobArn; } /** *

* The * HyperParameterTuningJobConfig object that specifies the configuration of the tuning job. *

* * @return The HyperParameterTuningJobConfig object that specifies the configuration of the tuning job. */ public final HyperParameterTuningJobConfig hyperParameterTuningJobConfig() { return hyperParameterTuningJobConfig; } /** *

* The HyperParameterTrainingJobDefinition object that specifies the definition of the training jobs that this * tuning job launches. *

* * @return The HyperParameterTrainingJobDefinition object that specifies the definition of the training jobs that * this tuning job launches. */ public final HyperParameterTrainingJobDefinition trainingJobDefinition() { return trainingJobDefinition; } /** * For responses, this returns true if the service returned a value for the TrainingJobDefinitions property. This * DOES NOT check that the value is non-empty (for which, you should check the {@code isEmpty()} method on the * property). This is useful because the SDK will never return a null collection or map, but you may need to * differentiate between the service returning nothing (or null) and the service returning an empty collection or * map. For requests, this returns true if a value for the property was specified in the request builder, and false * if a value was not specified. */ public final boolean hasTrainingJobDefinitions() { return trainingJobDefinitions != null && !(trainingJobDefinitions instanceof SdkAutoConstructList); } /** *

* A list of the HyperParameterTrainingJobDefinition objects launched for this tuning job. *

*

* Attempts to modify the collection returned by this method will result in an UnsupportedOperationException. *

*

* This method will never return null. If you would like to know whether the service returned this field (so that * you can differentiate between null and empty), you can use the {@link #hasTrainingJobDefinitions} method. *

* * @return A list of the HyperParameterTrainingJobDefinition objects launched for this tuning job. */ public final List trainingJobDefinitions() { return trainingJobDefinitions; } /** *

* The status of the tuning job. *

*

* If the service returns an enum value that is not available in the current SDK version, * {@link #hyperParameterTuningJobStatus} will return {@link HyperParameterTuningJobStatus#UNKNOWN_TO_SDK_VERSION}. * The raw value returned by the service is available from {@link #hyperParameterTuningJobStatusAsString}. *

* * @return The status of the tuning job. * @see HyperParameterTuningJobStatus */ public final HyperParameterTuningJobStatus hyperParameterTuningJobStatus() { return HyperParameterTuningJobStatus.fromValue(hyperParameterTuningJobStatus); } /** *

* The status of the tuning job. *

*

* If the service returns an enum value that is not available in the current SDK version, * {@link #hyperParameterTuningJobStatus} will return {@link HyperParameterTuningJobStatus#UNKNOWN_TO_SDK_VERSION}. * The raw value returned by the service is available from {@link #hyperParameterTuningJobStatusAsString}. *

* * @return The status of the tuning job. * @see HyperParameterTuningJobStatus */ public final String hyperParameterTuningJobStatusAsString() { return hyperParameterTuningJobStatus; } /** *

* The date and time that the tuning job started. *

* * @return The date and time that the tuning job started. */ public final Instant creationTime() { return creationTime; } /** *

* The date and time that the tuning job ended. *

* * @return The date and time that the tuning job ended. */ public final Instant hyperParameterTuningEndTime() { return hyperParameterTuningEndTime; } /** *

* The date and time that the status of the tuning job was modified. *

* * @return The date and time that the status of the tuning job was modified. */ public final Instant lastModifiedTime() { return lastModifiedTime; } /** *

* The * TrainingJobStatusCounters object that specifies the number of training jobs, categorized by status, that this * tuning job launched. *

* * @return The TrainingJobStatusCounters object that specifies the number of training jobs, categorized by status, * that this tuning job launched. */ public final TrainingJobStatusCounters trainingJobStatusCounters() { return trainingJobStatusCounters; } /** *

* The * ObjectiveStatusCounters object that specifies the number of training jobs, categorized by the status of their * final objective metric, that this tuning job launched. *

* * @return The * ObjectiveStatusCounters object that specifies the number of training jobs, categorized by the status * of their final objective metric, that this tuning job launched. */ public final ObjectiveStatusCounters objectiveStatusCounters() { return objectiveStatusCounters; } /** *

* A TrainingJobSummary * object that describes the training job that completed with the best current HyperParameterTuningJobObjective. *

* * @return A TrainingJobSummary * object that describes the training job that completed with the best current HyperParameterTuningJobObjective. */ public final HyperParameterTrainingJobSummary bestTrainingJob() { return bestTrainingJob; } /** *

* If the hyperparameter tuning job is an warm start tuning job with a WarmStartType of * IDENTICAL_DATA_AND_ALGORITHM, this is the TrainingJobSummary for the training job with the best objective metric value of all training jobs launched * by this tuning job and all parent jobs specified for the warm start tuning job. *

* * @return If the hyperparameter tuning job is an warm start tuning job with a WarmStartType of * IDENTICAL_DATA_AND_ALGORITHM, this is the TrainingJobSummary for the training job with the best objective metric value of all training jobs * launched by this tuning job and all parent jobs specified for the warm start tuning job. */ public final HyperParameterTrainingJobSummary overallBestTrainingJob() { return overallBestTrainingJob; } /** *

* The configuration for starting the hyperparameter parameter tuning job using one or more previous tuning jobs as * a starting point. The results of previous tuning jobs are used to inform which combinations of hyperparameters to * search over in the new tuning job. *

* * @return The configuration for starting the hyperparameter parameter tuning job using one or more previous tuning * jobs as a starting point. The results of previous tuning jobs are used to inform which combinations of * hyperparameters to search over in the new tuning job. */ public final HyperParameterTuningJobWarmStartConfig warmStartConfig() { return warmStartConfig; } /** *

* A flag to indicate if autotune is enabled for the hyperparameter tuning job. *

* * @return A flag to indicate if autotune is enabled for the hyperparameter tuning job. */ public final Autotune autotune() { return autotune; } /** *

* If the tuning job failed, the reason it failed. *

* * @return If the tuning job failed, the reason it failed. */ public final String failureReason() { return failureReason; } /** *

* Tuning job completion information returned as the response from a hyperparameter tuning job. This information * tells if your tuning job has or has not converged. It also includes the number of training jobs that have not * improved model performance as evaluated against the objective function. *

* * @return Tuning job completion information returned as the response from a hyperparameter tuning job. This * information tells if your tuning job has or has not converged. It also includes the number of training * jobs that have not improved model performance as evaluated against the objective function. */ public final HyperParameterTuningJobCompletionDetails tuningJobCompletionDetails() { return tuningJobCompletionDetails; } /** * Returns the value of the ConsumedResources property for this object. * * @return The value of the ConsumedResources property for this object. */ public final HyperParameterTuningJobConsumedResources consumedResources() { return consumedResources; } @Override public Builder toBuilder() { return new BuilderImpl(this); } public static Builder builder() { return new BuilderImpl(); } public static Class serializableBuilderClass() { return BuilderImpl.class; } @Override public final int hashCode() { int hashCode = 1; hashCode = 31 * hashCode + super.hashCode(); hashCode = 31 * hashCode + Objects.hashCode(hyperParameterTuningJobName()); hashCode = 31 * hashCode + Objects.hashCode(hyperParameterTuningJobArn()); hashCode = 31 * hashCode + Objects.hashCode(hyperParameterTuningJobConfig()); hashCode = 31 * hashCode + Objects.hashCode(trainingJobDefinition()); hashCode = 31 * hashCode + Objects.hashCode(hasTrainingJobDefinitions() ? trainingJobDefinitions() : null); hashCode = 31 * hashCode + Objects.hashCode(hyperParameterTuningJobStatusAsString()); hashCode = 31 * hashCode + Objects.hashCode(creationTime()); hashCode = 31 * hashCode + Objects.hashCode(hyperParameterTuningEndTime()); hashCode = 31 * hashCode + Objects.hashCode(lastModifiedTime()); hashCode = 31 * hashCode + Objects.hashCode(trainingJobStatusCounters()); hashCode = 31 * hashCode + Objects.hashCode(objectiveStatusCounters()); hashCode = 31 * hashCode + Objects.hashCode(bestTrainingJob()); hashCode = 31 * hashCode + Objects.hashCode(overallBestTrainingJob()); hashCode = 31 * hashCode + Objects.hashCode(warmStartConfig()); hashCode = 31 * hashCode + Objects.hashCode(autotune()); hashCode = 31 * hashCode + Objects.hashCode(failureReason()); hashCode = 31 * hashCode + Objects.hashCode(tuningJobCompletionDetails()); hashCode = 31 * hashCode + Objects.hashCode(consumedResources()); return hashCode; } @Override public final boolean equals(Object obj) { return super.equals(obj) && equalsBySdkFields(obj); } @Override public final boolean equalsBySdkFields(Object obj) { if (this == obj) { return true; } if (obj == null) { return false; } if (!(obj instanceof DescribeHyperParameterTuningJobResponse)) { return false; } DescribeHyperParameterTuningJobResponse other = (DescribeHyperParameterTuningJobResponse) obj; return Objects.equals(hyperParameterTuningJobName(), other.hyperParameterTuningJobName()) && Objects.equals(hyperParameterTuningJobArn(), other.hyperParameterTuningJobArn()) && Objects.equals(hyperParameterTuningJobConfig(), other.hyperParameterTuningJobConfig()) && Objects.equals(trainingJobDefinition(), other.trainingJobDefinition()) && hasTrainingJobDefinitions() == other.hasTrainingJobDefinitions() && Objects.equals(trainingJobDefinitions(), other.trainingJobDefinitions()) && Objects.equals(hyperParameterTuningJobStatusAsString(), other.hyperParameterTuningJobStatusAsString()) && Objects.equals(creationTime(), other.creationTime()) && Objects.equals(hyperParameterTuningEndTime(), other.hyperParameterTuningEndTime()) && Objects.equals(lastModifiedTime(), other.lastModifiedTime()) && Objects.equals(trainingJobStatusCounters(), other.trainingJobStatusCounters()) && Objects.equals(objectiveStatusCounters(), other.objectiveStatusCounters()) && Objects.equals(bestTrainingJob(), other.bestTrainingJob()) && Objects.equals(overallBestTrainingJob(), other.overallBestTrainingJob()) && Objects.equals(warmStartConfig(), other.warmStartConfig()) && Objects.equals(autotune(), other.autotune()) && Objects.equals(failureReason(), other.failureReason()) && Objects.equals(tuningJobCompletionDetails(), other.tuningJobCompletionDetails()) && Objects.equals(consumedResources(), other.consumedResources()); } /** * Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be * redacted from this string using a placeholder value. */ @Override public final String toString() { return ToString.builder("DescribeHyperParameterTuningJobResponse") .add("HyperParameterTuningJobName", hyperParameterTuningJobName()) .add("HyperParameterTuningJobArn", hyperParameterTuningJobArn()) .add("HyperParameterTuningJobConfig", hyperParameterTuningJobConfig()) .add("TrainingJobDefinition", trainingJobDefinition()) .add("TrainingJobDefinitions", hasTrainingJobDefinitions() ? trainingJobDefinitions() : null) .add("HyperParameterTuningJobStatus", hyperParameterTuningJobStatusAsString()) .add("CreationTime", creationTime()).add("HyperParameterTuningEndTime", hyperParameterTuningEndTime()) .add("LastModifiedTime", lastModifiedTime()).add("TrainingJobStatusCounters", trainingJobStatusCounters()) .add("ObjectiveStatusCounters", objectiveStatusCounters()).add("BestTrainingJob", bestTrainingJob()) .add("OverallBestTrainingJob", overallBestTrainingJob()).add("WarmStartConfig", warmStartConfig()) .add("Autotune", autotune()).add("FailureReason", failureReason()) .add("TuningJobCompletionDetails", tuningJobCompletionDetails()).add("ConsumedResources", consumedResources()) .build(); } public final Optional getValueForField(String fieldName, Class clazz) { switch (fieldName) { case "HyperParameterTuningJobName": return Optional.ofNullable(clazz.cast(hyperParameterTuningJobName())); case "HyperParameterTuningJobArn": return Optional.ofNullable(clazz.cast(hyperParameterTuningJobArn())); case "HyperParameterTuningJobConfig": return Optional.ofNullable(clazz.cast(hyperParameterTuningJobConfig())); case "TrainingJobDefinition": return Optional.ofNullable(clazz.cast(trainingJobDefinition())); case "TrainingJobDefinitions": return Optional.ofNullable(clazz.cast(trainingJobDefinitions())); case "HyperParameterTuningJobStatus": return Optional.ofNullable(clazz.cast(hyperParameterTuningJobStatusAsString())); case "CreationTime": return Optional.ofNullable(clazz.cast(creationTime())); case "HyperParameterTuningEndTime": return Optional.ofNullable(clazz.cast(hyperParameterTuningEndTime())); case "LastModifiedTime": return Optional.ofNullable(clazz.cast(lastModifiedTime())); case "TrainingJobStatusCounters": return Optional.ofNullable(clazz.cast(trainingJobStatusCounters())); case "ObjectiveStatusCounters": return Optional.ofNullable(clazz.cast(objectiveStatusCounters())); case "BestTrainingJob": return Optional.ofNullable(clazz.cast(bestTrainingJob())); case "OverallBestTrainingJob": return Optional.ofNullable(clazz.cast(overallBestTrainingJob())); case "WarmStartConfig": return Optional.ofNullable(clazz.cast(warmStartConfig())); case "Autotune": return Optional.ofNullable(clazz.cast(autotune())); case "FailureReason": return Optional.ofNullable(clazz.cast(failureReason())); case "TuningJobCompletionDetails": return Optional.ofNullable(clazz.cast(tuningJobCompletionDetails())); case "ConsumedResources": return Optional.ofNullable(clazz.cast(consumedResources())); default: return Optional.empty(); } } @Override public final List> sdkFields() { return SDK_FIELDS; } private static Function getter(Function g) { return obj -> g.apply((DescribeHyperParameterTuningJobResponse) obj); } private static BiConsumer setter(BiConsumer s) { return (obj, val) -> s.accept((Builder) obj, val); } public interface Builder extends SageMakerResponse.Builder, SdkPojo, CopyableBuilder { /** *

* The name of the hyperparameter tuning job. *

* * @param hyperParameterTuningJobName * The name of the hyperparameter tuning job. * @return Returns a reference to this object so that method calls can be chained together. */ Builder hyperParameterTuningJobName(String hyperParameterTuningJobName); /** *

* The Amazon Resource Name (ARN) of the tuning job. *

* * @param hyperParameterTuningJobArn * The Amazon Resource Name (ARN) of the tuning job. * @return Returns a reference to this object so that method calls can be chained together. */ Builder hyperParameterTuningJobArn(String hyperParameterTuningJobArn); /** *

* The HyperParameterTuningJobConfig object that specifies the configuration of the tuning job. *

* * @param hyperParameterTuningJobConfig * The HyperParameterTuningJobConfig object that specifies the configuration of the tuning job. * @return Returns a reference to this object so that method calls can be chained together. */ Builder hyperParameterTuningJobConfig(HyperParameterTuningJobConfig hyperParameterTuningJobConfig); /** *

* The HyperParameterTuningJobConfig object that specifies the configuration of the tuning job. *

* This is a convenience method that creates an instance of the {@link HyperParameterTuningJobConfig.Builder} * avoiding the need to create one manually via {@link HyperParameterTuningJobConfig#builder()}. * *

* When the {@link Consumer} completes, {@link HyperParameterTuningJobConfig.Builder#build()} is called * immediately and its result is passed to {@link #hyperParameterTuningJobConfig(HyperParameterTuningJobConfig)}. * * @param hyperParameterTuningJobConfig * a consumer that will call methods on {@link HyperParameterTuningJobConfig.Builder} * @return Returns a reference to this object so that method calls can be chained together. * @see #hyperParameterTuningJobConfig(HyperParameterTuningJobConfig) */ default Builder hyperParameterTuningJobConfig( Consumer hyperParameterTuningJobConfig) { return hyperParameterTuningJobConfig(HyperParameterTuningJobConfig.builder() .applyMutation(hyperParameterTuningJobConfig).build()); } /** *

* The HyperParameterTrainingJobDefinition object that specifies the definition of the training jobs that this * tuning job launches. *

* * @param trainingJobDefinition * The HyperParameterTrainingJobDefinition object that specifies the definition of the training jobs * that this tuning job launches. * @return Returns a reference to this object so that method calls can be chained together. */ Builder trainingJobDefinition(HyperParameterTrainingJobDefinition trainingJobDefinition); /** *

* The HyperParameterTrainingJobDefinition object that specifies the definition of the training jobs that this * tuning job launches. *

* This is a convenience method that creates an instance of the * {@link HyperParameterTrainingJobDefinition.Builder} avoiding the need to create one manually via * {@link HyperParameterTrainingJobDefinition#builder()}. * *

* When the {@link Consumer} completes, {@link HyperParameterTrainingJobDefinition.Builder#build()} is called * immediately and its result is passed to {@link #trainingJobDefinition(HyperParameterTrainingJobDefinition)}. * * @param trainingJobDefinition * a consumer that will call methods on {@link HyperParameterTrainingJobDefinition.Builder} * @return Returns a reference to this object so that method calls can be chained together. * @see #trainingJobDefinition(HyperParameterTrainingJobDefinition) */ default Builder trainingJobDefinition(Consumer trainingJobDefinition) { return trainingJobDefinition(HyperParameterTrainingJobDefinition.builder().applyMutation(trainingJobDefinition) .build()); } /** *

* A list of the HyperParameterTrainingJobDefinition objects launched for this tuning job. *

* * @param trainingJobDefinitions * A list of the HyperParameterTrainingJobDefinition objects launched for this tuning job. * @return Returns a reference to this object so that method calls can be chained together. */ Builder trainingJobDefinitions(Collection trainingJobDefinitions); /** *

* A list of the HyperParameterTrainingJobDefinition objects launched for this tuning job. *

* * @param trainingJobDefinitions * A list of the HyperParameterTrainingJobDefinition objects launched for this tuning job. * @return Returns a reference to this object so that method calls can be chained together. */ Builder trainingJobDefinitions(HyperParameterTrainingJobDefinition... trainingJobDefinitions); /** *

* A list of the HyperParameterTrainingJobDefinition objects launched for this tuning job. *

* This is a convenience method that creates an instance of the * {@link software.amazon.awssdk.services.sagemaker.model.HyperParameterTrainingJobDefinition.Builder} avoiding * the need to create one manually via * {@link software.amazon.awssdk.services.sagemaker.model.HyperParameterTrainingJobDefinition#builder()}. * *

* When the {@link Consumer} completes, * {@link software.amazon.awssdk.services.sagemaker.model.HyperParameterTrainingJobDefinition.Builder#build()} * is called immediately and its result is passed to {@link * #trainingJobDefinitions(List)}. * * @param trainingJobDefinitions * a consumer that will call methods on * {@link software.amazon.awssdk.services.sagemaker.model.HyperParameterTrainingJobDefinition.Builder} * @return Returns a reference to this object so that method calls can be chained together. * @see #trainingJobDefinitions(java.util.Collection) */ Builder trainingJobDefinitions(Consumer... trainingJobDefinitions); /** *

* The status of the tuning job. *

* * @param hyperParameterTuningJobStatus * The status of the tuning job. * @see HyperParameterTuningJobStatus * @return Returns a reference to this object so that method calls can be chained together. * @see HyperParameterTuningJobStatus */ Builder hyperParameterTuningJobStatus(String hyperParameterTuningJobStatus); /** *

* The status of the tuning job. *

* * @param hyperParameterTuningJobStatus * The status of the tuning job. * @see HyperParameterTuningJobStatus * @return Returns a reference to this object so that method calls can be chained together. * @see HyperParameterTuningJobStatus */ Builder hyperParameterTuningJobStatus(HyperParameterTuningJobStatus hyperParameterTuningJobStatus); /** *

* The date and time that the tuning job started. *

* * @param creationTime * The date and time that the tuning job started. * @return Returns a reference to this object so that method calls can be chained together. */ Builder creationTime(Instant creationTime); /** *

* The date and time that the tuning job ended. *

* * @param hyperParameterTuningEndTime * The date and time that the tuning job ended. * @return Returns a reference to this object so that method calls can be chained together. */ Builder hyperParameterTuningEndTime(Instant hyperParameterTuningEndTime); /** *

* The date and time that the status of the tuning job was modified. *

* * @param lastModifiedTime * The date and time that the status of the tuning job was modified. * @return Returns a reference to this object so that method calls can be chained together. */ Builder lastModifiedTime(Instant lastModifiedTime); /** *

* The * TrainingJobStatusCounters object that specifies the number of training jobs, categorized by status, that * this tuning job launched. *

* * @param trainingJobStatusCounters * The TrainingJobStatusCounters object that specifies the number of training jobs, categorized by * status, that this tuning job launched. * @return Returns a reference to this object so that method calls can be chained together. */ Builder trainingJobStatusCounters(TrainingJobStatusCounters trainingJobStatusCounters); /** *

* The * TrainingJobStatusCounters object that specifies the number of training jobs, categorized by status, that * this tuning job launched. *

* This is a convenience method that creates an instance of the {@link TrainingJobStatusCounters.Builder} * avoiding the need to create one manually via {@link TrainingJobStatusCounters#builder()}. * *

* When the {@link Consumer} completes, {@link TrainingJobStatusCounters.Builder#build()} is called immediately * and its result is passed to {@link #trainingJobStatusCounters(TrainingJobStatusCounters)}. * * @param trainingJobStatusCounters * a consumer that will call methods on {@link TrainingJobStatusCounters.Builder} * @return Returns a reference to this object so that method calls can be chained together. * @see #trainingJobStatusCounters(TrainingJobStatusCounters) */ default Builder trainingJobStatusCounters(Consumer trainingJobStatusCounters) { return trainingJobStatusCounters(TrainingJobStatusCounters.builder().applyMutation(trainingJobStatusCounters).build()); } /** *

* The * ObjectiveStatusCounters object that specifies the number of training jobs, categorized by the status of * their final objective metric, that this tuning job launched. *

* * @param objectiveStatusCounters * The ObjectiveStatusCounters object that specifies the number of training jobs, categorized by the * status of their final objective metric, that this tuning job launched. * @return Returns a reference to this object so that method calls can be chained together. */ Builder objectiveStatusCounters(ObjectiveStatusCounters objectiveStatusCounters); /** *

* The * ObjectiveStatusCounters object that specifies the number of training jobs, categorized by the status of * their final objective metric, that this tuning job launched. *

* This is a convenience method that creates an instance of the {@link ObjectiveStatusCounters.Builder} avoiding * the need to create one manually via {@link ObjectiveStatusCounters#builder()}. * *

* When the {@link Consumer} completes, {@link ObjectiveStatusCounters.Builder#build()} is called immediately * and its result is passed to {@link #objectiveStatusCounters(ObjectiveStatusCounters)}. * * @param objectiveStatusCounters * a consumer that will call methods on {@link ObjectiveStatusCounters.Builder} * @return Returns a reference to this object so that method calls can be chained together. * @see #objectiveStatusCounters(ObjectiveStatusCounters) */ default Builder objectiveStatusCounters(Consumer objectiveStatusCounters) { return objectiveStatusCounters(ObjectiveStatusCounters.builder().applyMutation(objectiveStatusCounters).build()); } /** *

* A * TrainingJobSummary object that describes the training job that completed with the best current HyperParameterTuningJobObjective. *

* * @param bestTrainingJob * A * TrainingJobSummary object that describes the training job that completed with the best current HyperParameterTuningJobObjective. * @return Returns a reference to this object so that method calls can be chained together. */ Builder bestTrainingJob(HyperParameterTrainingJobSummary bestTrainingJob); /** *

* A * TrainingJobSummary object that describes the training job that completed with the best current HyperParameterTuningJobObjective. *

* This is a convenience method that creates an instance of the {@link HyperParameterTrainingJobSummary.Builder} * avoiding the need to create one manually via {@link HyperParameterTrainingJobSummary#builder()}. * *

* When the {@link Consumer} completes, {@link HyperParameterTrainingJobSummary.Builder#build()} is called * immediately and its result is passed to {@link #bestTrainingJob(HyperParameterTrainingJobSummary)}. * * @param bestTrainingJob * a consumer that will call methods on {@link HyperParameterTrainingJobSummary.Builder} * @return Returns a reference to this object so that method calls can be chained together. * @see #bestTrainingJob(HyperParameterTrainingJobSummary) */ default Builder bestTrainingJob(Consumer bestTrainingJob) { return bestTrainingJob(HyperParameterTrainingJobSummary.builder().applyMutation(bestTrainingJob).build()); } /** *

* If the hyperparameter tuning job is an warm start tuning job with a WarmStartType of * IDENTICAL_DATA_AND_ALGORITHM, this is the TrainingJobSummary for the training job with the best objective metric value of all training jobs * launched by this tuning job and all parent jobs specified for the warm start tuning job. *

* * @param overallBestTrainingJob * If the hyperparameter tuning job is an warm start tuning job with a WarmStartType of * IDENTICAL_DATA_AND_ALGORITHM, this is the TrainingJobSummary for the training job with the best objective metric value of all training jobs * launched by this tuning job and all parent jobs specified for the warm start tuning job. * @return Returns a reference to this object so that method calls can be chained together. */ Builder overallBestTrainingJob(HyperParameterTrainingJobSummary overallBestTrainingJob); /** *

* If the hyperparameter tuning job is an warm start tuning job with a WarmStartType of * IDENTICAL_DATA_AND_ALGORITHM, this is the TrainingJobSummary for the training job with the best objective metric value of all training jobs * launched by this tuning job and all parent jobs specified for the warm start tuning job. *

* This is a convenience method that creates an instance of the {@link HyperParameterTrainingJobSummary.Builder} * avoiding the need to create one manually via {@link HyperParameterTrainingJobSummary#builder()}. * *

* When the {@link Consumer} completes, {@link HyperParameterTrainingJobSummary.Builder#build()} is called * immediately and its result is passed to {@link #overallBestTrainingJob(HyperParameterTrainingJobSummary)}. * * @param overallBestTrainingJob * a consumer that will call methods on {@link HyperParameterTrainingJobSummary.Builder} * @return Returns a reference to this object so that method calls can be chained together. * @see #overallBestTrainingJob(HyperParameterTrainingJobSummary) */ default Builder overallBestTrainingJob(Consumer overallBestTrainingJob) { return overallBestTrainingJob(HyperParameterTrainingJobSummary.builder().applyMutation(overallBestTrainingJob) .build()); } /** *

* The configuration for starting the hyperparameter parameter tuning job using one or more previous tuning jobs * as a starting point. The results of previous tuning jobs are used to inform which combinations of * hyperparameters to search over in the new tuning job. *

* * @param warmStartConfig * The configuration for starting the hyperparameter parameter tuning job using one or more previous * tuning jobs as a starting point. The results of previous tuning jobs are used to inform which * combinations of hyperparameters to search over in the new tuning job. * @return Returns a reference to this object so that method calls can be chained together. */ Builder warmStartConfig(HyperParameterTuningJobWarmStartConfig warmStartConfig); /** *

* The configuration for starting the hyperparameter parameter tuning job using one or more previous tuning jobs * as a starting point. The results of previous tuning jobs are used to inform which combinations of * hyperparameters to search over in the new tuning job. *

* This is a convenience method that creates an instance of the * {@link HyperParameterTuningJobWarmStartConfig.Builder} avoiding the need to create one manually via * {@link HyperParameterTuningJobWarmStartConfig#builder()}. * *

* When the {@link Consumer} completes, {@link HyperParameterTuningJobWarmStartConfig.Builder#build()} is called * immediately and its result is passed to {@link #warmStartConfig(HyperParameterTuningJobWarmStartConfig)}. * * @param warmStartConfig * a consumer that will call methods on {@link HyperParameterTuningJobWarmStartConfig.Builder} * @return Returns a reference to this object so that method calls can be chained together. * @see #warmStartConfig(HyperParameterTuningJobWarmStartConfig) */ default Builder warmStartConfig(Consumer warmStartConfig) { return warmStartConfig(HyperParameterTuningJobWarmStartConfig.builder().applyMutation(warmStartConfig).build()); } /** *

* A flag to indicate if autotune is enabled for the hyperparameter tuning job. *

* * @param autotune * A flag to indicate if autotune is enabled for the hyperparameter tuning job. * @return Returns a reference to this object so that method calls can be chained together. */ Builder autotune(Autotune autotune); /** *

* A flag to indicate if autotune is enabled for the hyperparameter tuning job. *

* This is a convenience method that creates an instance of the {@link Autotune.Builder} avoiding the need to * create one manually via {@link Autotune#builder()}. * *

* When the {@link Consumer} completes, {@link Autotune.Builder#build()} is called immediately and its result is * passed to {@link #autotune(Autotune)}. * * @param autotune * a consumer that will call methods on {@link Autotune.Builder} * @return Returns a reference to this object so that method calls can be chained together. * @see #autotune(Autotune) */ default Builder autotune(Consumer autotune) { return autotune(Autotune.builder().applyMutation(autotune).build()); } /** *

* If the tuning job failed, the reason it failed. *

* * @param failureReason * If the tuning job failed, the reason it failed. * @return Returns a reference to this object so that method calls can be chained together. */ Builder failureReason(String failureReason); /** *

* Tuning job completion information returned as the response from a hyperparameter tuning job. This information * tells if your tuning job has or has not converged. It also includes the number of training jobs that have not * improved model performance as evaluated against the objective function. *

* * @param tuningJobCompletionDetails * Tuning job completion information returned as the response from a hyperparameter tuning job. This * information tells if your tuning job has or has not converged. It also includes the number of training * jobs that have not improved model performance as evaluated against the objective function. * @return Returns a reference to this object so that method calls can be chained together. */ Builder tuningJobCompletionDetails(HyperParameterTuningJobCompletionDetails tuningJobCompletionDetails); /** *

* Tuning job completion information returned as the response from a hyperparameter tuning job. This information * tells if your tuning job has or has not converged. It also includes the number of training jobs that have not * improved model performance as evaluated against the objective function. *

* This is a convenience method that creates an instance of the * {@link HyperParameterTuningJobCompletionDetails.Builder} avoiding the need to create one manually via * {@link HyperParameterTuningJobCompletionDetails#builder()}. * *

* When the {@link Consumer} completes, {@link HyperParameterTuningJobCompletionDetails.Builder#build()} is * called immediately and its result is passed to * {@link #tuningJobCompletionDetails(HyperParameterTuningJobCompletionDetails)}. * * @param tuningJobCompletionDetails * a consumer that will call methods on {@link HyperParameterTuningJobCompletionDetails.Builder} * @return Returns a reference to this object so that method calls can be chained together. * @see #tuningJobCompletionDetails(HyperParameterTuningJobCompletionDetails) */ default Builder tuningJobCompletionDetails( Consumer tuningJobCompletionDetails) { return tuningJobCompletionDetails(HyperParameterTuningJobCompletionDetails.builder() .applyMutation(tuningJobCompletionDetails).build()); } /** * Sets the value of the ConsumedResources property for this object. * * @param consumedResources * The new value for the ConsumedResources property for this object. * @return Returns a reference to this object so that method calls can be chained together. */ Builder consumedResources(HyperParameterTuningJobConsumedResources consumedResources); /** * Sets the value of the ConsumedResources property for this object. * * This is a convenience method that creates an instance of the * {@link HyperParameterTuningJobConsumedResources.Builder} avoiding the need to create one manually via * {@link HyperParameterTuningJobConsumedResources#builder()}. * *

* When the {@link Consumer} completes, {@link HyperParameterTuningJobConsumedResources.Builder#build()} is * called immediately and its result is passed to * {@link #consumedResources(HyperParameterTuningJobConsumedResources)}. * * @param consumedResources * a consumer that will call methods on {@link HyperParameterTuningJobConsumedResources.Builder} * @return Returns a reference to this object so that method calls can be chained together. * @see #consumedResources(HyperParameterTuningJobConsumedResources) */ default Builder consumedResources(Consumer consumedResources) { return consumedResources(HyperParameterTuningJobConsumedResources.builder().applyMutation(consumedResources).build()); } } static final class BuilderImpl extends SageMakerResponse.BuilderImpl implements Builder { private String hyperParameterTuningJobName; private String hyperParameterTuningJobArn; private HyperParameterTuningJobConfig hyperParameterTuningJobConfig; private HyperParameterTrainingJobDefinition trainingJobDefinition; private List trainingJobDefinitions = DefaultSdkAutoConstructList.getInstance(); private String hyperParameterTuningJobStatus; private Instant creationTime; private Instant hyperParameterTuningEndTime; private Instant lastModifiedTime; private TrainingJobStatusCounters trainingJobStatusCounters; private ObjectiveStatusCounters objectiveStatusCounters; private HyperParameterTrainingJobSummary bestTrainingJob; private HyperParameterTrainingJobSummary overallBestTrainingJob; private HyperParameterTuningJobWarmStartConfig warmStartConfig; private Autotune autotune; private String failureReason; private HyperParameterTuningJobCompletionDetails tuningJobCompletionDetails; private HyperParameterTuningJobConsumedResources consumedResources; private BuilderImpl() { } private BuilderImpl(DescribeHyperParameterTuningJobResponse model) { super(model); hyperParameterTuningJobName(model.hyperParameterTuningJobName); hyperParameterTuningJobArn(model.hyperParameterTuningJobArn); hyperParameterTuningJobConfig(model.hyperParameterTuningJobConfig); trainingJobDefinition(model.trainingJobDefinition); trainingJobDefinitions(model.trainingJobDefinitions); hyperParameterTuningJobStatus(model.hyperParameterTuningJobStatus); creationTime(model.creationTime); hyperParameterTuningEndTime(model.hyperParameterTuningEndTime); lastModifiedTime(model.lastModifiedTime); trainingJobStatusCounters(model.trainingJobStatusCounters); objectiveStatusCounters(model.objectiveStatusCounters); bestTrainingJob(model.bestTrainingJob); overallBestTrainingJob(model.overallBestTrainingJob); warmStartConfig(model.warmStartConfig); autotune(model.autotune); failureReason(model.failureReason); tuningJobCompletionDetails(model.tuningJobCompletionDetails); consumedResources(model.consumedResources); } public final String getHyperParameterTuningJobName() { return hyperParameterTuningJobName; } public final void setHyperParameterTuningJobName(String hyperParameterTuningJobName) { this.hyperParameterTuningJobName = hyperParameterTuningJobName; } @Override public final Builder hyperParameterTuningJobName(String hyperParameterTuningJobName) { this.hyperParameterTuningJobName = hyperParameterTuningJobName; return this; } public final String getHyperParameterTuningJobArn() { return hyperParameterTuningJobArn; } public final void setHyperParameterTuningJobArn(String hyperParameterTuningJobArn) { this.hyperParameterTuningJobArn = hyperParameterTuningJobArn; } @Override public final Builder hyperParameterTuningJobArn(String hyperParameterTuningJobArn) { this.hyperParameterTuningJobArn = hyperParameterTuningJobArn; return this; } public final HyperParameterTuningJobConfig.Builder getHyperParameterTuningJobConfig() { return hyperParameterTuningJobConfig != null ? hyperParameterTuningJobConfig.toBuilder() : null; } public final void setHyperParameterTuningJobConfig(HyperParameterTuningJobConfig.BuilderImpl hyperParameterTuningJobConfig) { this.hyperParameterTuningJobConfig = hyperParameterTuningJobConfig != null ? hyperParameterTuningJobConfig.build() : null; } @Override public final Builder hyperParameterTuningJobConfig(HyperParameterTuningJobConfig hyperParameterTuningJobConfig) { this.hyperParameterTuningJobConfig = hyperParameterTuningJobConfig; return this; } public final HyperParameterTrainingJobDefinition.Builder getTrainingJobDefinition() { return trainingJobDefinition != null ? trainingJobDefinition.toBuilder() : null; } public final void setTrainingJobDefinition(HyperParameterTrainingJobDefinition.BuilderImpl trainingJobDefinition) { this.trainingJobDefinition = trainingJobDefinition != null ? trainingJobDefinition.build() : null; } @Override public final Builder trainingJobDefinition(HyperParameterTrainingJobDefinition trainingJobDefinition) { this.trainingJobDefinition = trainingJobDefinition; return this; } public final List getTrainingJobDefinitions() { List result = HyperParameterTrainingJobDefinitionsCopier .copyToBuilder(this.trainingJobDefinitions); if (result instanceof SdkAutoConstructList) { return null; } return result; } public final void setTrainingJobDefinitions( Collection trainingJobDefinitions) { this.trainingJobDefinitions = HyperParameterTrainingJobDefinitionsCopier.copyFromBuilder(trainingJobDefinitions); } @Override public final Builder trainingJobDefinitions(Collection trainingJobDefinitions) { this.trainingJobDefinitions = HyperParameterTrainingJobDefinitionsCopier.copy(trainingJobDefinitions); return this; } @Override @SafeVarargs public final Builder trainingJobDefinitions(HyperParameterTrainingJobDefinition... trainingJobDefinitions) { trainingJobDefinitions(Arrays.asList(trainingJobDefinitions)); return this; } @Override @SafeVarargs public final Builder trainingJobDefinitions( Consumer... trainingJobDefinitions) { trainingJobDefinitions(Stream.of(trainingJobDefinitions) .map(c -> HyperParameterTrainingJobDefinition.builder().applyMutation(c).build()) .collect(Collectors.toList())); return this; } public final String getHyperParameterTuningJobStatus() { return hyperParameterTuningJobStatus; } public final void setHyperParameterTuningJobStatus(String hyperParameterTuningJobStatus) { this.hyperParameterTuningJobStatus = hyperParameterTuningJobStatus; } @Override public final Builder hyperParameterTuningJobStatus(String hyperParameterTuningJobStatus) { this.hyperParameterTuningJobStatus = hyperParameterTuningJobStatus; return this; } @Override public final Builder hyperParameterTuningJobStatus(HyperParameterTuningJobStatus hyperParameterTuningJobStatus) { this.hyperParameterTuningJobStatus(hyperParameterTuningJobStatus == null ? null : hyperParameterTuningJobStatus .toString()); return this; } public final Instant getCreationTime() { return creationTime; } public final void setCreationTime(Instant creationTime) { this.creationTime = creationTime; } @Override public final Builder creationTime(Instant creationTime) { this.creationTime = creationTime; return this; } public final Instant getHyperParameterTuningEndTime() { return hyperParameterTuningEndTime; } public final void setHyperParameterTuningEndTime(Instant hyperParameterTuningEndTime) { this.hyperParameterTuningEndTime = hyperParameterTuningEndTime; } @Override public final Builder hyperParameterTuningEndTime(Instant hyperParameterTuningEndTime) { this.hyperParameterTuningEndTime = hyperParameterTuningEndTime; return this; } public final Instant getLastModifiedTime() { return lastModifiedTime; } public final void setLastModifiedTime(Instant lastModifiedTime) { this.lastModifiedTime = lastModifiedTime; } @Override public final Builder lastModifiedTime(Instant lastModifiedTime) { this.lastModifiedTime = lastModifiedTime; return this; } public final TrainingJobStatusCounters.Builder getTrainingJobStatusCounters() { return trainingJobStatusCounters != null ? trainingJobStatusCounters.toBuilder() : null; } public final void setTrainingJobStatusCounters(TrainingJobStatusCounters.BuilderImpl trainingJobStatusCounters) { this.trainingJobStatusCounters = trainingJobStatusCounters != null ? trainingJobStatusCounters.build() : null; } @Override public final Builder trainingJobStatusCounters(TrainingJobStatusCounters trainingJobStatusCounters) { this.trainingJobStatusCounters = trainingJobStatusCounters; return this; } public final ObjectiveStatusCounters.Builder getObjectiveStatusCounters() { return objectiveStatusCounters != null ? objectiveStatusCounters.toBuilder() : null; } public final void setObjectiveStatusCounters(ObjectiveStatusCounters.BuilderImpl objectiveStatusCounters) { this.objectiveStatusCounters = objectiveStatusCounters != null ? objectiveStatusCounters.build() : null; } @Override public final Builder objectiveStatusCounters(ObjectiveStatusCounters objectiveStatusCounters) { this.objectiveStatusCounters = objectiveStatusCounters; return this; } public final HyperParameterTrainingJobSummary.Builder getBestTrainingJob() { return bestTrainingJob != null ? bestTrainingJob.toBuilder() : null; } public final void setBestTrainingJob(HyperParameterTrainingJobSummary.BuilderImpl bestTrainingJob) { this.bestTrainingJob = bestTrainingJob != null ? bestTrainingJob.build() : null; } @Override public final Builder bestTrainingJob(HyperParameterTrainingJobSummary bestTrainingJob) { this.bestTrainingJob = bestTrainingJob; return this; } public final HyperParameterTrainingJobSummary.Builder getOverallBestTrainingJob() { return overallBestTrainingJob != null ? overallBestTrainingJob.toBuilder() : null; } public final void setOverallBestTrainingJob(HyperParameterTrainingJobSummary.BuilderImpl overallBestTrainingJob) { this.overallBestTrainingJob = overallBestTrainingJob != null ? overallBestTrainingJob.build() : null; } @Override public final Builder overallBestTrainingJob(HyperParameterTrainingJobSummary overallBestTrainingJob) { this.overallBestTrainingJob = overallBestTrainingJob; return this; } public final HyperParameterTuningJobWarmStartConfig.Builder getWarmStartConfig() { return warmStartConfig != null ? warmStartConfig.toBuilder() : null; } public final void setWarmStartConfig(HyperParameterTuningJobWarmStartConfig.BuilderImpl warmStartConfig) { this.warmStartConfig = warmStartConfig != null ? warmStartConfig.build() : null; } @Override public final Builder warmStartConfig(HyperParameterTuningJobWarmStartConfig warmStartConfig) { this.warmStartConfig = warmStartConfig; return this; } public final Autotune.Builder getAutotune() { return autotune != null ? autotune.toBuilder() : null; } public final void setAutotune(Autotune.BuilderImpl autotune) { this.autotune = autotune != null ? autotune.build() : null; } @Override public final Builder autotune(Autotune autotune) { this.autotune = autotune; return this; } public final String getFailureReason() { return failureReason; } public final void setFailureReason(String failureReason) { this.failureReason = failureReason; } @Override public final Builder failureReason(String failureReason) { this.failureReason = failureReason; return this; } public final HyperParameterTuningJobCompletionDetails.Builder getTuningJobCompletionDetails() { return tuningJobCompletionDetails != null ? tuningJobCompletionDetails.toBuilder() : null; } public final void setTuningJobCompletionDetails( HyperParameterTuningJobCompletionDetails.BuilderImpl tuningJobCompletionDetails) { this.tuningJobCompletionDetails = tuningJobCompletionDetails != null ? tuningJobCompletionDetails.build() : null; } @Override public final Builder tuningJobCompletionDetails(HyperParameterTuningJobCompletionDetails tuningJobCompletionDetails) { this.tuningJobCompletionDetails = tuningJobCompletionDetails; return this; } public final HyperParameterTuningJobConsumedResources.Builder getConsumedResources() { return consumedResources != null ? consumedResources.toBuilder() : null; } public final void setConsumedResources(HyperParameterTuningJobConsumedResources.BuilderImpl consumedResources) { this.consumedResources = consumedResources != null ? consumedResources.build() : null; } @Override public final Builder consumedResources(HyperParameterTuningJobConsumedResources consumedResources) { this.consumedResources = consumedResources; return this; } @Override public DescribeHyperParameterTuningJobResponse build() { return new DescribeHyperParameterTuningJobResponse(this); } @Override public List> sdkFields() { return SDK_FIELDS; } } }





© 2015 - 2024 Weber Informatics LLC | Privacy Policy