View source on GitHub |
Creates a tff.Type
from a tff.learning.models.VariableModel
or callable that constructs a model.
tff.learning.models.weights_type_from_model(
model: Union[tff.learning.models.VariableModel
, Callable[[], tff.learning.models.VariableModel
]]
) -> tff.types.StructType
Args | |
---|---|
model
|
A tff.learning.models.VariableModel instance, or a no-arg callable
that returns a model.
|
Returns | |
---|---|
A tff.StructType representing the TFF type of the ModelWeights
structure for model .
|