-
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
Support static graph code-gen for bincount #54686
Conversation
你的PR提交成功,感谢你对开源项目的贡献! |
@heavyrain-lzy 麻烦研发大哥看看 |
scalar: | ||
minlength: | ||
data_type : int | ||
support_tensor : true |
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.
由于GetExpectedKernelType
特殊,建议修改如下:
- 这里配置:
get_expected_kernel_type :
bincount : GetBincountExpectedKernelType
- 在
paddle/fluid/operators/generator/get_expected_kernel_func.cc
增加函数:
phi::KernelKey GetBincountExpectedKernelType(
const framework::ExecutionContext &ctx,
const framework::OperatorWithKernel* op_ptr) {
auto data_type =
ctx.HasInput("Weights")
? op_ptr->IndicateVarDataType(ctx, "Weights")
: op_ptr->IndicateVarDataType(ctx, "X");
return phi::KernelKey(data_type, ctx.device_context().GetPlace());
}
- 在
paddle/fluid/operators/generator/get_expected_kernel_func.h
添加d对应函数声明:
phi::KernelKey GetBincountExpectedKernelType(
const framework::ExecutionContext &ctx,
const framework::OperatorWithKernel* op_ptr);
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.
GetExpectedKernelType
感谢研发大哥,请问是怎么的出“GetExpectedKernelType”的结论的呢?我可以怎么调试复线知道要调整这个地方
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.
GetExpectedKernelType
感谢研发大哥,请问是怎么的出“GetExpectedKernelType”的结论的呢?我可以怎么调试复线知道要调整这个地方
目前
kernel :
data_type :
中的data_type
仅仅允许配置根据输入tensor,如data_type : x
或者一个DataType
类型的attribute如data_type : dtype
,或者二者的结合data_type : dtype > x
。不支持两个tensor优先级配置配置,如data_type : weights > x
rerun一下coverage,貌似随机挂 |
如果多次rerun均失败,请comment |
多次return 仍然失败 |
但是coverage是在环境准备阶段就失败了,感觉不是代码的问题。建议重新提交一个commit,将所有的CI都重新触发一下。非常感谢您的贡献! |
收到,已return所有Ci |
还是挂coverage |
现在rerun一下,已经把 |
@heavyrain-lzy 现在应该没问题了 |
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
Others
PR changes
Others
Description
#53267