Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
xiaoxiong74 committed Dec 2, 2020
1 parent 7de699a commit c1fe63c
Show file tree
Hide file tree
Showing 5 changed files with 76 additions and 29 deletions.
3 changes: 1 addition & 2 deletions .idea/deployment.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

87 changes: 66 additions & 21 deletions .idea/workspace.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ python face-cluster-by-infomap
| GCN-V + GCN-E | 92.56 | 83.74 | 87.93 |
| Infomap(ours)(k=50,min_sim=0.58) | 95.50 | 92.51 | 93.98 |

![avatar](./image/evaluate.png)
![](image/evaluate.png)

## Results on YouTube-Faces

Expand Down
2 changes: 2 additions & 0 deletions data/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ The data directory is constucted as follows:
- `features` currently supports binary file.
- `labels` supports plain text where each line indicates a label corresponding to the feature file.
```

### Feature Extraction
To experiment with your own face pictures, it is required to extracted face features from the pictures.

Expand Down
11 changes: 6 additions & 5 deletions face-cluster-by-infomap.py
Original file line number Diff line number Diff line change
Expand Up @@ -231,11 +231,12 @@ def cluster_by_infomap(nbrs, dists, pred_label_path, save_result=False):
for idx in range(idx_len):
of.write(str(idx2label[idx]) + '\n')

pred_labels = intdict2ndarray(idx2label)
true_lb2idxs, true_idx2lb = read_meta(label_path)
gt_labels = intdict2ndarray(true_idx2lb)
for metric in metrics:
evaluate(gt_labels, pred_labels, metric)
if label_path is not None:
pred_labels = intdict2ndarray(idx2label)
true_lb2idxs, true_idx2lb = read_meta(label_path)
gt_labels = intdict2ndarray(true_idx2lb)
for metric in metrics:
evaluate(gt_labels, pred_labels, metric)


def get_dist_nbr(feature_path, k=80, knn_method='faiss-cpu'):
Expand Down

0 comments on commit c1fe63c

Please sign in to comment.