diff --git a/paddle/fluid/eager/utils.h b/paddle/fluid/eager/utils.h index 291d96ff0809f2dd4230782033b918cd23e4568a..7146261164900c279280b02dd127abc00c49dfd5 100644 --- a/paddle/fluid/eager/utils.h +++ b/paddle/fluid/eager/utils.h @@ -257,18 +257,21 @@ class EagerUtils { } else { tensor_name_str = t.name(); } - const char* TENSOR_INFO_TEMPLATE = "Type: %s, Dtype: %s, Place: %s"; + const char* TENSOR_INFO_TEMPLATE = + "Type: %s, Dtype: %s, Place: %s, Shape: %s"; std::string tensor_info_str = ""; if (t.defined()) { if (t.initialized()) { tensor_info_str += paddle::string::Sprintf(TENSOR_INFO_TEMPLATE, t.impl()->type_info().name(), t.dtype(), - t.place().DebugString()); + t.place().DebugString(), + t.dims()); } else { tensor_info_str += paddle::string::Sprintf(TENSOR_INFO_TEMPLATE, t.impl()->type_info().name(), "Unknown", + "Unknown", "Unknown"); } } else {