set_state_tree: Assigns values to variables of the model.

set_state_treeR Documentation

Assigns values to variables of the model.

Description

This method takes a dictionary (named list) of nested variable values, which represents the state tree of the model, and assigns them to the corresponding variables of the model. The keys (list names) represent the variable names (e.g., 'trainable_variables', 'optimizer_variables'), and the values are nested dictionaries containing the variable paths and their corresponding values.

Usage

set_state_tree(object, state_tree)

Arguments

object

A keras model.

state_tree

A dictionary representing the state tree of the model. The keys are the variable names, and the values are nested dictionaries representing the variable paths and their values.

See Also

Other model functions:
get_config()
get_layer()
get_state_tree()
keras_model()
keras_model_sequential()
pop_layer()
summary.keras.src.models.model.Model()


rstudio/keras documentation built on Feb. 4, 2025, 1:11 p.m.