dòng chảy :: ops :: ResourceSparseApplyRMSProp
#include <training_ops.h>
Cập nhật '* var' theo thuật toán RMSProp.
Tóm lược
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 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 lại mà grad bằng 0.
mean_square = giảm dần * mean_square + (1-giảm dần) * gradient ** 2 Delta = learning_rate * gradient / sqrt (mean_square + epsilon)
ms <- rho * ms_ {t-1} + (1-rho) * grad * grad mom <- xung lượng * 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ẹ: Nên từ một Biến ().
- lr: Hệ số tỷ lệ. Phải là một vô hướng.
- rho: Tỷ lệ phân rã. Phải là một vô hướng.
- epsilon: Thuật ngữ Ridge. Phải là một vô hướng.
- grad: Độ dốc.
- chỉ số: Một vectơ chỉ số thành thứ nguyên đầu tiên của var, ms và mom.
Các thuộc tính tùy chọn (xem Phần Attrs
):
- use_locking: Nếu
True
, việc cập nhật các tenxơ var, ms và mẹ được bảo vệ bằng một khóa; nếu không thì hành vi không được xác định, nhưng có thể ít biểu hiện sự cạnh tranh hơn.
Lợi nhuận:
-
Operation
đã tạo
Người xây dựng và Người phá 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 cộng | |
---|---|
operation |
Chức năng công cộng | |
---|---|
operator::tensorflow::Operation () const |
Chức năng tĩnh công khai | |
---|---|
UseLocking (bool x) |
Cấu trúc | |
---|---|
tensorflow :: ops :: ResourceSparseApplyRMSProp :: Attrs | Bộ thiết lập thuộc tính tùy chọn cho ResourceSparseApplyRMSProp . |
Thuộc tính công cộng
hoạt động
Operation operation
Chức năng công cộng
ResourceSparseApplyRMSProp
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
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ử :: tensorflow :: Hoạt động
operator::tensorflow::Operation() const
Chức năng tĩnh công khai
UseLocking
Attrs UseLocking( bool x )