LudovicoYIN opened a new pull request, #19632: URL: https://github.com/apache/tvm/pull/19632
## Summary Add Relax TFLite frontend support for `RNN` (BuiltinOperator 23), claimed in [#19519](https://github.com/apache/tvm/issues/19519) Group A. Single-step RNN cell: ``` h = fused_activation(x @ W.T + h @ Wr.T + b) ``` ## Changes - **Handler**: `convert_rnn` registered in `convert_map` (alphabetical, after `RANGE`) - **Inputs** (5): `input [batch, input_size]`, `input_weights [num_units, input_size]`, `recurrent_weights [num_units, num_units]`, `bias [num_units]`, `hidden_state [batch, num_units]` (variable, zero-initialised) - **Output**: `[batch, num_units]` - **Activations**: all fused activations via `convert_fused_activation_function` - **Quantized**: raises `OpNotImplemented` ## Testing Two tests added to `tests/python/relax/test_frontend_tflite.py`: - `test_rnn_none_activation` — `tvm.ir.assert_structural_equal` with identity weights, NONE activation - `test_rnn_relu_activation` — shape check, random weights, RELU activation ```bash python -m pytest tests/python/relax/test_frontend_tflite.py -k rnn -v ``` ## References - Issue [#19519](https://github.com/apache/tvm/issues/19519) Group A: Sequence / recurrent model operators -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
