From 84b3001405c1d6301eb564663bb75f48bea45239 Mon Sep 17 00:00:00 2001
From: Felix Kleinert <f.kleinert@fz-juelich.de>
Date: Fri, 28 Feb 2020 09:55:47 +0100
Subject: [PATCH] update tests for naming of concat layers at the end of each
 inception block

---
 test/test_model_modules/test_inception_model.py | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/test/test_model_modules/test_inception_model.py b/test/test_model_modules/test_inception_model.py
index aa5cb284..ae227184 100644
--- a/test/test_model_modules/test_inception_model.py
+++ b/test/test_model_modules/test_inception_model.py
@@ -152,6 +152,10 @@ class TestInceptionModelBase:
         assert self.step_in(block_1b._keras_history[0]).name == "Block_1b_5x5"
         assert isinstance(self.step_in(block_pool1._keras_history[0], depth=2), keras.layers.pooling.MaxPooling2D)
         assert isinstance(self.step_in(block_pool2._keras_history[0], depth=2), keras.layers.pooling.AveragePooling2D)
+        # check naming of concat layer
+        assert block.name == 'Block_1_Co/concat:0'
+        assert block._keras_history[0].name == 'Block_1_Co'
+        assert isinstance(block._keras_history[0], keras.layers.merge.Concatenate)
         # next block
         opts['input_x'] = block
         opts['tower_pool_parts']['max_pooling'] = True
@@ -166,6 +170,10 @@ class TestInceptionModelBase:
         assert self.step_in(block_2a._keras_history[0]).name == "Block_2a_3x3"
         assert self.step_in(block_2b._keras_history[0]).name == "Block_2b_5x5"
         assert isinstance(self.step_in(block_pool._keras_history[0], depth=2), keras.layers.pooling.MaxPooling2D)
+        # check naming of concat layer
+        assert block.name == 'Block_2_Co/concat:0'
+        assert block._keras_history[0].name == 'Block_2_Co'
+        assert isinstance(block._keras_history[0], keras.layers.merge.Concatenate)
 
     def test_batch_normalisation(self, base, input_x):
         base.part_of_block += 1
-- 
GitLab