Home
last modified time | relevance | path

Searched refs:one_hot (Results 1 – 25 of 56) 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/python/eager/benchmarks/resnet50/
Dresnet50_test_util.py41 one_hot = tf.one_hot(labels, num_classes)
43 return images, one_hot
Dresnet50_graph_test.py40 one_hot = np.zeros((batch_size, num_classes)).astype(np.float32)
41 one_hot[np.arange(batch_size), labels] = 1.
42 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.py577 initial_state_log_probs = array_ops.one_hot(
584 label_final_state_mask = array_ops.one_hot(
602 one_hot = array_ops.one_hot(labels, depth=num_labels)
603 one_hot = array_ops.expand_dims(one_hot, axis=0)
605 state_log_probs = math_ops.reduce_sum(ilabel_log_probs * one_hot, axis=3)
618 one_hot = array_ops.one_hot(
623 one_hot = array_ops.expand_dims(one_hot, axis=0)
625 label_olabels = math_ops.reduce_logsumexp(label_states + one_hot, axis=2)
1274 one_hot = array_ops.one_hot(
1280 return math_ops.reduce_logsumexp(states + one_hot, axis=-1)
/external/tensorflow/tensorflow/lite/kernels/
Done_hot.cc26 namespace one_hot { namespace
207 one_hot::Prepare, in Register_ONE_HOT()
208 one_hot::Eval, in Register_ONE_HOT()
DAndroid.bp128 "one_hot.cc",
/external/tensorflow/tensorflow/lite/testing/op_tests/
Done_hot.py43 out = tf.one_hot(indices=indices, depth=depth)
50 out = tf.one_hot(
/external/tensorflow/tensorflow/dtensor/mlir/expansions/
Dmeta_spmd_expander.cc962 const int axis, mlir::TF::OneHotOp& one_hot) { in RelayoutOneHotInput() argument
981 EmitRelayout(one_hot.indices(), *input_layout, new_input_layout)); in RelayoutOneHotInput()
983 one_hot->setOperand(0, new_input); in RelayoutOneHotInput()
1088 auto one_hot = mlir::dyn_cast<mlir::TF::OneHotOp>(op); in ComputeLayoutForward() local
1089 int axis = one_hot.axis(); in ComputeLayoutForward()
1090 if (axis == -1) axis = ValueRank(one_hot.indices()); in ComputeLayoutForward()
1113 auto one_hot = mlir::dyn_cast<mlir::TF::OneHotOp>(op); in ComputeLayoutBackward() local
1114 int axis = one_hot.axis(); in ComputeLayoutBackward()
1115 if (axis == -1) axis = ValueRank(one_hot.indices()); in ComputeLayoutBackward()
1118 llvm::DenseMap<int, Layout> input_layouts(one_hot->getNumOperands()); in ComputeLayoutBackward()
/external/tensorflow/tensorflow/python/ops/ragged/
Dragged_one_hot_op_test.py129 array_ops.one_hot(
173 expected = array_ops.one_hot(
/external/tensorflow/tensorflow/core/kernels/fuzzing/
DBUILD75 tf_ops_fuzz_target_lib("one_hot")
/external/tensorflow/tensorflow/compiler/tf2xla/
Dxla_helpers.cc93 const xla::XlaOp& off_value, xla::XlaOp* one_hot) { in OneHot() argument
107 *one_hot = xla::Select( in OneHot()
Dxla_helpers.h72 const xla::XlaOp& off_value, xla::XlaOp* one_hot);
/external/tensorflow/tensorflow/python/kernel_tests/array_ops/
Done_hot_op_test.py37 array_ops.one_hot(dtype=dtype, **inputs)
39 ans = array_ops.one_hot(dtype=dtype, **inputs)
457 tensor_one_hot = array_ops.one_hot(tensor, depth=10, axis=0)
/external/tensorflow/tensorflow/security/advisory/
Dtfsa-2021-088.md9 …nsorflow/blob/f61c57bd425878be108ec787f4d96390579fb83e/tensorflow/lite/kernels/one_hot.cc#L68-L72):
Dtfsa-2021-003.md28 data = tf.one_hot(indices=[62,50],depth=136,on_value=np.int32(237),off_value=158,axis=856,dtype=20)
/external/tensorflow/tensorflow/compiler/mlir/tfr/examples/mnist/
Dmnist_train.py141 labels = tf.one_hot(features['label'], num_classes)
/external/tensorflow/tensorflow/compiler/tests/
Dnary_ops_test.py128 op = array_ops.one_hot(indices,
137 op = array_ops.one_hot(indices,
/external/tensorflow/tensorflow/python/ops/distributions/
Dmultinomial.py262 x = math_ops.reduce_sum(array_ops.one_hot(x, depth=k), axis=-2) # [n, k]
Ddirichlet_multinomial.py271 x = math_ops.reduce_sum(array_ops.one_hot(draws, depth=k), -2)
/external/tensorflow/tensorflow/python/debug/examples/v2/
Ddebug_mnist_v2.py148 labels = tf.one_hot(labels, depth=10, dtype=tf.float32)
/external/tensorflow/tensorflow/python/debug/examples/v1/
Ddebug_mnist_v1.py121 labels = tf.one_hot(labels, depth=10, dtype=tf.float32)
/external/tensorflow/tensorflow/python/distribute/integration_test/
Dtpu_memory_test.py37 label = tf.one_hot(label, NUM_CLASS)
/external/tensorflow/tensorflow/python/ops/parallel_for/
Darray_test.py179 return (array_ops.one_hot(indices_i, depth=4, on_value=2., off_value=-2.),
180 array_ops.one_hot(indices_i, depth=4, axis=1))
/external/tensorflow/tensorflow/lite/testing/
Dbuild_def.bzl107 "one_hot",
239 "one_hot",

123