!48270 fix somas dump info

Merge pull request !48270 from 王禹程/fix_somas_dump
This commit is contained in:
i-robot 2023-02-01 08:34:36 +00:00 committed by Gitee
commit e6c4fab2ef
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
1 changed files with 5 additions and 2 deletions

View File

@ -1920,8 +1920,11 @@ void Somas::DumpTensors(std::ostringstream &oss) const {
MS_EXCEPTION_IF_NULL(node);
auto scope_name = node->scope_full_name_;
std::string split_name = GetSplitName(scope_name);
oss << "%" << tensor->GetId() << "T"
<< "\t"
std::string dump_tensor_str = "T";
if (tensor->GetTypeString() == "Control") {
dump_tensor_str = "CT";
}
oss << "%" << tensor->GetId() << dump_tensor_str << "\t"
<< "#" << tensor->GetAlignedSize() << "S"
<< "\t"
<< "#" << tensor->GetOriginalSize() << "S"