tensorflow:: ops:: SparseReduceSumSparse
#include <sparse_ops.h>SparseTensorの各次元における要素の合計を計算します。
まとめ
この操作は SparseTensor を受け取り、 tf.reduce_sum tf.reduce_sum()のスパース版です。SparseReduceSum とは異なり、この操作は SparseTensor を返します。
reduction_axesされた次元に沿ってsp_input削減します。keep_dims keep_dims true でない限り、 reduction_axesの各エントリごとにテンソルのランクが 1 削減されます。keep_dims keep_dims true の場合、削減された次元は長さ 1 で保持されます。
reduction_axesにエントリがない場合、すべての次元が削減され、要素が1つだけのテンソルが返されます。また、軸は負の値になることもあり、その場合はPythonのインデックス規則に従って解釈されます。
議論:
- スコープ:スコープオブジェクト
- input_indices: 2次元。SparseTensor内の空でない値のインデックスを含む
N x R行列。正規順序ではない可能性があります。 -
input_indices: 1次元。input_indicesに対応するN個の空でない値。 - input_shape: 1次元。入力SparseTensorの形状。
- reduction_axes: 1次元。縮小軸を含む長さ
Kのベクトル。
オプション属性( Attrs参照):
- keep_dims: trueの場合、長さ1の縮小された次元を保持します。
返品:
コンストラクターとデストラクタ | |
|---|---|
SparseReduceSumSparse (const :: tensorflow::Scope & scope, :: tensorflow::Input input_indices, :: tensorflow::Input input_values, :: tensorflow::Input input_shape, :: tensorflow::Input reduction_axes) | |
SparseReduceSumSparse (const :: tensorflow::Scope & scope, :: tensorflow::Input input_indices, :: tensorflow::Input input_values, :: tensorflow::Input input_shape, :: tensorflow::Input reduction_axes, const SparseReduceSumSparse::Attrs & attrs) |
公開属性 | |
|---|---|
operation | |
output_indices | |
output_shape | |
output_values | |
パブリック静的関数 | |
|---|---|
KeepDims (bool x) | |
構造 | |
|---|---|
| tensorflow:: ops:: SparseReduceSumSparse:: Attrs | SparseReduceSumSparseのオプション属性セッター。 |
公開属性
手術
Operation operation
出力インデックス
::tensorflow::Output output_indices
出力形状
::tensorflow::Output output_shape
出力値
::tensorflow::Output output_values
公的機能
SparseReduceSumSparse
SparseReduceSumSparse( const ::tensorflow::Scope & scope, ::tensorflow::Input input_indices, ::tensorflow::Input input_values, ::tensorflow::Input input_shape, ::tensorflow::Input reduction_axes )
SparseReduceSumSparse
SparseReduceSumSparse( const ::tensorflow::Scope & scope, ::tensorflow::Input input_indices, ::tensorflow::Input input_values, ::tensorflow::Input input_shape, ::tensorflow::Input reduction_axes, const SparseReduceSumSparse::Attrs & attrs )
パブリック静的関数
キープディムズ
Attrs KeepDims( bool x )