Home

Awesome

Build Status

This repo contains the Amazon Mechanical Turk (AMT) workflow scripts for the paper:

MSeg: A Composite Dataset for Multi-domain Semantic Segmentation (CVPR 2020, Official Repo) [PDF] <br> John Lambert*, Zhuang Liu*, Ozan Sener, James Hays, Vladlen Koltun <br> Presented at CVPR 2020. Link to MSeg Video (3min)

This repo is the fourth of 4 repos that introduce our work. It provides utilities to perform large-scale Mechanical Turk re-labeling.

One additional repo will be introduced in August 2020:

<p align="left"> <img src="https://user-images.githubusercontent.com/62491525/83895683-094caa00-a721-11ea-8905-2183df60bc4f.gif" height="215"> <img src="https://user-images.githubusercontent.com/62491525/83893966-aeb24e80-a71e-11ea-84cc-80e591f91ec0.gif" height="215"> </p> <p align="left"> <img src="https://user-images.githubusercontent.com/62491525/83895915-57fa4400-a721-11ea-8fa9-3c2ff0361080.gif" height="215"> <img src="https://user-images.githubusercontent.com/62491525/83895972-73654f00-a721-11ea-8438-7bd43b695355.gif" height="215"> </p> <p align="left"> <img src="https://user-images.githubusercontent.com/62491525/83893958-abb75e00-a71e-11ea-978c-ab4080b4e718.gif" height="215"> <img src="https://user-images.githubusercontent.com/62491525/83895490-c094f100-a720-11ea-9f85-cf4c6b030e73.gif" height="215"> </p> <p align="left"> <img src="https://user-images.githubusercontent.com/62491525/83895811-35682b00-a721-11ea-9641-38e3b2c1ad0e.gif" height="215"> <img src="https://user-images.githubusercontent.com/62491525/83896026-8710b580-a721-11ea-86d2-a0fff9c6e26e.gif" height="215"> </p>

Dependencies

Install the mseg module from mseg-api.

Install the MSeg-mturk module:

Make sure that you can run import mseg_mturk in python, and you are good to go!

Repo Contents

This repository contains the following items:

Work Statistics

Most time-intensive tasks:

Workflow Overview

We design a careful workflow to ensure a high quality bar for annotations submitted by Mechanical Turk workers.

Our re-labeling workflow proceeds in 6 main stages:

(1) Hand-classify sentinels for each task, and create a BatchResult class with SentinelHIT specification.
(2) Run `mseg_mturk/publish_tasks.py` to generate HIT html, HIT csv, and instructions html. Sentinels are embedded into the 100-image HIT csv.
(2) Submit HIT on Amazon Mechanical Turk (AMT).
(2) Analyze accuracy of each submitted HIT using `mseg_mturk/eval_result.py`. 
	For each one, for all 100 images, check if it is a sentinel.
	If it is a sentinel, check correctness. Compute mean accuracy per HIT.
	Set status in WorkerHITResult for each HIT to 'Approved' or 'Rejected'
	based on 100% accuracy cutoff.

(3) Enter WorkerHITResult decisions into 'analyzed' version of csv. Upload analyzed csv to MTurk, and re-assign rejected jobs.
(4) Analyze multinomial worker agreement. For those HITs that were approved, 
	make a list of assigned labels per URL. Also record the number of approved
	observations per image.
(5) Take mode from approved, consider this the relabeled category.
(6) Manually review batch quality.
(7) Record relabeled list for each (dataset, original_classname) tuple.

Class Examplar Images

Via Google Drive, we provide access to the class examplar images we provided to MTurk annotators in their instructions: animals, rug vs. carpet, cabinet, nightstand, desk, chest-of-drawers, wardrobe, curtain vs. shower curtain, mountain vs. hill vs. snow, fence vs. guardrail, and all other shattered classes.

Example MTurk UIs

<p align="center"> <img src="https://user-images.githubusercontent.com/16724970/85213302-8c2d5180-b32a-11ea-9cd0-e298d0897918.png" width="950"> <img src="https://user-images.githubusercontent.com/16724970/85213174-c85fb280-b328-11ea-9261-6e860abc48c6.png" width="860"> <img src="https://user-images.githubusercontent.com/16724970/85214862-c43e8f80-b33e-11ea-9610-b35ede449f40.jpeg" width=860"> </p>

Citing MSeg

If you find this code useful for your research, please cite:

@InProceedings{MSeg_2020_CVPR,
author = {Lambert, John and Liu, Zhuang and Sener, Ozan and Hays, James and Koltun, Vladlen},
title = {{MSeg}: A Composite Dataset for Multi-domain Semantic Segmentation},
booktitle = {Computer Vision and Pattern Recognition (CVPR)},
year = {2020}
}

Acknowledgements

Many thanks to Qifeng Chen for his base AMT workflow, which he shared with us. We are also grateful to the Amazon Mechanical Turk workers who completed 1.34 years of uninterrupted annotation to make MSeg happen!