What is the equivalent of nn.map_variables
in the nnx
API?
#4464
Answered
by
cgarciae
carlesoctav
asked this question in
General
-
What is the equivalent of |
Beta Was this translation helpful? Give feedback.
Answered by
cgarciae
Dec 24, 2024
Replies: 1 comment
-
@carlesoctav you mimic |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
carlesoctav
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
@carlesoctav you mimic
map_variables
usingnnx.split
to get the pytree state andnnx.update
to update the Module after you've modified the state. See https://flax.readthedocs.io/en/latest/nnx_basics.html#the-flax-functional-api.