MCPcopy
hub / github.com/tensorlayer/TensorLayer / fire_block

Function fire_block

tensorlayer/models/squeezenetv1.py:24–31  ·  view source on GitHub ↗
(n, n_filter, max_pool=False, name='fire_block')

Source from the content-addressed store, hash-verified

22
23
24def fire_block(n, n_filter, max_pool=False, name='fire_block'):
25 n = Conv2d(n_filter, (1, 1), (1, 1), tf.nn.relu, 'SAME', name=name + '.squeeze1x1')(n)
26 n1 = Conv2d(n_filter * 4, (1, 1), (1, 1), tf.nn.relu, 'SAME', name=name + '.expand1x1')(n)
27 n2 = Conv2d(n_filter * 4, (3, 3), (1, 1), tf.nn.relu, 'SAME', name=name + '.expand3x3')(n)
28 n = Concat(-1, name=name + '.concat')([n1, n2])
29 if max_pool:
30 n = MaxPool2d((3, 3), (2, 2), 'VALID', name=name + '.max')(n)
31 return n
32
33
34def restore_params(network, path='models'):

Callers 1

SqueezeNetV1Function · 0.85

Calls 3

Conv2dClass · 0.90
ConcatClass · 0.90
MaxPool2dClass · 0.90

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…