Browse Source

!15066 clean code

From: @hwjiaorui
Reviewed-by: @kisnwang,@jjfeing
Signed-off-by: @jjfeing
pull/15066/MERGE
mindspore-ci-bot Gitee 4 years ago
parent
commit
c2c20e8173
3 changed files with 1 additions and 3 deletions
  1. +1
    -1
      mindspore/ccsrc/backend/optimizer/ascend/format_type/check_consistency.cc
  2. +0
    -1
      mindspore/ccsrc/backend/optimizer/ascend/ir_fission/gather_v2_ds_fission.cc
  3. +0
    -1
      mindspore/ccsrc/debug/data_dump/e2e_dump.cc

+ 1
- 1
mindspore/ccsrc/backend/optimizer/ascend/format_type/check_consistency.cc View File

@@ -39,7 +39,7 @@ bool CheckFormatForConsistency(const CNodePtr &node, const size_t input_index) {
if (pre_output_format == kOpFormat_DEFAULT || selected_input_format == kOpFormat_DEFAULT) {
string checking_format = (pre_output_format == kOpFormat_DEFAULT) ? selected_input_format : pre_output_format;
// when input shape size is 1D, default format and NC1HWC0 are compatible
if (input_origin_shape.size() == 1 && checking_format == kOpFormat_NC1HWC0) {
if (input_origin_shape.size() == 1) {
return true;
}
if (kDefaultCompatibleFormat.find(checking_format) != kDefaultCompatibleFormat.end()) {


+ 0
- 1
mindspore/ccsrc/backend/optimizer/ascend/ir_fission/gather_v2_ds_fission.cc View File

@@ -128,7 +128,6 @@ bool CheckInputs(const CNodePtr &origin_node) {
}
auto param_shape = AnfAlgo::GetPrevNodeOutputInferShape(origin_node, 0);
auto indice_shape = AnfAlgo::GetPrevNodeOutputInferShape(origin_node, 1);

// this optimizer only support embedding_table has dynamic shape
if (param_shape.empty() || indice_shape.empty() || AnfAlgo::IsDynamicShape(origin_node->input(2))) {
return false;


+ 0
- 1
mindspore/ccsrc/debug/data_dump/e2e_dump.cc View File

@@ -32,7 +32,6 @@
#endif

namespace mindspore {

bool E2eDump::IsDeviceTargetGPU() {
auto context = MsContext::GetInstance();
MS_EXCEPTION_IF_NULL(context);


Loading…
Cancel
Save