File tree Expand file tree Collapse file tree 2 files changed +1
-17
lines changed Expand file tree Collapse file tree 2 files changed +1
-17
lines changed Original file line number Diff line number Diff line change @@ -1817,16 +1817,6 @@ void MoeGateDispatchPermuteInferMeta(const MetaTensor& x,
1817
1817
" The dimensions of Input(corr_bias) must be 1, but received "
1818
1818
" dimensions of Input(corr_bias) is [%d]" ,
1819
1819
corr_bias_dims.size ()));
1820
- PADDLE_ENFORCE_EQ (
1821
- corr_bias_dims[0 ],
1822
- x_dims[0 ],
1823
- common::errors::InvalidArgument (
1824
- " The dimensions of Input(corr_bias) must be equal to the first "
1825
- " dimension of Input(x), but received Input(corr_bias) first "
1826
- " dimension is [%d],"
1827
- " Input(x) first dimension is [%d]" ,
1828
- corr_bias_dims[0 ],
1829
- x_dims[0 ]));
1830
1820
PADDLE_ENFORCE_EQ (
1831
1821
corr_bias.dtype (),
1832
1822
paddle::DataType::FLOAT32,
Original file line number Diff line number Diff line change @@ -6487,17 +6487,11 @@ void IntBincountInferMeta(const MetaTensor& x,
6487
6487
int64_t high,
6488
6488
int64_t dtype,
6489
6489
MetaTensor* out) {
6490
- PADDLE_ENFORCE_EQ (
6491
- x.dims ().size (),
6492
- 1 ,
6493
- errors::InvalidArgument (
6494
- " The input 'x' of int_bincount must be a 1-D Tensor, but got %u-D." ,
6495
- x.dims ().size ()));
6496
6490
PADDLE_ENFORCE_GT (
6497
6491
high,
6498
6492
low,
6499
6493
errors::InvalidArgument (" Attr high (%d) must be > low (%d)." , high, low));
6500
- int64_t bin_count = high - low + 1 ;
6494
+ int64_t bin_count = high - low;
6501
6495
6502
6496
out->set_dims (phi::make_ddim ({bin_count}));
6503
6497
out->set_dtype (x.dtype ());
You can’t perform that action at this time.
0 commit comments