Home
last modified time | relevance | path

Searched refs:image_shape (Results 1 – 25 of 26) sorted by relevance

12

/external/tensorflow/tensorflow/python/kernel_tests/
Dmorphological_ops_test.py185 def _ConstructAndTestGradient(self, image_shape, kernel_shape, strides, rates, argument
197 assert image_shape[3] == kernel_shape[2]
200 image = np.random.random_sample(image_shape).astype(np.float32)
202 image_init = np.random.random_sample(image_shape).astype(np.float32)
210 image, shape=image_shape, name="input")
224 [image_tensor, kernel_tensor], [image_shape, kernel_shape],
234 image_shape=[1, 3, 3, 1],
243 image_shape=[1, 3, 3, 1],
252 image_shape=[1, 3, 3, 2],
261 image_shape=[1, 3, 3, 1],
[all …]
/external/tensorflow/tensorflow/contrib/gan/python/eval/python/
Deval_utils_impl.py34 def image_grid(input_tensor, grid_shape, image_shape=(32, 32), num_channels=3): argument
59 num_features = image_shape[0] * image_shape[1] * num_channels
64 if (int(input_tensor.shape[1]) != image_shape[0] or
65 int(input_tensor.shape[2]) != image_shape[1] or
71 height, width = grid_shape[0] * image_shape[0], grid_shape[1] * image_shape[1]
73 input_tensor, tuple(grid_shape) + tuple(image_shape) + (num_channels,))
76 input_tensor, [grid_shape[0], width, image_shape[0], num_channels])
Dsummaries_impl.py76 image_shape=real_image_shape,
84 image_shape=generated_image_shape,
/external/tensorflow/tensorflow/contrib/slim/python/slim/data/
Dtfexample_decoder_test.py77 def GenerateImage(self, image_format, image_shape, image_dtype=np.uint8): argument
93 num_pixels = image_shape[0] * image_shape[1] * image_shape[2]
96 num=num_pixels).reshape(image_shape).astype(image_dtype)
143 image_shape = (2, 3, 3)
145 image_format='jpeg', image_shape=image_shape)
156 image_shape = (2, 3, channels)
158 image_format='JPEG', image_shape=image_shape)
171 image_shape = (2, 3, channels)
173 image_format='jpeg', image_shape=image_shape)
184 image_shape = (2, 3, channels)
[all …]
Dtest_utils.py62 def generate_image(image_shape, image_format='jpeg', label=0): argument
78 image = np.random.random_integers(0, 255, size=image_shape)
110 _, example = generate_image(image_shape=(10, 10, 3))
/external/tensorflow/tensorflow/python/ops/
Dimage_grad.py40 image_shape = image.get_shape()[1:3]
42 image_shape = array_ops.shape(image)[1:3]
46 image_shape,
132 image_shape = image.get_shape().as_list()
134 image_shape = array_ops.shape(image)
140 grad, op.inputs[1], op.inputs[2], image_shape, T=op.get_attr("T"),
Dimage_ops_impl.py138 image_shape = image.get_shape().with_rank(3)
142 if require_static and not image_shape.is_fully_defined():
143 raise ValueError("'image' (shape %s) must be fully defined." % image_shape)
144 if any(x == 0 for x in image_shape):
145 raise ValueError("all dims of 'image.shape' must be > 0: %s" % image_shape)
146 if not image_shape.is_fully_defined():
218 image_shape = image.get_shape().with_rank(3)
220 image_shape = image.get_shape().with_rank_at_least(3)
223 if require_static and not image_shape.is_fully_defined():
225 if any(x == 0 for x in image_shape):
[all …]
Dimage_grad_test.py338 image_shape = [batch, image_height, image_width, depth]
343 depth).reshape(image_shape).astype(np.float32)
350 image, shape=image_shape),
417 image_shape = [batch, image_height, image_width, depth]
423 depth).reshape(image_shape).astype(np.float32)
438 image_tensor = constant_op.constant(image, shape=image_shape)
450 [image_tensor, boxes_tensor], [image_shape, boxes_shape],
Dimage_ops_test.py484 image_shape = [299, 299, 3]
494 random_ops.random_uniform(image_shape, dtype=dtypes.float32) * 255,
514 image_shape = [299, 299, 3]
524 random_ops.random_uniform(image_shape, dtype=dtypes.float32) * 255,
544 image_shape = [16, 299, 299, 3]
554 random_ops.random_uniform(image_shape, dtype=dtypes.float32) * 255,
605 image_shape = [299, 299, 3]
614 random_ops.random_uniform(image_shape, dtype=dtypes.float32) * 255,
648 image_shape = [299, 299, 3]
657 random_ops.random_uniform(image_shape, dtype=dtypes.float32) * 255,
[all …]
/external/tensorflow/tensorflow/core/kernels/
Dextract_jpeg_shape_op.cc57 Tensor* image_shape = nullptr; in Compute() local
59 context->allocate_output(0, TensorShape({3}), &image_shape)); in Compute()
60 auto image_shape_data = image_shape->tensor<T, 1>(); in Compute()
/external/tensorflow/tensorflow/contrib/image/python/kernel_tests/
Ddense_image_warp_test.py87 image_shape = [batch_size, height, width, numchannels]
96 image = array_ops.placeholder(dtype=tf_type[image_type], shape=image_shape)
103 image_shape = [batch_size, height, width, numchannels]
104 image = np.random.normal(size=image_shape)
238 image_shape = [batch_size, height, width, numchannels]
239 image = random_ops.random_normal(image_shape)
Ddistort_image_ops_test.py257 image_shape = [299, 299, 3]
267 random_ops.random_uniform(image_shape, dtype=dtypes.float32) * 255,
301 image_shape = [299, 299, 3]
311 random_ops.random_uniform(image_shape, dtype=dtypes.float32) * 255,
/external/tensorflow/tensorflow/contrib/eager/python/examples/resnet50/
Dresnet50_graph_test.py35 def image_shape(batch_size): function
42 images = np.random.rand(*image_shape(batch_size)).astype(np.float32)
58 images = tf.placeholder(tf.float32, image_shape(None))
72 images = tf.placeholder(tf.float32, image_shape(None), name='images')
119 images = tf.placeholder(tf.float32, image_shape(None))
/external/tensorflow/tensorflow/contrib/eager/python/examples/densenet/
Ddensenet_graph_test.py32 def image_shape(batch_size): function
39 images = np.random.rand(*image_shape(batch_size)).astype(np.float32)
58 images = tf.placeholder(tf.float32, image_shape(None))
94 images = tf.placeholder(tf.float32, image_shape(None))
/external/tensorflow/tensorflow/python/profiler/internal/
Dflops_registry.py422 image_shape = graph_util.tensor_shape_from_node_def_name(graph, node.input[0])
423 image_shape.assert_is_fully_defined()
431 (2 * image_shape.num_elements()
433 / (image_shape.dims[-1].value * strides_product)))
/external/tensorflow/tensorflow/contrib/distributions/python/kernel_tests/
Dindependent_test.py227 image_shape = [28, 28, 1]
229 batch_shape + image_shape).astype(np.float32) - 1
264 self.assertAllEqual(image_shape, ind_event_shape)
265 self.assertAllEqual(sample_shape + batch_shape + image_shape, x_shape)
/external/tensorflow/tensorflow/cc/gradients/
Dimage_grad.cc113 auto image_shape = Shape(scope, op.input(0)); in CropAndResizeGradHelper() local
115 scope, grad_inputs[0], op.input(1), op.input(2), image_shape, input_type, in CropAndResizeGradHelper()
/external/tensorflow/tensorflow/contrib/layers/python/layers/
Dlayers_test.py2016 image_shape = (batch_size, height, width, channels)
2018 image_values = np.random.rand(*image_shape)
2023 image_values, shape=image_shape, dtype=dtypes.float32)
2063 image_shape = (batch_size, height, width, channels)
2066 image_shape = (batch_size, channels, height, width)
2068 image_values = np.random.rand(*image_shape)
2076 image_values, shape=image_shape, dtype=dtypes.float32)
2147 image_shape = (batch_size, height, width, channels)
2150 image_shape = (batch_size, channels, height, width)
2152 image_values = np.random.rand(*image_shape)
[all …]
Dnormalization_test.py105 image_shape = (10, height, width, 3)
106 images = random_ops.random_uniform(image_shape, seed=1)
294 image_shape = (10, height, width, 4)
295 images = random_ops.random_uniform(image_shape, seed=1)
/external/tensorflow/tensorflow/core/grappler/costs/
Dop_level_cost_estimator.cc579 auto image_shape = in ConvolutionDimensionsFromInputs() local
583 VLOG(2) << "Image shape: " << image_shape.DebugString(); in ConvolutionDimensionsFromInputs()
612 int64 batch = image_shape.dim(0).size(); in ConvolutionDimensionsFromInputs()
613 int64 ix = image_shape.dim(x_index).size(); in ConvolutionDimensionsFromInputs()
614 int64 iy = image_shape.dim(y_index).size(); in ConvolutionDimensionsFromInputs()
615 int64 iz = image_shape.dim(channel_index).size(); in ConvolutionDimensionsFromInputs()
1444 auto image_shape = in OpDimensionsFromInputs() local
1446 VLOG(2) << "Image shape: " << image_shape.DebugString(); in OpDimensionsFromInputs()
1459 int64 batch = image_shape.dim(0).size(); in OpDimensionsFromInputs()
1460 int64 ix = image_shape.dim(x_index).size(); in OpDimensionsFromInputs()
[all …]
/external/tensorflow/tensorflow/core/api_def/base_api/
Dapi_def_ExtractJpegShape.pbtxt10 name: "image_shape"
/external/tensorflow/tensorflow/c/
Dc_api_experimental.cc8413 auto image_shape = tensorflow::TensorShapeProto(); in TF_MakeFileBasedIteratorGetNextWithDatasets()
8414 image_shape.add_dim()->set_size(batch_size); in TF_MakeFileBasedIteratorGetNextWithDatasets()
8416 image_shape.add_dim()->set_size(784); in TF_MakeFileBasedIteratorGetNextWithDatasets()
8418 image_shape.add_dim()->set_size(224); in TF_MakeFileBasedIteratorGetNextWithDatasets()
8419 image_shape.add_dim()->set_size(224); in TF_MakeFileBasedIteratorGetNextWithDatasets()
8420 image_shape.add_dim()->set_size(3); in TF_MakeFileBasedIteratorGetNextWithDatasets()
8422 output_shape_list.push_back(image_shape); in TF_MakeFileBasedIteratorGetNextWithDatasets()
/external/tensorflow/tensorflow/go/op/
Dwrappers.go36825 …Shape(scope *Scope, contents tf.Output, optional ...ExtractJpegShapeAttr) (image_shape tf.Output) {
/external/tensorflow/tensorflow/core/ops/
Dops.pbtxt12454 name: "image_shape"
/external/tensorflow/tensorflow/core/ops/compat/
Dops_history.v1.pbtxt25520 name: "image_shape"

12