Commit 2309fdd
Add support for many additional Keras 3 layers
Restored recurrent layers (LSTM, GRU, SimpleRNN, Bidirectional) that were
removed in commit a60717c when Keras 3 broke the previous implementation,
and added a broad set of layers that had been listed as unsupported.
New layers:
- LSTM, GRU, SimpleRNN, Bidirectional (all merge_modes)
- ConvLSTM1D, ConvLSTM2D, ConvLSTM3D
- RNN wrapping LSTMCell / GRUCell / SimpleRNNCell / StackedRNNCells
- EinsumDense (generic einsum interpreter)
- GroupedQueryAttention (with optional use_gate)
- AdaptiveAvg/MaxPooling 1D/2D/3D
- DepthwiseConv1D
- RMSNormalization, GroupNormalization
- Discretization, IntegerLookup
- Masking (passthrough; mask propagation through recurrent layers is not modeled)
- Many training-only image-augmentation layers as identity passthroughs
(RandomBrightness, RandomCrop, RandomHue, AugMix, CutMix, MixUp,
RandAugment, AutoContrast, etc.)
Caveats:
- Stateful recurrent layers and return_state-as-input remain unsupported.
- ConvLSTM go_backwards / unroll / stateful remain unsupported.
- GroupNormalization currently only supports axis=-1.
A new test_model_recurrent test target exercises each new layer with
multiple distinct configurations.
README: pruned stale unsupported entries (ThresholdedReLU,
LocallyConnected1D/2D, CuDNNGRU/LSTM) that were removed in Keras 3.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>1 parent 02eb663 commit 2309fdd
23 files changed
Lines changed: 2724 additions & 20 deletions
File tree
- include/fdeep
- layers
- keras_export
- test
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
41 | 41 | | |
42 | 42 | | |
43 | 43 | | |
| 44 | + | |
44 | 45 | | |
45 | | - | |
| 46 | + | |
46 | 47 | | |
47 | 48 | | |
48 | | - | |
| 49 | + | |
49 | 50 | | |
50 | 51 | | |
51 | | - | |
52 | | - | |
53 | | - | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
54 | 59 | | |
55 | 60 | | |
56 | 61 | | |
57 | 62 | | |
58 | | - | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
59 | 69 | | |
60 | 70 | | |
61 | 71 | | |
| |||
71 | 81 | | |
72 | 82 | | |
73 | 83 | | |
74 | | - | |
75 | | - | |
76 | | - | |
77 | | - | |
78 | | - | |
79 | | - | |
80 | | - | |
81 | | - | |
82 | | - | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
83 | 89 | | |
84 | 90 | | |
85 | 91 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
11 | 11 | | |
12 | 12 | | |
13 | 13 | | |
14 | | - | |
15 | 14 | | |
16 | 15 | | |
17 | 16 | | |
18 | 17 | | |
19 | 18 | | |
20 | 19 | | |
| 20 | + | |
21 | 21 | | |
22 | 22 | | |
23 | 23 | | |
| |||
0 commit comments