-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Reduces latency of rendering Jax arrays.
Before: Cold rendering array of any size would take ~15-25 seconds (in colab). Now: Cold rendering of small-ish (less than 10M bytes) arrays is instantaneous (<< 1s) Larger arrays (e.g. > 2K x 2K) take 3-4 seconds, which is much more manageable To do this we do two things: a) We convert to numpy for arrays smaller than 10M for computing stats and doing slicing. (We still maintain jax visualization of sharding and types) b) We use a single jitted function for arrays larger than 10m to compute summaries rather than individual jax invocations for each stat, which end up jitted separately. PiperOrigin-RevId: 681055675
- Loading branch information
1 parent
c05b5fe
commit 438b9a5
Showing
2 changed files
with
148 additions
and
91 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters