Spec-Zone.ru › TensorFlow C++ 2.3

tensorflow::ops::SparseSlice

#include <sparse_ops.h>

Вырезать часть SparseTensor на основе start и size.

Summary

Например, если входные данные

input_tensor = shape = [2, 7]
[    a   d e  ]
[b c          ]

Графически выходные тензоры:

sparse_slice([0, 0], [2, 4]) = shape = [2, 4]
[    a  ]
[b c    ]

sparse_slice([0, 4], [2, 3]) = shape = [2, 3]
[ d e  ]
[      ]

Аргументы:

  • scope: Объект Scope
  • indices: 2-мерный тензор, представляющий индексы разреженного тензора.
  • values: 1-мерный тензор, представляющий значения разреженного тензора.
  • shape: 1-мерный тензор, представляющий форму разреженного тензора.
  • start: 1-мерный тензор, представляющий начало среза.
  • size: 1-мерный тензор, представляющий размер среза. output indices: список 1-мерных тензоров, представляющих индексы выходных разреженных тензоров.

Возвращает:

  • Output output_indices
  • Output output_values: список 1-мерных тензоров, представляющих значения выходных разреженных тензоров.
  • Output output_shape: список 1-мерных тензоров, представляющих форму выходных разреженных тензоров.
Конструкторы и деструкторы
SparseSlice(const ::tensorflow::Scope & scope, ::tensorflow::Input indices, ::tensorflow::Input values, ::tensorflow::Input shape, ::tensorflow::Input start, ::tensorflow::Input size)
Публичные атрибуты
operation
Operation
output_indices
::tensorflow::Output
output_shape
::tensorflow::Output
output_values
::tensorflow::Output

Публичные атрибуты

operation

Operation operation

output_indices

::tensorflow::Output output_indices

output_shape

::tensorflow::Output output_shape

output_values

::tensorflow::Output output_values

Публичные функции

SparseSlice

 SparseSlice(
  const ::tensorflow::Scope & scope,
  ::tensorflow::Input indices,
  ::tensorflow::Input values,
  ::tensorflow::Input shape,
  ::tensorflow::Input start,
  ::tensorflow::Input size
)

© 2020 The TensorFlow Authors. All rights reserved.
Licensed under the Creative Commons Attribution License 3.0.
Code samples licensed under the Apache 2.0 License.
https://www.tensorflow.org/versions/r2.3/api_docs/cc/class/tensorflow/ops/sparse-slice

Spec-Zone.ru

Настройки Оффлайн Что нового Помощь О нас
Spec-Zone .ru
спецификации, руководства, описания, API