Skip to content

Commit

Permalink
Ftarget string -> Target object works!
Browse files Browse the repository at this point in the history
  • Loading branch information
electriclilies committed Aug 20, 2021
1 parent 6be39dd commit 1022fed
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/relay/backend/interpreter.cc
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,11 @@ namespace {
struct PairHash {
template <typename T1, typename T2>
std::size_t operator()(const std::pair<T1, T2>& k) const {
return std::hash<T1>()(k.first) ^ std::hash<T2>()(k.second);
return dmlc::HashCombine(std::hash<T1>()(k.first), std::hash<T2>()(k.second));
}
template <typename T2>
std::size_t operator()(const std::pair<Target, T2>& k) const {
return dmlc::HashCombine(ObjectHash()(k.first), std::hash<T2>()(k.second));
}
};

Expand Down

0 comments on commit 1022fed

Please sign in to comment.