Created a class contains a number of nn.Modules. Looks like doing so adds a prefix to state_dict keys. Is there a way to specify a prefix during load_state_dict () ? Or what is the recommended way to hande such situation ?
You could create a new
dict by assigning the
state_dict keys and values to the new keys with the desired prefix.