Add static, dynamic and training tests for all tf.keras.layers (#3753)
Additional changes:
- `_TfLiteFunctionWrapper`
- only interprets its output as a dict if the expected keys are provided.
it's not really worth trying to write a general this-behaves-like-python
wrapper for TFLite imo.
- has special logic for dealing with keras/tflite eccentricities.
- `lstm_test.py` and `lstm_static_test.py` are deleted in favor of `layers_test.py`.
Currently only settings close to the default for each layer are tested.
This could be expanded out in the future in the form of multiple
unittests for each `bazel` test.
This change adds 850 test targets, 478 of which are passing and will
run on the CI. They all complete in under 35 seconds on my machine,
so the added time from the tests shouldn't be too large.diff --git a/scripts/get_e2e_artifacts.py b/scripts/get_e2e_artifacts.py
index adbd4f7..e62226d 100755
--- a/scripts/get_e2e_artifacts.py
+++ b/scripts/get_e2e_artifacts.py
@@ -43,6 +43,12 @@
'//integrations/tensorflow/e2e:mobile_bert_squad_tests',
'keras_tests':
'//integrations/tensorflow/e2e/keras:keras_tests',
+ 'layers_tests':
+ '//integrations/tensorflow/e2e/keras/layers:layers_tests',
+ 'layers_dynamic_batch_tests':
+ '//integrations/tensorflow/e2e/keras/layers:layers_dynamic_batch_tests',
+ 'layers_training_tests':
+ '//integrations/tensorflow/e2e/keras/layers:layers_training_tests',
'keyword_spotting_tests':
'//integrations/tensorflow/e2e/keras:keyword_spotting_tests',
'keyword_spotting_internal_streaming_tests':