Skip to content

Commit

Permalink
fix bug
Browse files Browse the repository at this point in the history
  • Loading branch information
wejoncy committed Dec 16, 2024
1 parent d3d25b9 commit d053dc0
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,10 @@ CoreMLExecutionProvider::GetCapability(const onnxruntime::GraphViewer& graph_vie
[](unsigned char c) { return !std::isalnum(c); })) {
user_provided_key = std::to_string(std::hash<std::string>{}(user_provided_key));
}
// invalid cache-key
if (user_provided_key.size() == 0){
user_provided_key = std::to_string(model_hash);
}
} else {
// model_hash is a 64-bit hash value of model_path if model_path is not empty,
// otherwise it hashes the graph input names and all the node output names.
Expand Down

0 comments on commit d053dc0

Please sign in to comment.