StripBlankNode returns a copy of the map where all the keys have the blank node prefix removed.
(mp map[string]uint64)
| 3124 | |
| 3125 | // StripBlankNode returns a copy of the map where all the keys have the blank node prefix removed. |
| 3126 | func StripBlankNode(mp map[string]uint64) map[string]uint64 { |
| 3127 | temp := make(map[string]uint64) |
| 3128 | for k, v := range mp { |
| 3129 | if strings.HasPrefix(k, "_:") { |
| 3130 | temp[k[2:]] = v |
| 3131 | } |
| 3132 | } |
| 3133 | return temp |
| 3134 | } |
| 3135 | |
| 3136 | // calculateMetrics populates the given map with the number of UIDs that were seen |
| 3137 | // for each predicate. |