keras-team / keras

Deep Learning for humans
http://keras.io/
Apache License 2.0
62.12k stars 19.49k forks source link

Improve the consistency of the names of initializers #20484

Closed james77777778 closed 1 week ago

james77777778 commented 1 week ago

Fix #20483

This PR renames OrthogonalInitializer to Orthogonal and STFTInitializer to STFT for name consistency and adds serialization tests to prevent future breakages.

This PR also adds a default value side="real" to support calls to initializers.get("STFT")

codecov-commenter commented 1 week ago

Codecov Report

Attention: Patch coverage is 68.75000% with 5 lines in your changes missing coverage. Please review.

Project coverage is 82.08%. Comparing base (c4314a9) to head (e6b3183).

Files with missing lines Patch % Lines
keras/api/_tf_keras/keras/initializers/__init__.py 0.00% 5 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #20484 +/- ## ========================================== - Coverage 82.08% 82.08% -0.01% ========================================== Files 515 515 Lines 47539 47543 +4 Branches 7455 7455 ========================================== + Hits 39022 39024 +2 - Misses 6707 6709 +2 Partials 1810 1810 ``` | [Flag](https://app.codecov.io/gh/keras-team/keras/pull/20484/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=keras-team) | Coverage Δ | | |---|---|---| | [keras](https://app.codecov.io/gh/keras-team/keras/pull/20484/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=keras-team) | `81.93% <68.75%> (-0.01%)` | :arrow_down: | | [keras-jax](https://app.codecov.io/gh/keras-team/keras/pull/20484/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=keras-team) | `65.02% <68.75%> (-0.01%)` | :arrow_down: | | [keras-numpy](https://app.codecov.io/gh/keras-team/keras/pull/20484/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=keras-team) | `59.98% <68.75%> (-0.01%)` | :arrow_down: | | [keras-tensorflow](https://app.codecov.io/gh/keras-team/keras/pull/20484/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=keras-team) | `66.04% <68.75%> (-0.01%)` | :arrow_down: | | [keras-torch](https://app.codecov.io/gh/keras-team/keras/pull/20484/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=keras-team) | `64.95% <68.75%> (-0.01%)` | :arrow_down: | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=keras-team#carryforward-flags-in-the-pull-request-comment) to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.