提交 a604e42d 编写于 作者: S Shiyuan Shang-Guan

Merge branch 'dev_bert' of https://github.com/Oneflow-Inc/oneflow into dev_multi-socket


Former-commit-id: a461fe8eb9215a132475bd97ecc3647ce7913f7e
......@@ -372,10 +372,13 @@ void OpGraph::InferNoParallelBlobDesc() const {
parallel_ctx.set_parallel_id(0);
parallel_ctx.set_parallel_num(1);
parallel_ctx.set_policy(op_node->parallel_desc().policy());
// the real important data we want to get is:
// a) model blobs' byte size;
// b) number of axes of blobs' body shape;
// Hence the argument record_piece_size can be any positive number, here it's 1
op_node->op().InferBlobDescsIf(
std::bind(&OpNode::NoParallelBlobDesc4BnInOp, op_node, std::placeholders::_1),
&parallel_ctx, job_desc_->RecordPieceSize() / op_node->parallel_desc().parallel_num(),
[](OpContext*) {});
&parallel_ctx, 1, [](OpContext*) {});
});
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册