# Facial Attribute Prediction Eval

> Tests the model's capability to predict multiple facial attributes (e.g., gender, hairstyle) from a single facial image as a multilabel classification task. It probes fine-grained visual feature extraction and attribute-level alignment. Use when the user wants to benchmark on CelebA, LFWA, or asks about evaluating this task. Reports Average Precision (AP).

- Skill: `qhjqhj00/facial-attribute-prediction-eval` (Agent Skill)
- Install (CLI): `npx skillmds add qhjqhj00/facial-attribute-prediction-eval`
- Raw SKILL.md: https://api.skillmd.com/api/skills/qhjqhj00/facial-attribute-prediction-eval/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: AI & ML
- Author: qhjqhj00 (https://skillmd.com/u/qhjqhj00)
- Updated: 2026-09-08
- Page: https://skillmd.com/skills/qhjqhj00/facial-attribute-prediction-eval

---


# facial-attribute-prediction-eval

> 15M Multimodal Facial Image-Text Dataset — Dawei Dai et al. (2024) (arXiv:2407.08515, 2024)

## What this evaluates

Tests the model's capability to predict multiple facial attributes (e.g., gender, hairstyle) from a single facial image as a multilabel classification task. It probes fine-grained visual feature extraction and attribute-level alignment.

## Datasets

- **CelebA** — total 182732; splits: train (162770), test (19962)
- **LFWA** — total ?; splits: train (6263), test (-1)

## Metrics

- `Average Precision (AP)` **(primary)** — range: percent
  - Mean Average Precision across all facial attributes. Computes the area under the precision-recall curve for each label and averages them across the attribute set.

## Input / output format

**Input**: A single facial image.

**Output**: A set of predicted binary labels for each facial attribute.

## Scoring recipe

```python
def compute_ap(predictions, gold):
    aps = []
    for pred_labels, true_labels in zip(predictions, gold):
        tp = 0
        precisions, recalls = [], []
        for i, pred in enumerate(pred_labels):
            if pred == true_labels[i]: tp += 1
            precisions.append(tp / (i + 1))
            recalls.append(tp / sum(true_labels))
        aps.append(np.trapz(precisions, recalls))
    return np.mean(aps) * 100
```

## Common pitfalls

- Evaluates across different training data scales (1%, 2%/10%, 100%), so results are not directly comparable without noting the subset size.
- Uses multiple feature aggregation strategies (CLS, mean, max pooling) combined via layer normalization before the final linear layer, which can inflate performance if not standardized.

## Evidence (verbatim from paper)

> Average precision (AP) was used as the evaluation index.

## Citation

```bibtex
@misc{dai2024facecaption,
  title={15M Multimodal Facial Image-Text Dataset},
  author={Dawei Dai et al. (2024)},
  year={2024},
  note={arXiv:2407.08515}
}
```

- arXiv: 2407.08515

