Home
last modified time | relevance | path

Searched full:layer (Results 1 – 25 of 3829) sorted by relevance

12345678910>>...154

/external/tensorflow/tensorflow/python/layers/
Dbase_test.py47 layer = base_layers.Layer(name='my_layer')
48 self.assertEqual(layer.variables, [])
49 self.assertEqual(layer.trainable_variables, [])
50 self.assertEqual(layer.non_trainable_variables, [])
53 self.assertEqual(layer.updates, [])
54 self.assertEqual(layer.losses, [])
55 self.assertEqual(layer.built, False)
56 layer = base_layers.Layer(name='my_layer', trainable=False)
57 self.assertEqual(layer.trainable, False)
61 layer = base_layers.Layer(name='my_layer', dtype='int64')
[all …]
Dconvolutional_test.py67 layer = conv_layers.Conv2D(32, [3, 3], activation=nn_ops.relu)
68 output = layer.apply(images)
72 self.assertListEqual(layer.kernel.get_shape().as_list(), [3, 3, 4, 32])
73 self.assertListEqual(layer.bias.get_shape().as_list(), [32])
85 layer = conv_layers.Conv2D(32, 3)
86 output = layer.apply(images)
89 self.assertListEqual(layer.kernel.get_shape().as_list(), [3, 3, 4, 32])
90 self.assertListEqual(layer.bias.get_shape().as_list(), [32])
96 layer = conv_layers.Conv2D(32, [3, 3], data_format='channels_first')
97 output = layer.apply(images)
[all …]
Dpooling_test.py57 layer = pooling_layers.MaxPooling2D([2, 2], strides=2)
58 output = layer.apply(images)
64 layer = pooling_layers.AveragePooling2D([2, 2], strides=2)
65 output = layer.apply(images)
72 layer = pooling_layers.MaxPooling2D([2, 2],
75 output = layer.apply(images)
82 layer = pooling_layers.AveragePooling2D((2, 2),
86 output = layer.apply(images)
94 layer = pooling_layers.AveragePooling2D((2, 2),
98 output = layer.apply(images)
[all …]
/external/tensorflow/tensorflow/python/keras/layers/
Dwrappers.py16 """Wrapper layers: layers that augment the functionality of another layer.
26 from tensorflow.python.keras.engine.base_layer import Layer
38 class Wrapper(Layer):
41 Wrappers take another layer and augment it in various ways.
42 Do not use this class as a layer, it is only an abstract base class.
46 layer: The layer to be wrapped.
49 def __init__(self, layer, **kwargs): argument
50 assert isinstance(layer, Layer)
51 self.layer = layer
52 # Tracks mapping of Wrapper inputs to inner layer inputs. Useful when
[all …]
Dwrappers_test.py15 """Tests for layer wrappers."""
34 class _RNNCellWithConstants(keras.layers.Layer):
114 'Please initialize `TimeDistributed` layer with a `Layer` instance.'):
184 layer = keras.layers.TimeDistributed(keras.layers.BatchNormalization())
185 _ = layer(x)
186 self.assertEqual(len(layer.updates), 2)
187 self.assertEqual(len(layer.trainable_weights), 2)
188 layer.trainable = False
189 assert not layer.updates
190 assert not layer.trainable_weights
[all …]
Dlstm_test.py15 """Tests for LSTM layer."""
57 layer = keras.layers.LSTM(units, return_sequences=True)
58 model.add(layer)
67 layer = keras.layers.LSTM(units, input_shape=(None, embedding_dim))
69 model.add(layer)
107 layer = layer_class(
115 layer.build((None, None, embedding_dim))
116 self.assertEqual(layer.cell.kernel.constraint, k_constraint)
117 self.assertEqual(layer.cell.recurrent_kernel.constraint, r_constraint)
118 self.assertEqual(layer.cell.bias.constraint, b_constraint)
[all …]
Dlstm_v2_test.py15 """Tests for UnifiedLSTM layer."""
71 layer = rnn.LSTM(
78 self.assertFalse(layer.could_use_cudnn)
90 layer = rnn.LSTM(units, return_sequences=True)
91 model.add(layer)
100 layer = rnn.LSTM(units, input_shape=(None, embedding_dim))
102 model.add(layer)
137 layer = rnn.LSTM(units)
139 output = layer(inputs, initial_state=initial_state[0])
141 output = layer(inputs, initial_state=initial_state)
[all …]
Dcudnn_recurrent_test.py84 layer = layer_class(units, return_state=True, stateful=True)
85 outputs = layer(inputs)
94 keras.backend.eval(layer.states[0]), state, atol=1e-4)
110 layer = layer_class(units, time_major=True, return_sequences=True)
111 model.add(layer)
136 layer = layer_class(units)
138 output = layer(inputs, initial_state=initial_state[0])
140 output = layer(inputs, initial_state=initial_state)
141 self.assertIn(initial_state[0], layer._inbound_nodes[0].input_tensors)
169 layer = layer_class(
[all …]
/external/mesa3d/src/gallium/auxiliary/vl/
Dvl_compositor.c698 default_rect(struct vl_compositor_layer *layer) in default_rect() argument
700 struct pipe_resource *res = layer->sampler_views[0]->texture; in default_rect()
720 calc_src_and_dst(struct vl_compositor_layer *layer, unsigned width, unsigned height, in calc_src_and_dst() argument
725 layer->src.tl = calc_topleft(size, src); in calc_src_and_dst()
726 layer->src.br = calc_bottomright(size, src); in calc_src_and_dst()
727 layer->dst.tl = calc_topleft(size, dst); in calc_src_and_dst()
728 layer->dst.br = calc_bottomright(size, dst); in calc_src_and_dst()
729 layer->zw.x = 0.0f; in calc_src_and_dst()
730 layer->zw.y = size.y; in calc_src_and_dst()
734 gen_rect_verts(struct vertex2f *vb, struct vl_compositor_layer *layer) in gen_rect_verts() argument
[all …]
/external/tensorflow/tensorflow/python/keras/utils/
Dlayer_utils.py16 """Utilities related to layer/model functionality.
31 def get_source_inputs(tensor, layer=None, node_index=None): argument
39 layer: Origin layer of the tensor. Will be
49 if layer is None or node_index:
50 layer, node_index, _ = tensor._keras_history
51 if not layer._inbound_nodes:
54 node = layer._inbound_nodes[node_index]
56 # Reached an Input layer, stop recursion.
60 for layer, node_index, _, tensor in node.iterate_inbound():
61 previous_sources = get_source_inputs(tensor, layer, node_index)
[all …]
/external/tensorflow/tensorflow/python/keras/engine/
Dbase_layer.py16 """Contains the base Layer class, from which all layers inherit."""
65 @keras_export('keras.layers.Layer')
66 class Layer(trackable.Trackable): class
67 """Base layer class.
71 A layer is a class implementing common neural networks operations, such
73 losses, updates, and inter-layer connectivity.
75 Users will just instantiate a layer and then treat it as a callable.
77 We recommend that descendants of `Layer` implement the following methods:
86 once. Should actually perform the logic of applying the layer to the
90 trainable: Boolean, whether the layer's variables should be trainable.
[all …]
Dnetwork.py69 class Network(base_layer.Layer):
167 # This acts just like the `trainable` attribute of any layer instance.
182 # Private attributes to implement compatibility with Layer.
214 # each of its layers will handle casting through the layer's own
268 layer, node_index, tensor_index = x._keras_history # pylint: disable=protected-access
269 self._output_layers.append(layer)
270 self._output_coordinates.append((layer, node_index, tensor_index))
274 layer, node_index, tensor_index = x._keras_history # pylint: disable=protected-access
275 # It's supposed to be an input layer, so only one node
279 self._input_layers.append(layer)
[all …]
Dsequential.py47 # Optionally, the first layer can receive an `input_shape` argument:
107 for layer in layers:
108 self.add(layer)
124 return any(layer.dynamic for layer in self.layers)
127 def add(self, layer): argument
128 """Adds a layer instance on top of the layer stack.
131 layer: layer instance.
134 TypeError: If `layer` is not a layer instance.
135 ValueError: In case the `layer` argument does not
137 ValueError: In case the `layer` argument has
[all …]
Dbase_layer_test.py15 """Tests for TensorFlow 2.0 layer behavior."""
46 class DynamicLayer1(base_layer.Layer):
61 class DynamicLayer2(base_layer.Layer):
76 class InvalidLayer(base_layer.Layer):
235 class TestLayer(keras.layers.Layer):
244 layer = TestLayer()
245 self.assertEqual(layer.default_weight.shape.as_list(), [])
246 self.assertEqual(layer.weight_without_name.shape.as_list(), [3, 4])
247 self.assertEqual(layer.default_weight.dtype.name, 'float32')
248 self.assertEqual(layer.weight_without_name.dtype.name, 'float32')
[all …]
/external/skia/tests/
DGpuLayerCacheTest.cpp8 // Disabling this test since it is for the layer hoister which is current disabled.
38 static int Uses(GrCachedLayer* layer) {
39 return layer->uses();
57 GrCachedLayer* layer = cache->findLayerOrCreate(picture.uniqueID(),
64 REPORTER_ASSERT(reporter, layer);
67 REPORTER_ASSERT(reporter, temp == layer);
71 REPORTER_ASSERT(reporter, picture.uniqueID() == layer->pictureID());
72 REPORTER_ASSERT(reporter, layer->start() == idOffset + i + 1);
73 REPORTER_ASSERT(reporter, layer->stop() == idOffset + i + 2);
74 REPORTER_ASSERT(reporter, !layer->texture());
[all …]
/external/skqp/tests/
DGpuLayerCacheTest.cpp8 // Disabling this test since it is for the layer hoister which is current disabled.
38 static int Uses(GrCachedLayer* layer) {
39 return layer->uses();
57 GrCachedLayer* layer = cache->findLayerOrCreate(picture.uniqueID(),
64 REPORTER_ASSERT(reporter, layer);
67 REPORTER_ASSERT(reporter, temp == layer);
71 REPORTER_ASSERT(reporter, picture.uniqueID() == layer->pictureID());
72 REPORTER_ASSERT(reporter, layer->start() == idOffset + i + 1);
73 REPORTER_ASSERT(reporter, layer->stop() == idOffset + i + 2);
74 REPORTER_ASSERT(reporter, !layer->texture());
[all …]
/external/skia/tools/sk_app/
DWindow.cpp23 void Window::visitLayers(std::function<void(Layer*)> visitor) { in visitLayers()
31 bool Window::signalLayers(std::function<bool(Layer*)> visitor) { in signalLayers()
41 this->visitLayers([](Layer* layer) { layer->onBackendCreated(); }); in onBackendCreated() argument
45 return this->signalLayers([=](Layer* layer) { return layer->onChar(c, modifiers); }); in onChar() argument
49 return this->signalLayers([=](Layer* layer) { return layer->onKey(key, state, modifiers); }); in onKey() argument
53 return this->signalLayers([=](Layer* layer) { return layer->onMouse(x, y, state, modifiers); }); in onMouse() argument
57 return this->signalLayers([=](Layer* layer) { return layer->onMouseWheel(delta, modifiers); }); in onMouseWheel() argument
61 return this->signalLayers([=](Layer* layer) { return layer->onTouch(owner, state, x, y); }); in onTouch() argument
65 this->visitLayers([=](Layer* layer) { layer->onUIStateChanged(stateName, stateValue); }); in onUIStateChanged() argument
76 this->visitLayers([](Layer* layer) { layer->onPrePaint(); }); in onPaint() argument
[all …]
/external/skqp/tools/sk_app/
DWindow.cpp23 void Window::visitLayers(std::function<void(Layer*)> visitor) { in visitLayers()
31 bool Window::signalLayers(std::function<bool(Layer*)> visitor) { in signalLayers()
41 this->visitLayers([](Layer* layer) { layer->onBackendCreated(); }); in onBackendCreated() argument
45 return this->signalLayers([=](Layer* layer) { return layer->onChar(c, modifiers); }); in onChar() argument
49 return this->signalLayers([=](Layer* layer) { return layer->onKey(key, state, modifiers); }); in onKey() argument
53 return this->signalLayers([=](Layer* layer) { return layer->onMouse(x, y, state, modifiers); }); in onMouse() argument
57 return this->signalLayers([=](Layer* layer) { return layer->onMouseWheel(delta, modifiers); }); in onMouseWheel() argument
61 return this->signalLayers([=](Layer* layer) { return layer->onTouch(owner, state, x, y); }); in onTouch() argument
65 this->visitLayers([=](Layer* layer) { layer->onUIStateChanged(stateName, stateValue); }); in onUIStateChanged() argument
78 this->visitLayers([](Layer* layer) { layer->onPrePaint(); }); in onPaint() argument
[all …]
/external/tensorflow/tensorflow/contrib/eager/python/
Dnetwork.py61 "necessary or supported. Instead, `Layer` instances are tracked on "
66 "`Layer` instances, including those from `tf.layers`, but switching to "
73 class Network(base.Layer):
79 necessary or supported. Instead, `Layer` instances are tracked on attribute
85 `tf.keras.Model` works with all TensorFlow `Layer` instances, including those
91 `Network` implements the `Layer` interface and adds convenience methods for
92 managing sub-`Layer`s, such as listing variables.
94 `Layer`s (including other `Network`s) should be added via `track_layer`. They
110 created by tracked `Layer`s is available via `Network.variables`:
119 `tf.layers.Dense` layer:
[all …]
/external/tensorflow/tensorflow/python/keras/
Dtesting_utils.py73 """Test routine for a layer with a single input and single output.
76 layer_cls: Layer class object.
78 layer.
86 The output data (Numpy array) returned by the layer, for additional
114 layer = layer_cls(**kwargs)
116 # test get_weights , set_weights at layer level
117 weights = layer.get_weights()
118 layer.set_weights(weights)
123 layer = layer_cls(**kwargs)
127 y = layer(x)
[all …]
Dmodels.py27 from tensorflow.python.keras.engine.base_layer import Layer
49 def _clone_layer(layer): argument
50 return layer.__class__.from_config(layer.get_config())
92 for layer in model._input_layers:
94 batch_shape=layer._batch_input_shape,
95 dtype=layer.dtype,
96 sparse=layer.sparse,
97 name=layer.name)
99 # Cache newly created input layer.
101 layer_map[layer] = newly_created_input_layer
[all …]
/external/webrtc/webrtc/modules/video_coding/codecs/vp9/
Dscreenshare_layers_unittest.cc48 EXPECT_EQ(expected_.layer[layer_id].upd_buf, in EqualRefsForLayer()
49 actual.layer[layer_id].upd_buf); in EqualRefsForLayer()
50 EXPECT_EQ(expected_.layer[layer_id].ref_buf1, in EqualRefsForLayer()
51 actual.layer[layer_id].ref_buf1); in EqualRefsForLayer()
52 EXPECT_EQ(expected_.layer[layer_id].ref_buf2, in EqualRefsForLayer()
53 actual.layer[layer_id].ref_buf2); in EqualRefsForLayer()
54 EXPECT_EQ(expected_.layer[layer_id].ref_buf3, in EqualRefsForLayer()
55 actual.layer[layer_id].ref_buf3); in EqualRefsForLayer()
94 expected_.layer[l].upd_buf = l; in TEST_F()
100 expected_.layer[l].ref_buf1 = l; in TEST_F()
[all …]
/external/vulkan-validation-layers/layers/
DREADME.md1 # Layer Description and Status
3 ## Layer Library Interface
5 All layer libraries must support the layer library interface defined in
8 [`LoaderAndLayerInterface.md`]: ../loader/LoaderAndLayerInterface.md#layer-library-interface
12 Layer libraries can be written to intercept or hook VK entry points for various
13 debug and validation purposes. One or more VK entry points can be defined in your Layer
14 library. Undefined entrypoints in the Layer library will be passed to the next Layer which
15 may be the driver. Multiple layer libraries can be chained (actually a hierarchy) together.
24 When a validation layer is enabled, it will look for a vk_layer_settings.txt file (see"Using
33 ### Layer library example code
[all …]
/external/walt/hardware/kicad/
DWALTsm.kicad_pcb204 (module Capacitors_SMD:C_0805 (layer F.Cu) (tedit 58B4C36B) (tstamp 5766179B)
210 (fp_text reference C1 (at -2.667 0.42) (layer F.SilkS)
213 (fp_text value 0.1uF (at 0.381 0) (layer F.Fab)
216 (fp_line (start -1.8 -1) (end 1.8 -1) (layer F.CrtYd) (width 0.05))
217 (fp_line (start -1.8 1) (end 1.8 1) (layer F.CrtYd) (width 0.05))
218 (fp_line (start -1.8 -1) (end -1.8 1) (layer F.CrtYd) (width 0.05))
219 (fp_line (start 1.8 -1) (end 1.8 1) (layer F.CrtYd) (width 0.05))
220 (fp_line (start 0.5 -0.85) (end -0.5 -0.85) (layer F.SilkS) (width 0.15))
221 (fp_line (start -0.5 0.85) (end 0.5 0.85) (layer F.SilkS) (width 0.15))
233 (module walt_footprints:R_0603_pad07mm_long (layer F.Cu) (tedit 57B60F33) (tstamp 576617B3)
[all …]
/external/tensorflow/tensorflow/python/keras/saving/
Dhdf5_format.py267 'passed to the first layer cannot reload their '
277 def preprocess_weights_for_loading(layer, argument
281 """Preprocess layer weights between different Keras formats.
287 layer: Layer instance.
310 layer.forward_layer, weights[:num_weights_per_layer],
313 layer.backward_layer, weights[num_weights_per_layer:],
330 layer.layer, weights, original_keras_version, original_backend)
346 for sublayer in layer.layers:
350 layer=sublayer,
357 for sublayer in layer.layers:
[all …]

12345678910>>...154