dòng chảy căng:: ôi:: Tài nguyênSparseApplyRMSProp

#include <training_ops.h>

Cập nhật '*var' theo thuật toán RMSProp.

Bản tóm tắt

Lưu ý rằng khi triển khai dày đặc thuật toán này, ms và mom sẽ cập nhật ngay cả khi grad bằng 0, nhưng trong cách triển khai thưa thớt này, ms và mom sẽ không cập nhật trong các lần lặp trong đó grad bằng 0.

trung bình_vuông = phân rã * trung bình_vuông + (1-phân rã) * gradient ** 2 Delta = tốc độ học tập * gradient / sqrt(mean_square + epsilon)

ms <- rho * ms_{t-1} + (1-rho) * grad * grad mẹ <- đà * mom_{t-1} + lr * grad / sqrt(ms + epsilon) var <- var - mom

Tranh luận:

  • phạm vi: Một đối tượng Phạm vi
  • var: Phải từ một Biến().
  • ms: Phải từ một Biến().
  • mẹ: Phải từ một Biến().
  • lr: Hệ số tỷ lệ. Phải là một vô hướng.
  • rho: Tốc độ phân rã. Phải là một vô hướng.
  • epsilon: Thuật ngữ sườn núi. Phải là một vô hướng.
  • grad: Độ dốc.
  • chỉ số: Một vectơ chỉ số vào chiều thứ nhất của var, ms và mom.

Thuộc tính tùy chọn (xem Attrs ):

  • use_locking: Nếu True , việc cập nhật các tensor var, ms và mom được bảo vệ bằng khóa; mặt khác, hành vi không được xác định, nhưng có thể ít gây tranh cãi hơn.

Trả về:

Hàm tạo và hàm hủy

ResourceSparseApplyRMSProp (const :: tensorflow::Scope & scope, :: tensorflow::Input var, :: tensorflow::Input ms, :: tensorflow::Input mom, :: tensorflow::Input lr, :: tensorflow::Input rho, :: tensorflow::Input momentum, :: tensorflow::Input epsilon, :: tensorflow::Input grad, :: tensorflow::Input indices)
ResourceSparseApplyRMSProp (const :: tensorflow::Scope & scope, :: tensorflow::Input var, :: tensorflow::Input ms, :: tensorflow::Input mom, :: tensorflow::Input lr, :: tensorflow::Input rho, :: tensorflow::Input momentum, :: tensorflow::Input epsilon, :: tensorflow::Input grad, :: tensorflow::Input indices, const ResourceSparseApplyRMSProp::Attrs & attrs)

Thuộc tính công khai

operation

Chức năng công cộng

operator::tensorflow::Operation () const

Các hàm tĩnh công khai

UseLocking (bool x)

Cấu trúc

tensorflow:: ops:: ResourceSparseApplyRMSProp:: Attrs

Trình thiết lập thuộc tính tùy chọn cho ResourceSparseApplyRMSProp .

Thuộc tính công khai

hoạt động

Operation operation

Chức năng công cộng

Tài nguyênSparseApplyRMSProp

 ResourceSparseApplyRMSProp(
  const ::tensorflow::Scope & scope,
  ::tensorflow::Input var,
  ::tensorflow::Input ms,
  ::tensorflow::Input mom,
  ::tensorflow::Input lr,
  ::tensorflow::Input rho,
  ::tensorflow::Input momentum,
  ::tensorflow::Input epsilon,
  ::tensorflow::Input grad,
  ::tensorflow::Input indices
)

Tài nguyênSparseApplyRMSProp

 ResourceSparseApplyRMSProp(
  const ::tensorflow::Scope & scope,
  ::tensorflow::Input var,
  ::tensorflow::Input ms,
  ::tensorflow::Input mom,
  ::tensorflow::Input lr,
  ::tensorflow::Input rho,
  ::tensorflow::Input momentum,
  ::tensorflow::Input epsilon,
  ::tensorflow::Input grad,
  ::tensorflow::Input indices,
  const ResourceSparseApplyRMSProp::Attrs & attrs
)

toán tử::tenorflow::Hoạt động

 operator::tensorflow::Operation() const 

Các hàm tĩnh công khai

Sử dụngKhóa

Attrs UseLocking(
  bool x
)