snowflake.ml.model.model_signature.ParamGroupSpec¶
- class snowflake.ml.model.model_signature.ParamGroupSpec(name: str, specs: list[snowflake.ml.model._signatures.core.BaseParamSpec], shape: Optional[tuple[int, ...]] = None)¶
Bases:
BaseParamSpecSpecification of a group of parameters in Snowflake native model packaging.
Initialize a parameter group.
- Parameters:
name – Name of the parameter group.
specs – A list of parameter specifications that composes the group.
shape – Shape of the parameter group. None means scalar, otherwise a tuple representing dimensions. Use -1 for variable length dimensions.
Methods
- classmethod from_dict(input_dict: dict[str, Any]) ParamGroupSpec¶
Deserialize the parameter group from a dict.
- Parameters:
input_dict – The dict containing information of the parameter group.
- Returns:
A parameter group instance deserialized and created from the dict.
- to_dict() dict[str, Any]¶
Serialize the parameter group into a dict.
- Returns:
A dict that serializes the parameter group.
Attributes
- name¶
Name of the parameter.
- shape¶
Shape of the parameter. None means scalar.
- specs¶
List of parameter specifications in the group.