!48651 [MD] TFRecord Warning LOG Bug Fix

Merge pull request !48651 from davidanugraha/tfrecord_log_bug_fix
This commit is contained in:
i-robot 2023-02-10 01:25:57 +00:00 committed by Gitee
commit a8852757af
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
1 changed files with 1 additions and 1 deletions

View File

@ -91,7 +91,7 @@ Status TFReaderOp::Init() {
RETURN_STATUS_UNEXPECTED(
"[Internal ERROR] num_samples or num_rows for TFRecordDataset must be greater than 0, but got: " +
std::to_string(total_rows_));
} else if (compression_type_ == CompressionType::NONE && total_rows_ == 0) {
} else if (compression_type_ != CompressionType::NONE && total_rows_ == 0) {
MS_LOG(WARNING) << "Since compression_type is set, but neither num_samples nor numRows (from schema file) "
<< "is provided, performance might be degraded.";
}