-
Notifications
You must be signed in to change notification settings - Fork 5.6k
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
Fix for split op in BF16 inference #39548
Fix for split op in BF16 inference #39548
Conversation
Thanks for your contribution! |
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.
You did a good job. Could you please add a unit test to these changes in cpu_bfloat16_pass._tester.cc
?
@sfraczek Please help review, thanks ! |
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.
LGTM
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.
LGTM
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.
It looks good, however I had some comments.
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.
LGTM
@baoachun could you please review this PR? |
void CPUBFloat16Pass::SetOutputDataType(ir::Graph* graph) const { | ||
void AddDequantize(Graph* g, ir::Node* op, ir::Node* op_out, | ||
int& dequantize_counter) { | ||
if (op->Op()->Type() == "prior_box") return; |
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.
Why does prior_box return directly? Could you add descriptions or can we use set
to maintain operators that require special handling?
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.
@wozna could you please advise us on this prior_box
scenario?
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.
Prior_box output always produces floating-point results because these are prior boxes generated. Therefore, we do not need dequantization. And so far only this operator is behaving this way.
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.
Jakub may add comments in next PR, but this PR has passed all CIs and hopefully it could be merged
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.
LGTM
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.
LGTM
PR types
Bug fixes
PR changes
Others
Describe
Fix for
split
op in BF16 inference. Bug was related to incorrect handling of multi-output which was resolved in similar way to handling multi-input in ops such asconcat
.