tensorflow :: ops :: HistogramFixedWidth

#include <math_ops.h>

Kembalikan histogram nilai.

Ringkasan

Dengan mempertimbangkan values tensor, operasi ini mengembalikan histogram peringkat 1 yang menghitung jumlah entri dalam values yang termasuk dalam setiap bin. value_range memiliki lebar yang sama dan ditentukan oleh argumen value_range dan nbins .

# Bins will be:  (-inf, 1), [1, 2), [2, 3), [3, 4), [4, inf)
nbins = 5
value_range = [0.0, 5.0]
new_values = [-1.0, 0.0, 1.5, 2.0, 5.0, 15]

with tf.get_default_session() as sess:
  hist = tf.histogram_fixed_width(new_values, value_range, nbins=5)
  variables.global_variables_initializer().run()
  sess.run(hist) => [2, 1, 1, 0, 2]

Argumen:

  • scope: Objek Scope
  • nilai: Tensor Numerik.
  • value_range: Shape [2] Tensor dengan dtype sama dengan values . nilai <= value_range [0] akan dipetakan ke hist [0], nilai> = value_range [1] akan dipetakan ke hist [-1].
  • nbins: int32 Tensor skalar int32 Tensor . Jumlah tempat sampah histogram.

Pengembalian:

Pembuat dan Penghancur

HistogramFixedWidth (const :: tensorflow::Scope & scope, :: tensorflow::Input values, :: tensorflow::Input value_range, :: tensorflow::Input nbins)
HistogramFixedWidth (const :: tensorflow::Scope & scope, :: tensorflow::Input values, :: tensorflow::Input value_range, :: tensorflow::Input nbins, const HistogramFixedWidth::Attrs & attrs)

Atribut publik

operation
out

Fungsi publik

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

Fungsi statis publik

Dtype (DataType x)

Structs

tensorflow :: ops :: HistogramFixedWidth :: Attrs

Penyetel atribut opsional untuk HistogramFixedWidth .

Atribut publik

operasi

Operation operation

di luar

::tensorflow::Output out

Fungsi publik

HistogramFixedWidth

 HistogramFixedWidth(
  const ::tensorflow::Scope & scope,
  ::tensorflow::Input values,
  ::tensorflow::Input value_range,
  ::tensorflow::Input nbins
)

HistogramFixedWidth

 HistogramFixedWidth(
  const ::tensorflow::Scope & scope,
  ::tensorflow::Input values,
  ::tensorflow::Input value_range,
  ::tensorflow::Input nbins,
  const HistogramFixedWidth::Attrs & attrs
)

simpul

::tensorflow::Node * node() const 

operator :: tensorflow :: Input

 operator::tensorflow::Input() const 

operator :: tensorflow :: Keluaran

 operator::tensorflow::Output() const 

Fungsi statis publik

Dtype

Attrs Dtype(
  DataType x
)