MMFashion: An Open-Source Toolbox for Visual Fashion Analysis

Xin Liu, Jiancheng Li, Jiaqi Wang, Ziwei Liu

TL;DR

MMFashion is a comprehensive, PyTorch-based open-source toolbox designed to unify diverse visual fashion analysis tasks—from attribute prediction to outfit recommendation—into a single, modular framework. By providing a "one-stop shop" with pre-trained models and standardized benchmarks, it lowers the barrier for both researchers and developers to build sophisticated fashion AI applications.

What Problem Does This Paper Address?

While the fashion industry has embraced AI for everything from online search to personalized styling, the research landscape has remained fragmented. Before MMFashion, there was no unified codebase to handle the wide variety of fashion-related computer vision tasks. Researchers often had to jump between different, incompatible repositories to perform tasks like landmark detection, cloth retrieval, or instance segmentation.

This fragmentation creates a high "tax" on innovation: it makes it difficult to compare different algorithms fairly and prevents "layman" users—developers without deep CV expertise—from easily integrating state-of-the-art fashion analysis into their projects. MMFashion aims to bridge this gap by providing a flexible, user-friendly platform that covers almost all mainstream fashion analysis tasks.

Methods

The core philosophy of MMFashion is modular design. Borrowing successful patterns from the OpenMMLab ecosystem (like MMDetection), the authors decompose the fashion analysis pipeline into two primary abstractions:

  1. Backbone: This component (e.g., ResNet, VGG) transforms an input image into feature maps.
  2. Head: This is the task-specific part of the network that takes those features and produces predictions, such as an attribute predictor, a clothes retriever, or a landmark regressor.
The modular framework of MMFashion separates general feature extraction (Backbone) from task-specific logic (Head).

This separation allows developers to "mix and match" components. For example, you could easily swap a ResNet backbone for a newer architecture while keeping the same retrieval head. The toolbox also utilizes a unified training pipeline with a "hooking" mechanism, making it easy to inject custom logic (like learning rate updates or checkpointing) at specific steps in the training loop.

Datasets

MMFashion leverages and extends several key industry-standard datasets:

  • DeepFashion: A massive dataset of over 800,000 images used for attribute prediction, retrieval, and landmark detection.
  • Polyvore: Used for fashion compatibility and recommendation tasks, featuring rich multimodal information (images + text).
  • New Annotations: The authors contributed new COCO-style annotations for clothes detection and segmentation based on the "In-Shop Clothes" benchmark, providing a more accurate open-source resource for fashion parsing.

Key Insights and Ideas

  • Unified Benchmarking: By implementing multiple tasks in one place, MMFashion allows for a "common ground" comparison. The authors demonstrate this by benchmarking various backbones (VGG vs. ResNet) and pooling strategies across different tasks.
  • Landmark Pooling vs. Global Pooling: For attribute prediction, the authors found that "landmark pooling"—extracting features specifically around functional regions like necklines or cuffs—significantly outperforms "global pooling" (using the whole image). For instance, using a ResNet50 backbone, landmark pooling improved Top-5 recall from 23.52% to 30.84%.
  • Ease of Extensibility: The modularity isn't just for the authors; it's for the community. The framework is designed so that adding a new task often just requires defining a new "Head" and a corresponding configuration file.

Key Results

The paper provides a comprehensive benchmark of the toolbox's capabilities:

  • Attribute Prediction: Achieved high precision, with Top-5 accuracy reaching ~99.3% using a ResNet50 backbone with landmark pooling.
  • Landmark Detection: The toolbox provides robust performance across varying distances from ground truth, as shown in their PDL (Percentage of Detected Landmarks) curves.
  • Retrieval: The framework supports both "In-shop" and the more challenging "Consumer-to-Shop" retrieval. As expected, in-shop retrieval (where both query and target are professional photos) shows higher accuracy than consumer-to-shop (where queries are often messy, real-world photos).
Visual examples of the diverse tasks supported by MMFashion, including attribute prediction, retrieval, and compatibility scoring.

Limitations and Future Work

While MMFashion is currently the most complete platform of its kind, the authors acknowledge it is a "still-growing" effort.

  • Synthesis Tasks: The current version focuses primarily on analysis. Future updates aim to include synthesis tasks, such as virtual try-on, which would allow users to see how clothes look on different bodies.
  • Community Driven: The long-term success of the toolbox depends on community contributions to keep up with the rapid pace of fashion AI research.

For those interested in exploring the code or contributing, the project is hosted at https://github.com/open-mmlab/mmfashion.

Summary updated

BibTeX
@inproceedings{liu2021mmfashion,
  author = {Xin Liu and Jiancheng Li and Jiaqi Wang and Ziwei Liu},
  title = {{MMFashion: An Open-Source Toolbox for Visual Fashion Analysis}},
  booktitle = {ACM Multimedia},
  year = {2021},
  doi = {10.1145/3474085.3478327},
}
Figure