Skip to content

Add weight_decay_mask to dadapt_adamw, and fix it for prodigy. - #1763

Merged
copybara-service[bot] merged 1 commit into
mainfrom
test_973156449
Aug 30, 2026
Merged

Add weight_decay_mask to dadapt_adamw, and fix it for prodigy.#1763
copybara-service[bot] merged 1 commit into
mainfrom
test_973156449

Conversation

@copybara-service

Copy link
Copy Markdown

Add weight_decay_mask to dadapt_adamw, and fix it for prodigy.

prodigy's weight_decay_mask previously required a mask whose tree structure
exactly matched the params. Masks that were a prefix of the params tree, or a
plain True/False, raised a pytree structure error even though the docstring
documented prefix masks as supported. Both optimizers now route the masking
through optax.add_decayed_weights.

`prodigy`'s `weight_decay_mask` previously required a mask whose tree structure
exactly matched the params. Masks that were a prefix of the params tree, or a
plain `True`/`False`, raised a pytree structure error even though the docstring
documented prefix masks as supported. Both optimizers now route the masking
through `optax.add_decayed_weights`.

PiperOrigin-RevId: 973454596
@copybara-service
copybara-service Bot merged commit d47bc8d into main Aug 30, 2026
4 checks passed
@copybara-service
copybara-service Bot deleted the test_973156449 branch August 30, 2026 14:45
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.

1 participant