diff --git a/tests/test_TFNetworkRecLayer.py b/tests/test_TFNetworkRecLayer.py index 6db0e3d6b4..8b4ed3d592 100644 --- a/tests/test_TFNetworkRecLayer.py +++ b/tests/test_TFNetworkRecLayer.py @@ -3361,12 +3361,14 @@ def check_reclayer_optimize_out(subnet_layer_dict, other_subnet_layers=None, sha with make_scope() as session: print("Create non-optimized rec layer (with subnet layer moved out)") rec_layer_dict["optimize_move_layers_out"] = False + rec_layer_dict["unit"]["window"]["class"] = "slice_nd" net1 = TFNetwork(config=config, train_flag=True, name="") if shared_base_net: net1.construct_from_dict(shared_base_net) for key in shared_base_net: assert key in net1.layers net1.construct_from_dict({"output_not_opt": rec_layer_dict}) + rec_layer_dict["unit"]["window"]["class"] = "slice_nd2" rec_layer_dict["optimize_move_layers_out"] = True print("Create optimized rec layer (with subnet layer inside loop)") net2 = TFNetwork(config=config, extern_data=net1.extern_data, train_flag=True, name="") @@ -3611,7 +3613,7 @@ def random_start_positions(source, **kwargs): from_="position", other_subnet_layers={ "my_layer": {"class": "gather_nd", "from": "base:data", "position": ":i"}, - "window": {"class": "slice_nd2", # no_opt: [B,4,D], opt: [B,T,4,D] + "window": {"class": "slice_nd", # no_opt: [B,4,D], opt: [B,T,4,D] "from": "base:data", "start": "data:source", "size": 4, "is_output_layer": True}, }, shared_base_net={