<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# source: google/cloud/automl/v1beta1/image.proto

namespace Google\Cloud\AutoMl\V1beta1;

use Google\Protobuf\Internal\GPBType;
use Google\Protobuf\Internal\RepeatedField;
use Google\Protobuf\Internal\GPBUtil;

/**
 * Model metadata for image classification.
 *
 * Generated from protobuf message <code>google.cloud.automl.v1beta1.ImageClassificationModelMetadata</code>
 */
class ImageClassificationModelMetadata extends \Google\Protobuf\Internal\Message
{
    /**
     * Optional. The ID of the `base` model. If it is specified, the new model
     * will be created based on the `base` model. Otherwise, the new model will be
     * created from scratch. The `base` model is expected to be in the same
     * `project` and `location` as the new model to create.
     *
     * Generated from protobuf field <code>string base_model_id = 1;</code>
     */
    private $base_model_id = '';
    /**
     * Required. The train budget of creating this model. The actual
     * `train_cost` will be equal or less than this value.
     *
     * Generated from protobuf field <code>int64 train_budget = 2;</code>
     */
    private $train_budget = 0;
    /**
     * Output only. The actual train cost of creating this model. If this
     * model is created from a `base` model, the train cost used to create the
     * `base` model are not included.
     *
     * Generated from protobuf field <code>int64 train_cost = 3;</code>
     */
    private $train_cost = 0;
    /**
     * Output only. The reason that this create model operation stopped,
     * e.g. BUDGET_REACHED, CONVERGED.
     *
     * Generated from protobuf field <code>string stop_reason = 5;</code>
     */
    private $stop_reason = '';

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $base_model_id
     *           Optional. The ID of the `base` model. If it is specified, the new model
     *           will be created based on the `base` model. Otherwise, the new model will be
     *           created from scratch. The `base` model is expected to be in the same
     *           `project` and `location` as the new model to create.
     *     @type int|string $train_budget
     *           Required. The train budget of creating this model. The actual
     *           `train_cost` will be equal or less than this value.
     *     @type int|string $train_cost
     *           Output only. The actual train cost of creating this model. If this
     *           model is created from a `base` model, the train cost used to create the
     *           `base` model are not included.
     *     @type string $stop_reason
     *           Output only. The reason that this create model operation stopped,
     *           e.g. BUDGET_REACHED, CONVERGED.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Automl\V1Beta1\Image::initOnce();
        parent::__construct($data);
    }

    /**
     * Optional. The ID of the `base` model. If it is specified, the new model
     * will be created based on the `base` model. Otherwise, the new model will be
     * created from scratch. The `base` model is expected to be in the same
     * `project` and `location` as the new model to create.
     *
     * Generated from protobuf field <code>string base_model_id = 1;</code>
     * @return string
     */
    public function getBaseModelId()
    {
        return $this->base_model_id;
    }

    /**
     * Optional. The ID of the `base` model. If it is specified, the new model
     * will be created based on the `base` model. Otherwise, the new model will be
     * created from scratch. The `base` model is expected to be in the same
     * `project` and `location` as the new model to create.
     *
     * Generated from protobuf field <code>string base_model_id = 1;</code>
     * @param string $var
     * @return $this
     */
    public function setBaseModelId($var)
    {
        GPBUtil::checkString($var, True);
        $this->base_model_id = $var;

        return $this;
    }

    /**
     * Required. The train budget of creating this model. The actual
     * `train_cost` will be equal or less than this value.
     *
     * Generated from protobuf field <code>int64 train_budget = 2;</code>
     * @return int|string
     */
    public function getTrainBudget()
    {
        return $this->train_budget;
    }

    /**
     * Required. The train budget of creating this model. The actual
     * `train_cost` will be equal or less than this value.
     *
     * Generated from protobuf field <code>int64 train_budget = 2;</code>
     * @param int|string $var
     * @return $this
     */
    public function setTrainBudget($var)
    {
        GPBUtil::checkInt64($var);
        $this->train_budget = $var;

        return $this;
    }

    /**
     * Output only. The actual train cost of creating this model. If this
     * model is created from a `base` model, the train cost used to create the
     * `base` model are not included.
     *
     * Generated from protobuf field <code>int64 train_cost = 3;</code>
     * @return int|string
     */
    public function getTrainCost()
    {
        return $this->train_cost;
    }

    /**
     * Output only. The actual train cost of creating this model. If this
     * model is created from a `base` model, the train cost used to create the
     * `base` model are not included.
     *
     * Generated from protobuf field <code>int64 train_cost = 3;</code>
     * @param int|string $var
     * @return $this
     */
    public function setTrainCost($var)
    {
        GPBUtil::checkInt64($var);
        $this->train_cost = $var;

        return $this;
    }

    /**
     * Output only. The reason that this create model operation stopped,
     * e.g. BUDGET_REACHED, CONVERGED.
     *
     * Generated from protobuf field <code>string stop_reason = 5;</code>
     * @return string
     */
    public function getStopReason()
    {
        return $this->stop_reason;
    }

    /**
     * Output only. The reason that this create model operation stopped,
     * e.g. BUDGET_REACHED, CONVERGED.
     *
     * Generated from protobuf field <code>string stop_reason = 5;</code>
     * @param string $var
     * @return $this
     */
    public function setStopReason($var)
    {
        GPBUtil::checkString($var, True);
        $this->stop_reason = $var;

        return $this;
    }

}

