File tree 1 file changed +2
-1
lines changed 1 file changed +2
-1
lines changed Original file line number Diff line number Diff line change @@ -1641,14 +1641,15 @@ def remove_env_var_from_estimator_kwargs_if_model_access_config_present(
1641
1641
init_kwargs (dict): Dictionary of kwargs when Estimator is instantiated.
1642
1642
accept_eula (Optional[bool]): Whether or not the EULA was accepted, optionally passed in to Estimator.fit().
1643
1643
"""
1644
- if model_access_config is not None and init_kwargs .get ("environment" ) is not None :
1644
+ if model_access_config is not None and init_kwargs .get ("environment" ) is not None and init_kwargs . get ( "model_uri" ) is not None :
1645
1645
if (
1646
1646
constants .SAGEMAKER_GATED_MODEL_S3_URI_TRAINING_ENV_VAR_KEY
1647
1647
in init_kwargs ["environment" ]
1648
1648
):
1649
1649
del init_kwargs ["environment" ][
1650
1650
constants .SAGEMAKER_GATED_MODEL_S3_URI_TRAINING_ENV_VAR_KEY
1651
1651
]
1652
+ del init_kwargs ["environment" ]["accept_eula" ]
1652
1653
1653
1654
1654
1655
def get_hub_access_config (hub_content_arn : Optional [str ]):
You can’t perform that action at this time.
0 commit comments