diff --git a/paddle/fluid/operators/multinomial_op.cu b/paddle/fluid/operators/multinomial_op.cu index 64c4af3022984..2762f0ce9bd46 100644 --- a/paddle/fluid/operators/multinomial_op.cu +++ b/paddle/fluid/operators/multinomial_op.cu @@ -151,7 +151,7 @@ class MultinomialOpKernel MultinomialFunctor(cpu_out_data, cpu_in_data, num_samples, replacement, num_categories, num_distributions); - cudaMemcpy(out_data, cpu_out_data, out_data_numel * sizeof(T), + cudaMemcpy(out_data, cpu_out_data, out_data_numel * sizeof(int64_t), cudaMemcpyHostToDevice); delete[] cpu_in_data;