Skip to content

Commit acd0636

Browse files
authored
Reduce log noise (pytorch#15244)
same as pytorch#15163
1 parent dbdeb49 commit acd0636

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

extension/named_data_map/merged_data_map.cpp

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -69,11 +69,10 @@ ET_NODISCARD Result<const TensorLayout> MergedDataMap::get_tensor_layout(
6969
ET_NODISCARD
7070
Result<FreeableBuffer> MergedDataMap::get_data(string_view key) const {
7171
const auto it = key_to_map_index_.find(key.data());
72-
ET_CHECK_OR_RETURN_ERROR(
73-
it != key_to_map_index_.end(),
74-
NotFound,
75-
"Key %s not found in named data maps",
76-
key.data());
72+
if (it == key_to_map_index_.end()) {
73+
ET_LOG(Debug, "Key %s not found in named data maps.", key.data());
74+
return Error::NotFound;
75+
}
7776
return named_data_maps_.at(it->second)->get_data(key);
7877
}
7978

0 commit comments

Comments
 (0)