-
Notifications
You must be signed in to change notification settings - Fork 825
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
GlobalMultiClientEnv and refine EagerExecution #5523
Conversation
Maybe<bool> GlobalMultiClientEnv(); | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这个接口放在env_desc.h文件中是不是更合适一点。还可以基于这个接口简单重构一下api中IsMultiClient的实现
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
嗯,跟env放在一起比较好
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
改了,放在 env 里了。另外 api 里面的我没动,感觉重构也没太大意义,还省去了一个 include。
…eflow-Inc/oneflow into dev_cc_lazy_mode_enable_eager
Global<GlobalJobBuildAndInferCtxMgr>
的逻辑,首先会判断是否是 Multi-Client:- 如果是 Multi-Client,直接返回 LazyMgr
- 如果是 Single-Client,再根据 Single-Client 下的逻辑判断是否设置了标记 eager_execution_enabled,如果是,则 Eager 执行 global_function ,否则 Lazy 执行 global_function
这样我们新版的 torch 代码就跟 enable_eager_execution 完全无关了。
本 PR 不依赖对 enable_eager_execution 标记的移除;也不依赖 Compatible Single-Client 的迁移