Skip to content

Rebase DBraun/sequence-layers mlx.001 onto main; bump to 0.3.dev1#15

Closed
JulianSlzr wants to merge 17 commits into
google:mainfrom
JulianSlzr:mlx.001
Closed

Rebase DBraun/sequence-layers mlx.001 onto main; bump to 0.3.dev1#15
JulianSlzr wants to merge 17 commits into
google:mainfrom
JulianSlzr:mlx.001

Conversation

@JulianSlzr
Copy link
Copy Markdown
Collaborator

Rebases @DBraun's MLX fork onto sequence-layers 0.02 as an initial next version.

Temporary measure before the refactor (#14) for downstream SL MLX users.

DBraun and others added 17 commits June 2, 2026 02:30
commit f2f2198
Author: David Braun <2096055+DBraun@users.noreply.github.com>
Date:   Thu Feb 26 09:06:30 2026 -0500

    remove depthformer and moshi_demo.py

commit 74669fc
Author: Kehang Han <kehanghan@gmail.com>
Date:   Wed Feb 25 15:15:26 2026 -0800

    This commit finally makes MLX generate good music!

commit 9e4a452
Author: Kehang Han <kehanghan@gmail.com>
Date:   Wed Feb 25 12:47:09 2026 -0800

    Changes to make temporal output match between jax and mlx

commit 8d267f2
Author: David Braun <2096055+DBraun@users.noreply.github.com>
Date:   Wed Feb 25 12:45:53 2026 -0500

    Update weight_converter.py

commit 68add71
Author: David Braun <2096055+DBraun@users.noreply.github.com>
Date:   Wed Feb 25 12:41:52 2026 -0500

    MLX attention: add per_dim_scale

commit b4ae905
Author: David Braun <2096055+DBraun@users.noreply.github.com>
Date:   Wed Feb 25 11:31:02 2026 -0500

    Update normalization.py

commit a3e84cf
Author: Kehang Han <kehanghan@gmail.com>
Date:   Tue Feb 24 16:04:27 2026 -0800

    To make encoded approx bit level compatible

commit c6596c7
Author: Kehang Han <kehanghan@gmail.com>
Date:   Tue Feb 24 14:35:16 2026 -0800

    Updates to MLX port of SL to support magenta-rt

commit 08077bb
Author: David Braun <2096055+DBraun@users.noreply.github.com>
Date:   Tue Feb 24 08:54:43 2026 -0500

    Create moshi_demo.py
use mx.fast.scaled_dot_product_attention
use mx.fast.rope
These tests exercise the DotProductSelfAttention KV cache ring buffer
with time > max_past_horizon, causing buffer wrap-around. They expose
a write-before-read bug: the current code overwrites the oldest key in
the attention window before queries can attend to it, even with
block_size=1.

Failures:
- test_use_kv_cache_ringbuffer: 33.3% element mismatch at time=6
- LocalDotProductSelfAttention.test_layer: 19.4% element mismatch at time=10

The following commit fixes these by implementing write-after-read.
Includes:
- Expanded sweep for KV cache ringbuffer test with max_future_horizon=0.
- Restored informative comments about ring buffer and mask logic.
TAG=agy

CONV=21ada17b-3411-4090-8450-e69d8ebfeae6
@JulianSlzr JulianSlzr requested a review from rryan June 2, 2026 02:58
@JulianSlzr JulianSlzr closed this Jun 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants