Skip to content

BigQuery instance format not supported for Model.batch_predict in VertexAI - but in documentation #467

@DanReia

Description

@DanReia

Environment details

  • OS type and version: MacOS Bigsur
  • Python version: 3.7.9
  • pip version: 20.1.1
  • google-cloud-aiplatform version: 1.0.1

Steps to reproduce

  1. Construct Custom Model training job with prebuilt container (in this case Tensorflow 2.4)
  2. Run mode.batch_predict using below sample call

Code example

model = aiplatform.Model(f"projects/{your_project}/locations/us-central1/models/{your_model_id}")

batch_prediction_job = model.batch_predict(
job_display_name="jobname",
bigquery_source="bq://project.dataset.table",
instances_format="bigquery",
bigquery_destination_prefix="project.dataset",
predictions_format="bigquery",
machine_type="n1-standard-4",
sync=True,
)

Stack trace

Can't put the full stack trace for commercial purposes but the error is self explanatory:

# example

google.api_core.exceptions.InvalidArgument: 400 Instance format "bigquery" is not supported for Model projects/your_project/locations/us-central1/models/your_model_id. Supported values are: [jsonl, csv, tf-record, tf-record-gzip, file-list].

Question

  1. According to the error "bigquery" is not supported on type Model, but it is quite clearly laid out in the documentation here. Is it not supported or is it supported? If not, please can it be removed from the documentation until it is supported.
  2. Is there something that I am doing incorrectly in the batch_predict call that would invalidate "bigquery" support for type Model? Is it supported for some deployed models/serving containers but not all?

Metadata

Metadata

Assignees

Labels

api: aiplatformIssues related to the AI Platform API.type: docsImprovement to the documentation for an API.type: questionRequest for information or clarification. Not an issue.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions