Correct labels. Args: labels: TODO.
(labels)
| 176 | |
| 177 | |
| 178 | def correct_labels(labels): |
| 179 | """Correct labels. |
| 180 | |
| 181 | Args: |
| 182 | labels: TODO. |
| 183 | """ |
| 184 | labels_id = 0 |
| 185 | id2id = {} |
| 186 | new_labels = [] |
| 187 | for i in labels: |
| 188 | if i not in id2id: |
| 189 | id2id[i] = labels_id |
| 190 | labels_id += 1 |
| 191 | new_labels.append(id2id[i]) |
| 192 | return np.array(new_labels) |
| 193 | |
| 194 | |
| 195 | def merge_seque(distribute_res): |
no outgoing calls
no test coverage detected
searching dependent graphs…