From 3ec620c64bd60ceb5b89918200e11e3fbff67370 Mon Sep 17 00:00:00 2001 From: Andrew Ferlitsch Date: Thu, 16 Dec 2021 16:34:14 -0800 Subject: [PATCH] fix: issues/192254729 (#914) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Thank you for opening a Pull Request! Before submitting your PR, there are a few things you can do to make sure it goes smoothly: - [x] Make sure to open an issue as a [bug/issue](https://github.com/googleapis/python-aiplatform/issues/new/choose) before writing your code! That way we can discuss the change, evaluate designs, and agree on the general idea - [ ] Ensure the tests and linter pass - [x] Code coverage does not decrease (if any source code was changed) - [x] Appropriate docs were updated (if necessary) Fixes #192254729 🦕 --- .../create_training_pipeline_tabular_regression_sample.py | 1 + .../create_training_pipeline_tabular_regression_sample_test.py | 1 + 2 files changed, 2 insertions(+) diff --git a/samples/model-builder/create_training_pipeline_tabular_regression_sample.py b/samples/model-builder/create_training_pipeline_tabular_regression_sample.py index 2404bb37e2..f7edcce1d9 100644 --- a/samples/model-builder/create_training_pipeline_tabular_regression_sample.py +++ b/samples/model-builder/create_training_pipeline_tabular_regression_sample.py @@ -33,6 +33,7 @@ def create_training_pipeline_tabular_regression_sample( tabular_regression_job = aiplatform.AutoMLTabularTrainingJob( display_name=display_name, + optimization_prediction_type="regression" ) my_tabular_dataset = aiplatform.TabularDataset(dataset_id) diff --git a/samples/model-builder/create_training_pipeline_tabular_regression_sample_test.py b/samples/model-builder/create_training_pipeline_tabular_regression_sample_test.py index 1e897b5851..d9a6b386e0 100644 --- a/samples/model-builder/create_training_pipeline_tabular_regression_sample_test.py +++ b/samples/model-builder/create_training_pipeline_tabular_regression_sample_test.py @@ -44,6 +44,7 @@ def test_create_training_pipeline_tabular_regression_sample( ) mock_get_automl_tabular_training_job.assert_called_once_with( display_name=constants.DISPLAY_NAME, + optimization_prediction_type="regression" ) mock_run_automl_tabular_training_job.assert_called_once_with( dataset=mock_tabular_dataset,