Tensorflow :: ops :: Pad
#include <array_ops.h>
Füllt einen Tensor mit Nullen auf.
Zusammenfassung
Diese Operation paddings
eine input
mit Nullen gemäß den paddings
Ihnen angegebenen paddings
. paddings
ist ein ganzzahliger Tensor mit der Form [Dn, 2]
, wobei n der Rang der input
. Für jede Dimension D der input
paddings[D, 0]
an, wie viele Nullen vor dem Inhalt der input
in dieser Dimension paddings[D, 1]
, und paddings[D, 1]
geben an, wie viele Nullen nach dem Inhalt der input
in dieser Dimension hinzugefügt werden sollen.
Die gepolsterte Größe jeder Dimension D der Ausgabe beträgt:
paddings(D, 0) + input.dim_size(D) + paddings(D, 1)
Beispielsweise:
# 't' is [[1, 1], [2, 2]] # 'paddings' is [[1, 1], [2, 2]] # rank of 't' is 2 pad(t, paddings) ==> [[0, 0, 0, 0, 0, 0] [0, 0, 1, 1, 0, 0] [0, 0, 2, 2, 0, 0] [0, 0, 0, 0, 0, 0]]
Argumente:
- scope: Ein Scope- Objekt
Kehrt zurück:
-
Output
: Der Ausgangstensor.
Konstruktoren und Destruktoren | |
---|---|
Pad (const :: tensorflow::Scope & scope, :: tensorflow::Input input, :: tensorflow::Input paddings) |
Öffentliche Attribute | |
---|---|
operation | |
output |
Öffentliche Funktionen | |
---|---|
node () const | ::tensorflow::Node * |
operator::tensorflow::Input () const | |
operator::tensorflow::Output () const |
Öffentliche Attribute
Operation
Operation operation
Ausgabe
::tensorflow::Output output
Öffentliche Funktionen
Pad
Pad( const ::tensorflow::Scope & scope, ::tensorflow::Input input, ::tensorflow::Input paddings )
Knoten
::tensorflow::Node * node() const
operator :: tensorflow :: Input
operator::tensorflow::Input() const
operator :: tensorflow :: Output
operator::tensorflow::Output() const