텐서플로우:: ops:: DeserializeManySparse

#include <sparse_ops.h>

직렬화된 미니배치에서 SparseTensors 역직렬화하고 연결합니다.

요약

입력 serialized_sparse 미니배치 크기 N 과 SerializeSparse 의 압축된 출력에 해당하는 행으로 구성된 [N x 3] 형태의 문자열 행렬이어야 합니다. 원래 SparseTensor 객체들의 랭크는 모두 일치해야 합니다. 최종 SparseTensor 는 입력 SparseTensor 객체들의 랭크보다 하나 높은 랭크를 갖습니다(새로운 행 차원을 따라 연결되었기 때문입니다).

출력 SparseTensor 객체의 첫 번째 차원을 제외한 모든 차원의 shape 값은 입력 SparseTensor 객체의 해당 차원 shape 값 중 최댓값입니다. 첫 번째 shape 값은 미니배치 크기인 N 입니다.

입력 SparseTensor 객체의 인덱스는 표준 사전식 순서로 정렬되어 있다고 가정합니다. 만약 그렇지 않다면, 이 단계 후에 SparseReorder 실행하여 인덱스 순서를 복원하십시오.

예를 들어, 직렬화된 입력이 두 개의 원래 SparseTensor 객체를 나타내는 [2 x 3] 행렬인 경우:

index = [ 0]
        [10]
        [20]
values = [1, 2, 3]
shape = [50]

그리고

index = [ 2]
        [10]
values = [4, 5]
shape = [30]

그러면 최종적으로 역직렬화된 SparseTensor 다음과 같습니다.

index = [0  0]
        [0 10]
        [0 20]
        [1  2]
        [1 10]
values = [1, 2, 3, 4, 5]
shape = [2 50]

논거:

  • 범위: Scope 객체
  • serialized_sparse: 2차원, N 직렬화된 SparseTensor 객체. 3개의 열이 있어야 합니다.
  • dtype: 직렬화된 SparseTensor 객체의 dtype .

보고:

생성자와 소멸자

DeserializeManySparse (const :: tensorflow::Scope & scope, :: tensorflow::Input serialized_sparse, DataType dtype)

공개 속성

operation
sparse_indices
sparse_shape
sparse_values

공개 속성

작업

Operation operation

희소 인덱스

::tensorflow::Output sparse_indices

희소한 모양

::tensorflow::Output sparse_shape

희소값

::tensorflow::Output sparse_values

공공 기능

DeserializeManySparse

 DeserializeManySparse(
  const ::tensorflow::Scope & scope,
  ::tensorflow::Input serialized_sparse,
  DataType dtype
)