|
|
|
@ -117,8 +117,9 @@ bool VariableResponse::CopyLodTensorData(
|
|
|
|
|
tensor->mutable_data(ctx.GetPlace(), ToVarType(meta_.data_type()));
|
|
|
|
|
|
|
|
|
|
VLOG(6) << "Tensor.memory_size = " << tensor->memory_size()
|
|
|
|
|
<< ", Buffer Size = " << length;
|
|
|
|
|
PADDLE_ENFORCE_EQ(tensor->memory_size(), static_cast<unsigned int>(length));
|
|
|
|
|
<< ", Buffer Size = " << length << ", dims:" << dims
|
|
|
|
|
<< ", numel:" << tensor->numel();
|
|
|
|
|
PADDLE_ENFORCE_GE(tensor->memory_size(), static_cast<unsigned int>(length));
|
|
|
|
|
return ReadRaw(input, ctx, tensor->place(), tensor_data, length);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|