Python nets.inception.inception_resnet_v2_arg_scope() Examples
The following are 8
code examples of nets.inception.inception_resnet_v2_arg_scope().
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example.
You may also want to check out all available functions/classes of the module
nets.inception
, or try the search function
.
Example #1
Source File: inception_resnet_v2_test.py From MAX-Image-Segmenter with Apache License 2.0 | 5 votes |
def testNoBatchNormScaleByDefault(self): height, width = 299, 299 num_classes = 1000 inputs = tf.placeholder(tf.float32, (1, height, width, 3)) with tf.contrib.slim.arg_scope(inception.inception_resnet_v2_arg_scope()): inception.inception_resnet_v2(inputs, num_classes, is_training=False) self.assertEqual(tf.global_variables('.*/BatchNorm/gamma:0$'), [])
Example #2
Source File: inception_resnet_v2_test.py From MAX-Image-Segmenter with Apache License 2.0 | 5 votes |
def testBatchNormScale(self): height, width = 299, 299 num_classes = 1000 inputs = tf.placeholder(tf.float32, (1, height, width, 3)) with tf.contrib.slim.arg_scope( inception.inception_resnet_v2_arg_scope(batch_norm_scale=True)): inception.inception_resnet_v2(inputs, num_classes, is_training=False) gamma_names = set( v.op.name for v in tf.global_variables('.*/BatchNorm/gamma:0$')) self.assertGreater(len(gamma_names), 0) for v in tf.global_variables('.*/BatchNorm/moving_mean:0$'): self.assertIn(v.op.name[:-len('moving_mean')] + 'gamma', gamma_names)
Example #3
Source File: inception_resnet_v2_test.py From MAX-Object-Detector with Apache License 2.0 | 5 votes |
def testNoBatchNormScaleByDefault(self): height, width = 299, 299 num_classes = 1000 inputs = tf.placeholder(tf.float32, (1, height, width, 3)) with tf.contrib.slim.arg_scope(inception.inception_resnet_v2_arg_scope()): inception.inception_resnet_v2(inputs, num_classes, is_training=False) self.assertEqual(tf.global_variables('.*/BatchNorm/gamma:0$'), [])
Example #4
Source File: inception_resnet_v2_test.py From MAX-Object-Detector with Apache License 2.0 | 5 votes |
def testBatchNormScale(self): height, width = 299, 299 num_classes = 1000 inputs = tf.placeholder(tf.float32, (1, height, width, 3)) with tf.contrib.slim.arg_scope( inception.inception_resnet_v2_arg_scope(batch_norm_scale=True)): inception.inception_resnet_v2(inputs, num_classes, is_training=False) gamma_names = set( v.op.name for v in tf.global_variables('.*/BatchNorm/gamma:0$')) self.assertGreater(len(gamma_names), 0) for v in tf.global_variables('.*/BatchNorm/moving_mean:0$'): self.assertIn(v.op.name[:-len('moving_mean')] + 'gamma', gamma_names)
Example #5
Source File: inception_resnet_v2_test.py From g-tensorflow-models with Apache License 2.0 | 5 votes |
def testNoBatchNormScaleByDefault(self): height, width = 299, 299 num_classes = 1000 inputs = tf.placeholder(tf.float32, (1, height, width, 3)) with tf.contrib.slim.arg_scope(inception.inception_resnet_v2_arg_scope()): inception.inception_resnet_v2(inputs, num_classes, is_training=False) self.assertEqual(tf.global_variables('.*/BatchNorm/gamma:0$'), [])
Example #6
Source File: inception_resnet_v2_test.py From g-tensorflow-models with Apache License 2.0 | 5 votes |
def testBatchNormScale(self): height, width = 299, 299 num_classes = 1000 inputs = tf.placeholder(tf.float32, (1, height, width, 3)) with tf.contrib.slim.arg_scope( inception.inception_resnet_v2_arg_scope(batch_norm_scale=True)): inception.inception_resnet_v2(inputs, num_classes, is_training=False) gamma_names = set( v.op.name for v in tf.global_variables('.*/BatchNorm/gamma:0$')) self.assertGreater(len(gamma_names), 0) for v in tf.global_variables('.*/BatchNorm/moving_mean:0$'): self.assertIn(v.op.name[:-len('moving_mean')] + 'gamma', gamma_names)
Example #7
Source File: inception_resnet_v2_test.py From models with Apache License 2.0 | 5 votes |
def testNoBatchNormScaleByDefault(self): height, width = 299, 299 num_classes = 1000 inputs = tf.placeholder(tf.float32, (1, height, width, 3)) with slim.arg_scope(inception.inception_resnet_v2_arg_scope()): inception.inception_resnet_v2(inputs, num_classes, is_training=False) self.assertEqual(tf.global_variables('.*/BatchNorm/gamma:0$'), [])
Example #8
Source File: inception_resnet_v2_test.py From models with Apache License 2.0 | 5 votes |
def testBatchNormScale(self): height, width = 299, 299 num_classes = 1000 inputs = tf.placeholder(tf.float32, (1, height, width, 3)) with slim.arg_scope( inception.inception_resnet_v2_arg_scope(batch_norm_scale=True)): inception.inception_resnet_v2(inputs, num_classes, is_training=False) gamma_names = set( v.op.name for v in tf.global_variables('.*/BatchNorm/gamma:0$')) self.assertGreater(len(gamma_names), 0) for v in tf.global_variables('.*/BatchNorm/moving_mean:0$'): self.assertIn(v.op.name[:-len('moving_mean')] + 'gamma', gamma_names)