21994919156aac15558f77555538346fb702bcbc,autokeras/nn/graph.py,Graph,_get_pooling_layers,#Graph#Any#Any#,264
Before Change
layer_list = []
node_list = [start_node_id]
self._depth_first_search(end_node_id, layer_list, node_list)
return filter(lambda layer_id: is_layer(self.layer_list[layer_id], "Pooling"), layer_list)
def _depth_first_search(self, target_id, layer_id_list, node_list):
Search for all the layers and nodes down the path.
After Change
layer_list = []
node_list = [start_node_id]
self._depth_first_search(end_node_id, layer_list, node_list)
ret = []
for layer_id in layer_list:
layer = self.layer_list[layer_id]
if is_layer(layer, "Pooling"):
ret.append((layer.kernel_size, layer.stride, layer.padding))
elif is_layer(layer, "Conv") and layer.stride != 1:
ret.append((int((layer.kernel_size + 1) / 2), layer.stride, 0))
return ret
def _depth_first_search(self, target_id, layer_id_list, node_list):
Search for all the layers and nodes down the path.
In pattern: SUPERPATTERN
Frequency: 4
Non-data size: 9
Instances
Project Name: jhfjhfj1/autokeras
Commit Name: 21994919156aac15558f77555538346fb702bcbc
Time: 2018-11-26
Author: jhfjhfj1@gmail.com
File Name: autokeras/nn/graph.py
Class Name: Graph
Method Name: _get_pooling_layers
Project Name: keras-team/autokeras
Commit Name: 21994919156aac15558f77555538346fb702bcbc
Time: 2018-11-26
Author: jhfjhfj1@gmail.com
File Name: autokeras/nn/graph.py
Class Name: Graph
Method Name: deep_layer_ids
Project Name: keras-team/autokeras
Commit Name: 21994919156aac15558f77555538346fb702bcbc
Time: 2018-11-26
Author: jhfjhfj1@gmail.com
File Name: autokeras/nn/graph.py
Class Name: Graph
Method Name: _get_pooling_layers