当前位置:网站首页>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:
边栏推荐
- 最长公共子序列(LCS)(动态规划,递归)
- 第一篇论文的写作流程
- sublime使用技巧
- 一个酷酷的“幽灵”控制台工具
- App embedded H5 --- iPhone soft keyboard blocks input text
- Pointer and array are input in function to realize reverse order output
- Harmonyos fourth training
- 拿到PMP认证带来什么改变?
- [question] Compilation Principle
- Operand of null-aware operation ‘!‘ has type ‘SchedulerBinding‘ which excludes null.
猜你喜欢
Is PMP really useful?
[opencv] image morphological operation opencv marks the positions of different connected domains
Ansible概述和模块解释(你刚走过了今天,而扑面而来的却是昨天)
使用知云阅读器翻译统计遗传学书籍
Understand common network i/o models
- [email protected] Mapping relatio"/>
Why JSON is used for calls between interfaces, how fastjson is assigned, fastjson 1.2 [email protected] Mapping relatio
PMP证书有没有必要续期?
QT simple layout box model with spring
Y58. Chapter III kubernetes from entry to proficiency - continuous integration and deployment (Sany)
LabVIEW在打开一个新的引用,提示内存已满
随机推荐
Salesforce 容器化 ISV 场景下的软件供应链安全落地实践
Pointer and array are input in function to realize reverse order output
U++ metadata specifier learning notes
U++ game learning notes
DFS,BFS以及图的遍历搜索
Leetcode minimum difference in student scores
Why is the salary of test and development so high?
DBSync新增对MongoDB、ES的支持
使用知云阅读器翻译统计遗传学书籍
Wonderful express | Tencent cloud database June issue
一个酷酷的“幽灵”控制台工具
Using thread class and runnable interface to realize the difference between multithreading
U++ 游戏类 学习笔记
线程池的创建与使用
Leetcode(417)——太平洋大西洋水流问题
Simulate thread communication
SQL injection - secondary injection and multi statement injection
npm ERR! 400 Bad Request - PUT xxx - “devDependencies“ dep “xx“ is not a valid dependency name
想要选择一些部门优先使用 OKR, 应该如何选择试点部门?
动态生成表格