Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion paddle/phi/kernels/impl/accuracy_check_kernel_impl.h
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ struct AccuracyCheckFunctor<phi::CPUContext, phi::dtype::complex<T>> {
for (int i = 0; i < num; i++) {
out_data[i] = true;
}
bool val;
bool val = false;
int res_index = -1;
for (int i = 0; i < num; i++) {
const phi::dtype::complex<T> a = in_a[i], b = in_b[i];
Expand Down
4 changes: 2 additions & 2 deletions paddle/phi/kernels/impl/einsum_grad_kernel_impl.h
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ DenseTensor PerformTileAndReduction(const Context& dev_ctx,
std::vector<int64_t> resize_dims;
std::vector<int64_t> recover_shape;
std::vector<int64_t> t_shape = common::vectorize<int64_t>(t.dims());
for (int i = 0; i < op_label.size(); i++) {
for (size_t i = 0; i < op_label.size(); i++) {
int c = op_label[i];
if (label2type[c] == LabelType::Reduction) {
repeat_times.push_back(label2shape[c]);
Expand All @@ -64,7 +64,7 @@ DenseTensor PerformTileAndReduction(const Context& dev_ctx,
"shape size: `%d`, but got label nums: `%d`",
t_shape.size(),
op_label.size()));
for (int i = 0; i < op_label.size(); i++) {
for (size_t i = 0; i < op_label.size(); i++) {
int c = op_label[i];
if (label2type[c] == LabelType::Contraction &&
t_shape[i] != label2shape[c]) {
Expand Down