Skip to content

flax switch error #16250

Answered by jakevdp
jakubMitura14 asked this question in Q&A
Jun 4, 2023 · 1 comments · 1 reply
Discussion options

You must be logged in to vote

It's unclear from your partial code, but it appears that main_func_op is a method of a class (because you're referring to it as self.main_func_op) in which case the self argument is implicit so you probably need something like:

nn.switch(indexx, self.main_fun_ops, curried)

This would be easier to answer if you could provide a minimal reproducible example. Also, since since this is a flax-specific question, you'll probably get better answers if you ask at http://github.com/google/flax/

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@jakubMitura14
Comment options

Answer selected by jakubMitura14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants