Home
last modified time | relevance | path

Searched refs:one_hot (Results 1 – 25 of 62) sorted by relevance

123

/external/tensorflow/tensorflow/core/api_def/base_api/
Dapi_def_OneHot.pbtxt80 [5.0 0.0 0.0] // one_hot(0)
81 [0.0 0.0 5.0] // one_hot(2)
82 [0.0 0.0 0.0] // one_hot(-1)
83 [0.0 5.0 0.0] // one_hot(1)
102 // ^ one_hot(0)
103 // ^ one_hot(2)
104 // ^ one_hot(-1)
105 // ^ one_hot(1)
121 [1.0, 0.0, 0.0] // one_hot(0)
122 [0.0, 0.0, 1.0] // one_hot(2)
[all …]
/external/tensorflow/tensorflow/lite/experimental/examples/lstm/
Dinput_data.py89 def _extract_labels(f, one_hot=False, num_classes=10): argument
112 if one_hot:
129 one_hot=False, argument
159 self.one_hot = one_hot
200 if self.one_hot:
269 one_hot=False, argument
280 one_hot=one_hot,
305 train_labels = _extract_labels(f, one_hot=one_hot)
315 test_labels = _extract_labels(f, one_hot=one_hot)
/external/tensorflow/tensorflow/python/keras/utils/
Dnp_utils_test.py38 for label, one_hot, expected_shape in zip(labels,
42 self.assertEqual(one_hot.shape, expected_shape)
44 self.assertTrue(np.all(one_hot.sum(axis=-1) == 1))
47 np.argmax(one_hot, -1).reshape(label.shape) == label))
/external/tensorflow/tensorflow/python/eager/benchmarks/resnet50/
Dresnet50_test_util.py45 one_hot = tf.one_hot(labels, num_classes)
47 return images, one_hot
Dresnet50_graph_test.py44 one_hot = np.zeros((batch_size, num_classes)).astype(np.float32)
45 one_hot[np.arange(batch_size), labels] = 1.
46 return images, one_hot
/external/tensorflow/tensorflow/compiler/tf2xla/kernels/
Done_hot_op.cc65 xla::XlaOp one_hot; in Compile() local
69 ctx->Input(3), &one_hot)); in Compile()
70 ctx->SetOutput(0, one_hot); in Compile()
/external/tensorflow/tensorflow/python/ops/
Dctc_ops.py531 initial_state_log_probs = array_ops.one_hot(
538 label_final_state_mask = array_ops.one_hot(
556 one_hot = array_ops.one_hot(labels, depth=num_labels)
557 one_hot = array_ops.expand_dims(one_hot, axis=0)
559 state_log_probs = math_ops.reduce_sum(ilabel_log_probs * one_hot, axis=3)
572 one_hot = array_ops.one_hot(
577 one_hot = array_ops.expand_dims(one_hot, axis=0)
579 label_olabels = math_ops.reduce_logsumexp(label_states + one_hot, axis=2)
1217 one_hot = array_ops.one_hot(
1223 return math_ops.reduce_logsumexp(states + one_hot, axis=-1)
/external/tensorflow/tensorflow/python/keras/preprocessing/
Dtext.py61 def one_hot(input_text, function
88 return text.one_hot(input_text, n, filters=filters, lower=lower, split=split)
Dtext_test.py32 encoded = preprocessing_text.one_hot(text, 5)
39 encoded = preprocessing_text.one_hot(text, 5)
Ddataset_utils.py217 label_ds = label_ds.map(lambda x: array_ops.one_hot(x, num_classes))
/external/tensorflow/tensorflow/lite/testing/op_tests/
Done_hot.py47 out = tf.one_hot(indices=indices, depth=depth)
54 out = tf.one_hot(
/external/tensorflow/tensorflow/lite/kernels/
Done_hot.cc26 namespace one_hot { namespace
202 one_hot::Prepare, in Register_ONE_HOT()
203 one_hot::Eval, in Register_ONE_HOT()
/external/tensorflow/tensorflow/python/ops/ragged/
Dragged_one_hot_op_test.py131 array_ops.one_hot(
175 expected = array_ops.one_hot(
/external/tensorflow/tensorflow/tools/api/golden/v2/
Dtensorflow.keras.preprocessing.text.pbtxt12 name: "one_hot"
/external/tensorflow/tensorflow/tools/api/golden/v1/
Dtensorflow.keras.preprocessing.text.pbtxt12 name: "one_hot"
/external/tensorflow/tensorflow/core/kernels/fuzzing/
DBUILD75 tf_ops_fuzz_target_lib("one_hot")
/external/tensorflow/tensorflow/compiler/tf2xla/
Dxla_helpers.cc85 const xla::XlaOp& off_value, xla::XlaOp* one_hot) { in OneHot() argument
99 *one_hot = xla::Select( in OneHot()
Dxla_helpers.h65 const xla::XlaOp& off_value, xla::XlaOp* one_hot);
/external/tensorflow/tensorflow/python/keras/tests/
Dmemory_checker_test.py70 f = array_ops.one_hot(states, dtype='float32', depth=3)
/external/tensorflow/tensorflow/python/kernel_tests/
Done_hot_op_test.py41 array_ops.one_hot(dtype=dtype, **inputs)
43 ans = array_ops.one_hot(dtype=dtype, **inputs)
461 tensor_one_hot = array_ops.one_hot(tensor, depth=10, axis=0)
/external/tensorflow/tensorflow/python/keras/integration_test/
Dforwardprop_test.py45 mask = tf.one_hot(element_index, primal_vector_length)
88 full_onehot = tf.one_hot(index, total_size)
/external/tensorflow/tensorflow/compiler/mlir/tfr/examples/mnist/
Dmnist_train.py145 labels = tf.one_hot(features['label'], num_classes)
/external/tensorflow/tensorflow/compiler/tests/
Dnary_ops_test.py131 op = array_ops.one_hot(indices,
140 op = array_ops.one_hot(indices,
/external/tensorflow/tensorflow/python/debug/examples/v2/
Ddebug_mnist_v2.py152 labels = tf.one_hot(labels, depth=10, dtype=tf.float32)
/external/tensorflow/tensorflow/python/ops/distributions/
Dmultinomial.py266 x = math_ops.reduce_sum(array_ops.one_hot(x, depth=k), axis=-2) # [n, k]

123