einx
einx copied to clipboard
Enable vmap over equinox modules
Resolves #15
This does introduce a dependency to cachetools to use an LRU cache with custom keys.
Further, a dummy pass is still required through any module being vmapped over. In idiomatic equinox code, where modules will quite often vmap over nested modules, this is perhaps not ideal, as it can require manually performing dummy passes over deeply nested modules. Perhaps some further work could be done to allow vmap to automatically trigger a dummy pass on its first call? This could be of use in use cases beyond equinox as well.