テンソルフロー::作戦:: SetDiff1D

#include <array_ops.h>

2 つの数値または文字列のリストの差を計算します。

まとめ

リストxとリストyを指定すると、この演算は、 xにはあるがyには存在しないすべての値を表すリストoutを返します。返されたリストoutxに出現する数値と同じ順序で並べ替えられます (重複は保持されます)。この操作は、 x内の各out要素の位置を表すリストidxも返します。言い換えると:

out[i] = x[idx[i]] for i in [0, 1, ..., len(out) - 1]

たとえば、次の入力があったとします。

x = [1, 2, 3, 4, 5, 6]
y = [1, 3, 5]

この操作は次を返します:

out ==> [2, 4, 6]
idx ==> [1, 3, 5]

引数:

  • スコープ:スコープオブジェクト
  • ×:1-D。守るべき価値観。
  • y: 1-D。削除する値。

戻り値:

  • Output出力: 1-D。値はxには存在しますが、 yには存在しません。
  • Output idx: 1-D。 x値の位置はoutに保存されます。

コンストラクターとデストラクター

SetDiff1D (const :: tensorflow::Scope & scope, :: tensorflow::Input x, :: tensorflow::Input y)
SetDiff1D (const :: tensorflow::Scope & scope, :: tensorflow::Input x, :: tensorflow::Input y, const SetDiff1D::Attrs & attrs)

パブリック属性

idx
operation
out

パブリック静的関数

OutIdx (DataType x)

構造体

tensorflow:: ops:: SetDiff1D:: Attrs

SetDiff1Dのオプションの属性セッター。

パブリック属性

いど

::tensorflow::Output idx

手術

Operation operation

::tensorflow::Output out

公共機能

SetDiff1D

 SetDiff1D(
  const ::tensorflow::Scope & scope,
  ::tensorflow::Input x,
  ::tensorflow::Input y
)

SetDiff1D

 SetDiff1D(
  const ::tensorflow::Scope & scope,
  ::tensorflow::Input x,
  ::tensorflow::Input y,
  const SetDiff1D::Attrs & attrs
)

パブリック静的関数

アウトIdx

Attrs OutIdx(
  DataType x
)