class_docstr: Abstract class interacting with CAIP or Vertex Prediction service.
class_docstr_tok: ["Abstract","class","interacting","with","CAIP","or","Vertex","Prediction","service","."]
docstr: Deploys a model for serving with AI Platform.
  
  Args:
    serving_path: The path to the model. Must be a GCS URI.
    model_version_name: Model version for CAIP model being deployed, or model
      name for the Vertex model being deployed. Must be different from what is
      currently being served.
    ai_platform_serving_args: Dictionary containing arguments for pushing to
      AI Platform.
    labels: The dict of labels that will be attached to this CAIP job or
      Vertex endpoint. They are merged with optional labels from
      `ai_platform_serving_args`.
    skip_model_endpoint_creation: If true, the method assumes CAIP model or
      Vertex endpoint already exists in AI platform, therefore skipping
      model/endpoint creation.
    set_default: Whether set the newly deployed CAIP model version or Vertex
      model as the default.
    **kwargs: Extra keyword args.
  
  Returns:
    The resource name of the deployed CAIP model version or Vertex model.
  
  Raises:
    RuntimeError: if an error is encountered when trying to push.
docstr_tok: ["Deploys","a","model","for","serving","with","AI","Platform",".","Args",":","serving_path",":","The","path","to","the","model",".","Must","be","a","GCS","URI",".","model_version_name",":","Model","version","for","CAIP","model","being","deployed",",","or","model","name","for","the","Vertex","model","being","deployed",".","Must","be","different","from","what","is","currently","being","served",".","ai_platform_serving_args",":","Dictionary","containing","arguments","for","pushing","to","AI","Platform",".","labels",":","The","dict","of","labels","that","will","be","attached","to","this","CAIP","job","or","Vertex","endpoint",".","They","are","merged","with","optional","labels","from","`","ai_platform_serving_args","`",".","skip_model_endpoint_creation",":","If","true",",","the","method","assumes","CAIP","model","or","Vertex","endpoint","already","exists","in","AI","platform",",","therefore","skipping","model\/endpoint","creation",".","set_default",":","Whether","set","the","newly","deployed","CAIP","model","version","or","Vertex","model","as","the","default",".","*","*","kwargs",":","Extra","keyword","args",".","Returns",":","The","resource","name","of","the","deployed","CAIP","model","version","or","Vertex","model",".","Raises",":","RuntimeError",":","if","an","error","is","encountered","when","trying","to","push","."]
code: def deploy_model(
      self,
      serving_path: str,
      model_version_name: str,
      ai_platform_serving_args: Dict[str, Any],
      labels: Dict[str, str],
      skip_model_endpoint_creation: Optional[bool] = False,
      set_default: Optional[bool] = True,
      **kwargs,
  ) -> str:
      """Deploys a model for serving with AI Platform.
  
      Args:
        serving_path: The path to the model. Must be a GCS URI.
        model_version_name: Model version for CAIP model being deployed, or model
          name for the Vertex model being deployed. Must be different from what is
          currently being served.
        ai_platform_serving_args: Dictionary containing arguments for pushing to
          AI Platform.
        labels: The dict of labels that will be attached to this CAIP job or
          Vertex endpoint. They are merged with optional labels from
          `ai_platform_serving_args`.
        skip_model_endpoint_creation: If true, the method assumes CAIP model or
          Vertex endpoint already exists in AI platform, therefore skipping
          model/endpoint creation.
        set_default: Whether set the newly deployed CAIP model version or Vertex
          model as the default.
        **kwargs: Extra keyword args.
  
      Returns:
        The resource name of the deployed CAIP model version or Vertex model.
  
      Raises:
        RuntimeError: if an error is encountered when trying to push.
      """
      pass
  
imports: import abc
  import sys
  import time
  from typing import Any, Dict, Optional, Union
  from absl import logging
  from google.cloud import aiplatform
  from googleapiclient import discovery
  from googleapiclient import errors
  import tensorflow
label_desc: Use image node_id 1 for calling the AbstractPredictionClient obj's underlying member method code with example usage: obj.deploy_model(serving_path, model_version_name, ai_platform_serving_args, labels, skip_model_endpoint_creation, set_default) without return types