update op_version_registry, test=develop #26592
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
PR types
Bug fixes
PR changes
Others
Describe
为
NewAttr
添加默认值参数。核心接口:
AddCheckpoint(string summary, OpVersionDesc desc)
此方法会触发Op
的version++
OpVersionDesc
,用于注册本次升级对应的修改点NewAttr(name, default_value)
表示增加了一个attribute
,并需要指定其向前兼容的默认值ModifyAttr(name, default_value)
表示修改了attribute
的行为,并需要指定其向前兼容的默认值其他注册方法可以按需增加
全局的
op_capatible_info
会记录每个Op
最新的版本号(version checkpoint
的次数),并通过save_inference_model
存储到模型中。其中记录的版本及描述,会帮助
Inference
和Lite
来对应升级策略;也可以自动搜集作为Release Notes
的来源。设计文档见 Agroup:Op 版本监控及兼容性识别设计(#3366223)