@@ -1285,6 +1285,7 @@ def from_json(self, json_obj: Dict[str, Any]) -> None:
12851285 Args:
12861286 json_obj (Dict[str, Any]): Dictionary representation of spec.
12871287 """
1288+ print ("HEYHEYHEY" )
12881289 if self ._is_hub_content :
12891290 json_obj = walk_and_apply_json (json_obj , camel_to_snake )
12901291 self .model_id : str = json_obj .get ("model_id" )
@@ -1361,6 +1362,7 @@ def from_json(self, json_obj: Dict[str, Any]) -> None:
13611362 )
13621363 self .model_kwargs = deepcopy (json_obj .get ("model_kwargs" , {}))
13631364 self .deploy_kwargs = deepcopy (json_obj .get ("deploy_kwargs" , {}))
1365+ print (f'HUH { json_obj .get ("predictor_specs" )} ' )
13641366 self .predictor_specs : Optional [JumpStartPredictorSpecs ] = (
13651367 JumpStartPredictorSpecs (
13661368 json_obj .get ("predictor_specs" ),
@@ -1535,11 +1537,11 @@ def from_json(self, json_obj: Dict[str, Any]) -> None:
15351537 for field in json_obj .keys ():
15361538 if field in self .__slots__ :
15371539 setattr (self , field , json_obj [field ])
1538-
1540+
15391541 # Handle custom fields
1540- for field , custom_field in self .CUSTOM_FIELD_MAP .items ():
1542+ for custom_field , field in self .CUSTOM_FIELD_MAP .items ():
15411543 if field in json_obj :
1542- setattr (self , custom_field , json_obj [field ])
1544+ setattr (self , field , json_obj [custom_field ])
15431545
15441546
15451547class JumpStartMetadataConfig (JumpStartDataHolderType ):
@@ -1732,7 +1734,9 @@ def __init__(self, spec: Dict[str, Any], is_hub_content: Optional[bool] = False)
17321734 spec (Dict[str, Any]): Dictionary representation of spec.
17331735 is_hub_content (Optional[bool]): Whether the model is from a private hub.
17341736 """
1737+ print ("here?" )
17351738 super ().__init__ (spec , is_hub_content )
1739+ print ("hi" )
17361740 self .from_json (spec )
17371741 if self .inference_configs and self .inference_configs .get_top_config_from_ranking ():
17381742 super ().from_json (self .inference_configs .get_top_config_from_ranking ().resolved_config )
0 commit comments