@@ -2048,6 +2048,8 @@ def deploy(
2048
2048
encryption_spec_key_name : Optional [str ] = None ,
2049
2049
sync = True ,
2050
2050
deploy_request_timeout : Optional [float ] = None ,
2051
+ autoscaling_target_cpu_utilization : Optional [int ] = None ,
2052
+ autoscaling_target_accelerator_duty_cycle : Optional [int ] = None ,
2051
2053
) -> Endpoint :
2052
2054
"""Deploys model to endpoint. Endpoint will be created if unspecified.
2053
2055
@@ -2132,6 +2134,13 @@ def deploy(
2132
2134
be immediately returned and synced when the Future has completed.
2133
2135
deploy_request_timeout (float):
2134
2136
Optional. The timeout for the deploy request in seconds.
2137
+ autoscaling_target_cpu_utilization (int):
2138
+ Target CPU Utilization to use for Autoscaling Replicas.
2139
+ A default value of 60 will be used if not specified.
2140
+ autoscaling_target_accelerator_duty_cycle (int):
2141
+ Target Accelerator Duty Cycle.
2142
+ Must also set accelerator_type and accelerator_count if specified.
2143
+ A default value of 60 will be used if not specified.
2135
2144
Returns:
2136
2145
endpoint ("Endpoint"):
2137
2146
Endpoint with the deployed model.
@@ -2166,6 +2175,8 @@ def deploy(
2166
2175
or initializer .global_config .encryption_spec_key_name ,
2167
2176
sync = sync ,
2168
2177
deploy_request_timeout = deploy_request_timeout ,
2178
+ autoscaling_target_cpu_utilization = autoscaling_target_cpu_utilization ,
2179
+ autoscaling_target_accelerator_duty_cycle = autoscaling_target_accelerator_duty_cycle ,
2169
2180
)
2170
2181
2171
2182
@base .optional_sync (return_input_arg = "endpoint" , bind_future_to_self = False )
@@ -2187,6 +2198,8 @@ def _deploy(
2187
2198
encryption_spec_key_name : Optional [str ] = None ,
2188
2199
sync : bool = True ,
2189
2200
deploy_request_timeout : Optional [float ] = None ,
2201
+ autoscaling_target_cpu_utilization : Optional [int ] = None ,
2202
+ autoscaling_target_accelerator_duty_cycle : Optional [int ] = None ,
2190
2203
) -> Endpoint :
2191
2204
"""Deploys model to endpoint. Endpoint will be created if unspecified.
2192
2205
@@ -2271,6 +2284,13 @@ def _deploy(
2271
2284
be immediately returned and synced when the Future has completed.
2272
2285
deploy_request_timeout (float):
2273
2286
Optional. The timeout for the deploy request in seconds.
2287
+ autoscaling_target_cpu_utilization (int):
2288
+ Target CPU Utilization to use for Autoscaling Replicas.
2289
+ A default value of 60 will be used if not specified.
2290
+ autoscaling_target_accelerator_duty_cycle (int):
2291
+ Target Accelerator Duty Cycle.
2292
+ Must also set accelerator_type and accelerator_count if specified.
2293
+ A default value of 60 will be used if not specified.
2274
2294
Returns:
2275
2295
endpoint ("Endpoint"):
2276
2296
Endpoint with the deployed model.
@@ -2306,6 +2326,8 @@ def _deploy(
2306
2326
explanation_parameters = explanation_parameters ,
2307
2327
metadata = metadata ,
2308
2328
deploy_request_timeout = deploy_request_timeout ,
2329
+ autoscaling_target_cpu_utilization = autoscaling_target_cpu_utilization ,
2330
+ autoscaling_target_accelerator_duty_cycle = autoscaling_target_accelerator_duty_cycle ,
2309
2331
)
2310
2332
2311
2333
_LOGGER .log_action_completed_against_resource ("model" , "deployed" , endpoint )
0 commit comments