当前位置:网站首页>Torch optimizer small parsing
Torch optimizer small parsing
2022-07-07 05:17:00 【Fun of construction】
I press torch 1.11 Version written :
With sgd For example :
Inside maximize = group[‘maximize’] Illustrates the maxmize Parameters can be divided group Appoint . Of course, it can also be used globally , also maxmize yes sgd Unique ( By 1.11 edition )
Be careful , Other versions of optimizer such as adam, I didn't see it maxmize Parameters . Want to perform gradient rise , My idea is to rewrite the optimizer .
Be careful ,self.param_groups It's a list , Is defined in the base class ,sgd Can't find in the . As can be seen from the picture above ,sgd Is in accordance with the self.param_groups To each params Perform gradient optimization ( Up or down )
Be careful sgd init Methods defaults Variable , This is for the base class init Methodical . of super, You can see b Stand a video , It's very detailed :
Back to base class , Pay attention to defaults notes :
The dictionary is used in the back setdefault Method to set the global default defaults For each group:
边栏推荐
- Is PMP really useful?
- 【PHP SPL笔记】
- Auto.js 获取手机所有app名字
- Flask project uses flask socketio exception: typeerror: function() argument 1 must be code, not str
- 如何设计 API 接口,实现统一格式返回?
- Weebly移动端网站编辑器 手机浏览新时代
- DBSync新增对MongoDB、ES的支持
- The sooner you understand the four rules of life, the more blessed you will be
- Dbsync adds support for mongodb and ES
- 一文搞懂常见的网络I/O模型
猜你喜欢
HarmonyOS第四次培训
10 distributed databases that take you to the galaxy
If you‘re running pod install manually, make sure flutter pub get is executed first.
Dynamically generate tables
高手勿进!写给初中级程序员以及还在大学修炼的“准程序员”的成长秘籍
Function pointer and pointer function in C language
Basic knowledge of road loss of 3GPP channel model
AOSP ~binder communication principle (I) - Overview
y58.第三章 Kubernetes从入门到精通 -- 持续集成与部署(三一)
Operand of null-aware operation ‘!‘ has type ‘SchedulerBinding‘ which excludes null.
随机推荐
背包问题(01背包,完全背包,动态规划)
Leetcode longest public prefix
ASP. Net MVC - resource cannot be found error - asp Net MVC – Resource Cannot be found error
Harmonyos fourth training
基于Bevy游戏引擎和FPGA的双人游戏
QT simple layout box model with spring
Batch normalization (Standardization) processing
磁盘监控相关命令
2039: [蓝桥杯2022初赛] 李白打酒加强版 (动态规划)
sublime使用技巧
Leetcode (46) - Full Permutation
If you‘re running pod install manually, make sure flutter pub get is executed first.
【二叉树】二叉树寻路
《四》表单
Timer create timer
Operand of null-aware operation ‘!‘ has type ‘SchedulerBinding‘ which excludes null.
Operand of null-aware operation ‘!‘ has type ‘SchedulerBinding‘ which excludes null.
Tencent cloud database public cloud market ranks top 2!
Creation and use of thread pool
Understand common network i/o models