tensorflow::ops::SparseReduceMax

#include <sparse_ops.h>

Tính giá trị lớn nhất của các phần tử trên các chiều của SparseTensor.

Bản tóm tắt

Op này nhận một SparseTensor và là phiên bản thưa của tf.reduce_max() . Đặc biệt, Op này cũng trả về một Tensor dày đặc thay vì một Tensor thưa.

Giảm sp_input theo các chiều được chỉ định trong reduction_axes . Trừ khi keep_dims là true, hạng của tensor sẽ giảm đi 1 cho mỗi mục trong reduction_axes . Nếu keep_dims là true, các chiều đã giảm sẽ được giữ nguyên với độ dài là 1.

Nếu reduction_axes không có mục nào, tất cả các chiều sẽ được giảm bớt và một tensor chỉ có một phần tử sẽ được trả về. Ngoài ra, các trục có thể có giá trị âm, được diễn giải theo các quy tắc lập chỉ mục trong Python.

Luận điểm:

  • phạm vi: Một đối tượng Phạm vi
  • input_indices: Ma trận 2 chiều N x R chứa các chỉ số của các giá trị không rỗng trong SparseTensor, có thể không theo thứ tự chuẩn.
  • input_values: 1 chiều. N giá trị không rỗng tương ứng với input_indices .
  • input_shape: 1 chiều. Hình dạng của SparseTensor đầu vào.
  • reduction_axes: Vectơ 1 chiều có độ dài K chứa các trục giảm.

Các thuộc tính tùy chọn (xem Attrs ):

  • keep_dims: Nếu là true, giữ nguyên kích thước giảm với độ dài 1.

Trả về:

Hàm khởi tạo và hàm hủy

SparseReduceMax (const :: tensorflow::Scope & scope, :: tensorflow::Input input_indices, :: tensorflow::Input input_values, :: tensorflow::Input input_shape, :: tensorflow::Input reduction_axes)
SparseReduceMax (const :: tensorflow::Scope & scope, :: tensorflow::Input input_indices, :: tensorflow::Input input_values, :: tensorflow::Input input_shape, :: tensorflow::Input reduction_axes, const SparseReduceMax::Attrs & attrs)

Thuộc tính công khai

operation
output

Chức năng công cộng

node () const
::tensorflow::Node *
operator::tensorflow::Input () const
operator::tensorflow::Output () const

Các hàm tĩnh công khai

KeepDims (bool x)

Cấu trúc

tensorflow::ops::SparseReduceMax::Attrs

Các thiết lập thuộc tính tùy chọn cho SparseReduceMax .

Thuộc tính công khai

hoạt động

Operation operation

đầu ra

::tensorflow::Output output

Chức năng công cộng

SparseReduceMax

 SparseReduceMax(
  const ::tensorflow::Scope & scope,
  ::tensorflow::Input input_indices,
  ::tensorflow::Input input_values,
  ::tensorflow::Input input_shape,
  ::tensorflow::Input reduction_axes
)

SparseReduceMax

 SparseReduceMax(
  const ::tensorflow::Scope & scope,
  ::tensorflow::Input input_indices,
  ::tensorflow::Input input_values,
  ::tensorflow::Input input_shape,
  ::tensorflow::Input reduction_axes,
  const SparseReduceMax::Attrs & attrs
)

nút

::tensorflow::Node * node() const 

operator::tensorflow::Input

 operator::tensorflow::Input() const 

operator::tensorflow::Output

 operator::tensorflow::Output() const 

Các hàm tĩnh công khai

KeepDims

Attrs KeepDims(
  bool x
)