Skip to content

model state manipulation #1448

Discussion options

You must be logged in to vote

I think the question is a bit different. You can create functions that work for each parameter of the module. There is the map and visit functions that exist on Module. You could use burn::tensor::container::TensorContainer to aggregate each parameter and then update the module in question. This is the strategy used in burn-train for gradients accumulation, but this can be used to merge modules as well.

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by antimora
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants
Converted from issue

This discussion was converted from issue #1248 on March 10, 2024 17:48.