-
From the docs it seems that def f(x, y):
... Let's say we My understanding is that cache hits for However, what does it use to compute cache hits when |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
The rough mental model is this: if you pass a pytree children, treedef = tree_util.tree_flatten(y) The |
Beta Was this translation helpful? Give feedback.
The rough mental model is this: if you pass a pytree
y
to the function, then internally the JIT machinery computesThe
children
are treated as dynamic arguments, whiletreedef
(and all the pytree auxilary data it contains) is treated as a static argument, with its hash being rolled into the JIT cache key.