텐서플로우:: ops:: 컴프로드

#include <math_ops.h>

텐서 x 의 axis 따라 누적곱을 계산합니다.

요약

기본적으로 이 연산은 입력의 첫 번째 요소와 출력의 첫 번째 요소가 동일한 포괄적 누적 연산을 수행합니다.

tf.cumprod([a, b, c])  # => [a, a * b, a * b * c]

exclusive 키워드 인수를 True 로 설정하면 대신 독점 cumprod가 수행됩니다.

tf.cumprod([a, b, c], exclusive=True)  # => [1, a, a * b]

reverse 키워드 인수를 True 로 설정하면 cumprod가 반대 방향으로 수행됩니다.

tf.cumprod([a, b, c], reverse=True)  # => [a * b * c, b * c, c]

이는 개별적인 tf.reverse 연산을 사용하는 것보다 더 효율적입니다.

reverse 및 exclusive 키워드 인수도 결합할 수 있습니다.

tf.cumprod([a, b, c], exclusive=True, reverse=True)  # => [b * c, c, 1]

논거:

  • 범위: Scope 객체
  • x: Tensor 입니다. 다음 유형 중 하나여야 합니다: float32 , float64 , int64 , int32 , uint8 , uint16 , int16 , int8 , complex64 , complex128 , qint8 , quint8 , qint32 , half .
  • axis: int32 유형의 Tensor (기본값: 0). 범위는 [-rank(x), rank(x)) 이어야 합니다.

선택적 속성( Attrs 참조):

  • 독점: True 인 경우 독점적인 컴프로드를 수행합니다.
  • reverse: bool (기본값: False).

보고:

생성자와 소멸자

Cumprod (const :: tensorflow::Scope & scope, :: tensorflow::Input x, :: tensorflow::Input axis)
Cumprod (const :: tensorflow::Scope & scope, :: tensorflow::Input x, :: tensorflow::Input axis, const Cumprod::Attrs & attrs)

공개 속성

operation
out

공공 기능

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

공개 정적 함수

Exclusive (bool x)
Reverse (bool x)

구조

텐서플로우:: ops:: Cumprod:: Attrs

Cumprod 에 대한 선택적 속성 설정기입니다.

공개 속성

작업

Operation operation

밖으로

::tensorflow::Output out

공공 기능

컴프로드

 Cumprod(
  const ::tensorflow::Scope & scope,
  ::tensorflow::Input x,
  ::tensorflow::Input axis
)

컴프로드

 Cumprod(
  const ::tensorflow::Scope & scope,
  ::tensorflow::Input x,
  ::tensorflow::Input axis,
  const Cumprod::Attrs & attrs
)

마디

::tensorflow::Node * node() const 

연산자::텐서플로우::입력

 operator::tensorflow::Input() const 

연산자::텐서플로우::출력

 operator::tensorflow::Output() const 

공개 정적 함수

독점적인

Attrs Exclusive(
  bool x
)

뒤집다

Attrs Reverse(
  bool x
)