Skip to content

Commit

Permalink
Remove failing end2end test
Browse files Browse the repository at this point in the history
  • Loading branch information
lgeiger committed Apr 6, 2022
1 parent bc3072c commit 4a20312
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions larq_compute_engine/tests/end2end_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -229,22 +229,20 @@ def test_simple_model(dataset, conversion_function, model_cls):
@pytest.mark.parametrize(
"conversion_function", [convert_keras_model, convert_keras_model_as_saved_model]
)
@pytest.mark.parametrize("model_cls", [toy_model, toy_model_int8])
@pytest.mark.parametrize("inference_input_type", [tf.int8, tf.float32])
@pytest.mark.parametrize("inference_output_type", [tf.int8, tf.float32])
def test_int8_input_output(
conversion_function, model_cls, inference_input_type, inference_output_type
conversion_function, inference_input_type, inference_output_type
):
if conversion_function == convert_keras_model_as_saved_model and (
model_cls == toy_model or version.parse(tf.__version__) < version.parse("2.2")
version.parse(tf.__version__) < version.parse("2.2")
):
pytest.skip("convert_keras_model_as_saved_model currently fails in this case.")
pytest.skip("TensorFlow 2.2 or newer is required for saved model conversion.")

model_lce = conversion_function(
model_cls(),
toy_model_int8(),
inference_input_type=inference_input_type,
inference_output_type=inference_output_type,
experimental_default_int8_range=(-6.0, 6.0) if model_cls == toy_model else None,
)
interpreter = tf.lite.Interpreter(model_content=model_lce)
input_details = interpreter.get_input_details()
Expand Down

0 comments on commit 4a20312

Please sign in to comment.