Git Product home page Git Product logo

asen's Introduction

Attribute-Specific Embedding Network

This repository is a PyTorch implementation of Attribute-Specific Embedding Network (ASEN) proposed in our paper Fine-Grained Fashion Similarity Learning by Attribute-Specific Embedding Network accepted by AAAI 2020.

Network

ASEN

Requirements

Environments

  • PyTorch 1.1.0
  • CUDA 10.1.168
  • Python 3.6.2

We use anaconda to create our experimental environment. You can rebuild it by the following commands.

conda create -n {your_env_name} python=3.6
conda activate {your_env_name}
pip install -r requirements.txt
...
conda deactivate

Download Data

Dataset Split

We supply our dataset split and some descriptions of the datasets with a bunch of meta files. Download them by the following script.

wget -c -P data/ http://www.maryeon.com/file/meta_data.tar.gz
cd data/
tar -zxvf meta_data.tar.gz

FashionAI Dataset

As the full FashionAI has not been publicly released, we utilize its early version for the FashionAI Global Challenge 2018. You can first sign in and download the data. Once done, you should uncompress them into the FashionAI directory:

unzip fashionAI_attributes_train1.zip fashionAI_attributes_train2.zip -d {your_project_path}/data/FashionAI

DARN Dataset

As some images’ URLs have been broken, only 214,619 images are obtained for our experiments. We provide with a series of URLs for the images.

DeepFashion Dataset

DeepFashion is a large dataset which consists of four benchmarks for various tasks in the field of clothing including category and attribute prediction which we use for our experiments, in-shop clothes retrieval, fashion landmark detection and consumer-to-shop clothes retrieval.

Zappos50k Dataset

We utilize identical split provided by Conditional SImilarity Network. To download the Zappos50k dataset and their triplet list, please refer to their repository.

Getting Started

All data prepared, you can simply train the model on FashionAI dataset(default)

python main.py --dataset FashionAI

there are also optional arguments for dataset, initial learning rate, batch size and so on. Check them by

python main.py --help

We also provide with an advanced version of ASEN, which has been included in model.py. The advanced version of ASEN can achieve the same performance as ASEN while requiring less than 50 epochs. You can train it by

python main.py --model ASENet_V2 --decay_rate 0.9 --step_size 3 --epochs 50

Testing

As training terminates, two snapshots are saved for testing. One is the model that has the highest performance on validation set and the other is the one of the latest epoch. You can load any of them and test on the test set.

python main.py --test [--dataset xx] --resume runs/{your_exp_name}/xx.pth.tar

Citing

If it's of any help to your research, consider citing our work:

@inproceedings{ma2020fine,
  title={Fine-Grained Fashion Similarity Learning by Attribute-Specific Embedding Network},
  author={Ma, Zhe and Dong, Jianfeng and Long, Zhongzi and Zhang, Yao and He, Yuan and Xue, Hui and Ji, Shouling},
  booktitle={Thirty-fourth AAAI Conference on Artificial Intelligence},
  year = {2020}
}

asen's People

Contributors

zju-zhangy avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.