Skip to content

Swapping selected layers with different layers. #3586

Discussion options

You must be logged in to vote

Ah yeah so if you want to really customize JAX you need to write custom interpreters. The JAX tutorials are pretty good (11/10 if we're comparing to most projects, but not 100% of the information you need to be successful).

This is the main one which is relevant: https://jax.readthedocs.io/en/latest/autodidax.html

That being said, if you're looking for something simpler, you can probably write a more restricted version without getting that far down into the weeds. I think targeting only flax Dense layers and making the modification at initialization time should be much simpler. I don't know the best way to do that using FLAX's machinery since I'm a bit more familiar with haiku.

Replies: 2 comments 2 replies

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
2 replies
@davisyoshida
Comment options

Answer selected by aneesh-aparajit
@aneesh-aparajit
Comment options

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