Get hands-on experience with 20+ free Google Cloud products and $300 in free credit for new customers.

Batch prediction on custom model

yao
Bronze 1
Bronze 1

Hi,

I used custom containers for training and prediction to create a model on Vertex AI. Now I want to run batch prediction against it but get error message that says "Unable to start batch prediction job due to the following error: A model using a third-party image must specify PredictRoute and HealthRoute in ContainerSpec."

I checked documentation, AIP_HEALTH_ROUTE = /v1/endpoints/ENDPOINT/deployedModels/DEPLOYED_MODEL

Does this mean that the model has to be deployed to an endpoint in order to generate the value of the AIP_ENDPOINT_ID variable?

However, the documentation “Get batch predictions” says “Requesting a batch prediction is an asynchronous request (as opposed to online prediction, which is a synchronous request). You request batch predictions directly from the model resource; you don't need to deploy the model to an endpoint.

I am confused whether in my situation, the model has to be deployed first. Also, is there any resources regarding hosting custom models for batch predictions?

7 REPLIES 7