This repository contains the segmentation user interface from the OpenSurfaces project, extracted as a lightweight tool

Overview

OpenSurfaces Segmentation UI

This repository contains the segmentation user interface from the OpenSurfaces project, extracted as a lightweight tool. A dummy server backend is included to run the demo.

You can also view the demo online.

To run the demo, there are two versions: one with django, and one with no framework. The django version uses a dummy django server and compiles the website live as necessary. The non-django version is a flat html file extracted from the django version.

If you find this tool helpful, please cite our project:

@inproceedings{bell13opensurfaces,
	author = "Sean Bell and Paul Upchurch and Noah Snavely and Kavita Bala",
	title = "OpenSurfaces: A Richly Annotated Catalog of Surface Appearance",
	booktitle = "SIGGRAPH Conf. Proc.",
	volume = "32",
	number = "4",
	year = "2013",
}

and report any bugs using the GitHub issue tracker. Also, please "star" this project on GitHub; it's nice to see how many people are using our code.

Version 1: Run with Django (Ubuntu Linux)

  1. Install dependencies (coffee-script, django, django-compressor, ua-parser, BeautifulSoup):

    Note: this will change your django current installation if you are not somewhere between 1.4.* and 1.6.*. I suggest looking into the virtualenv package if this is a problem for you.

./django-setup-demo.sh
  1. Start the local webserver:
./django-run-demo.sh
  1. Visit localhost:8000 in a web browser

To get the demo to work on Mac and Windows, you will have to look at the above scripts and run the equivalent commands for your system.

After drawing 6 polygons, the submit button will show you the POST data that would have been sent to the server.

Version 2: Run without Django (Linux or Mac)

  1. Install npm and node.js. On Ubuntu, this is:
sudo apt-get install npm nodejs
  1. Install coffee-script:
sudo npm install -g coffee-script
  1. Build static files (js, css, img) and then start a local python-based webserver:
./python-run-demo.sh
  1. Visit localhost:8000 in a web browser

To get the demo to work on Windows, you will have to look at the above scripts and run the equivalent commands for your system.

Project Notes

POST data

When a user submits, the client will POST the data to the same URL. On success, the client expects the JSON response {"message": "success", "result": "success"}. The client will then notify the MTurk server that the task is completed. For more details, see example_project/segmentation/views.py.

When a user submits, the POST will contain these fields:

results: a dictionary mapping from the photo ID (which is just "1" in
	this example) to a list of polygons.  Example:
	{"1": [[x1,y1,x2,y2,x3,y3,...], [x1,y1,x2,y2,...]]}.
	Coordinates are scaled with respect to the source photo dimensions, so both
	x and y are in the range 0 to 1.

time_ms: amount of time the user spent (whether or not they were active)

time_active_ms: amount of time that the user was active in the current window

action_log: a JSON-encoded log of user actions

screen_width: user screen width

screen_height: user screen height

version: always "1.0"

feedback: omitted if there is no feedback; JSON encoded dictionary of the form:
{
	'thoughts': user's response to "What did you think of this task?",
	'understand': user's response to "What parts didn't you understand?",
	'other': user's response to "Any other feedback, improvements, or suggestions?"
}

Feedback survey

When the user finishes the task, a popup will ask for feedback. In the django version, disable this by setting ask_for_feedback to 'false' in the file example_project/segmentation/vies.py. In the non-django verfsion, update the window.ask_for_feedback variable in index.html.

I recommend asking for feedback after the 2nd or 3rd time a user has submitted, not the first time, and then not asking again (otherwise it gets annoying). Users usually don't have feedback until they have been working for a little while.

Compiling from coffeescript

The javascript for the tool is automatically compiled from coffeescript files by django-compressor and accessed by the client at a url of the form /static/cache/js/*.js. This is set up already if using django.

If not using django, the python-run-demo.sh does this for you by manually compiling coffeescript files and storing them in the /static/ folder.

Browser compatibility

This UI works in Chrome and Firefox only. The Django version includes a browser check that shows an error page if the user is not on Chrome or Firefox or is on a mobile device.

Local /static/ folder

After you run the demo setup, the directory /static/ will contain compiled css and javascript files.

If you are usikng django and change any part of the static files (js, css, images, coffeescript), you will need to repopulate the static folder with this command:

example_project/manage.py collectstatic --noinput

If you are building on top of this repository:

In example_project/settings.py:

  1. Change SECRET_KEY to some random string.
  2. Fill in the rest of the values (admin name, database, etc).

If you want to add this demo to your own (separate) Django project:

In your settings.py file, make the following changes:

  1. Make sure STATIC_ROOT is set to an absolute writable path.

  2. Add this to the STATICFILES_FINDERS tuple:

	'compressor.finders.CompressorFinder',
  1. Add this to the INSTALLED_APPS tuple:
	'django.contrib.humanize',
	'compressor',
	'segmentation',
  1. Add this to settings.py (e.g. at the end):
	# Django Compressor
	COMPRESS_ENABLED = True
	COMPRESS_OUTPUT_DIR = 'cache'
	COMPRESS_PRECOMPILERS = (
		('text/coffeescript', 'coffee --bare --compile --stdio'),
		('text/less', 'lessc -x {infile} {outfile}'),
	)
Owner
Sean Bell
CEO and Co-Founder, GrokStyle Inc. PhD, Cornell University
Sean Bell
[Preprint] "Chasing Sparsity in Vision Transformers: An End-to-End Exploration" by Tianlong Chen, Yu Cheng, Zhe Gan, Lu Yuan, Lei Zhang, Zhangyang Wang

Chasing Sparsity in Vision Transformers: An End-to-End Exploration Codes for [Preprint] Chasing Sparsity in Vision Transformers: An End-to-End Explora

VITA 64 Dec 08, 2022
Combining Automatic Labelers and Expert Annotations for Accurate Radiology Report Labeling Using BERT

CheXbert: Combining Automatic Labelers and Expert Annotations for Accurate Radiology Report Labeling Using BERT CheXbert is an accurate, automated dee

Stanford Machine Learning Group 51 Dec 08, 2022
An original implementation of "Noisy Channel Language Model Prompting for Few-Shot Text Classification"

Channel LM Prompting (and beyond) This includes an original implementation of Sewon Min, Mike Lewis, Hannaneh Hajishirzi, Luke Zettlemoyer. "Noisy Cha

Sewon Min 92 Jan 07, 2023
LF-YOLO (Lighter and Faster YOLO) is used to detect defect of X-ray weld image.

This project is based on ultralytics/yolov3. LF-YOLO (Lighter and Faster YOLO) is used to detect defect of X-ray weld image. The related paper is avai

26 Dec 13, 2022
Code to use Augmented Shapiro Wilks Stopping, as well as code for the paper "Statistically Signifigant Stopping of Neural Network Training"

This codebase is being actively maintained, please create and issue if you have issues using it Basics All data files are included under losses and ea

J K Terry 32 Nov 09, 2021
Official implementation for ICDAR 2021 paper "Handwritten Mathematical Expression Recognition with Bidirectionally Trained Transformer"

Handwritten Mathematical Expression Recognition with Bidirectionally Trained Transformer Description Convert offline handwritten mathematical expressi

Wenqi Zhao 87 Dec 27, 2022
Real-time face detection and emotion/gender classification using fer2013/imdb datasets with a keras CNN model and openCV.

Real-time face detection and emotion/gender classification using fer2013/imdb datasets with a keras CNN model and openCV.

Octavio Arriaga 5.3k Dec 30, 2022
Code for WECHSEL: Effective initialization of subword embeddings for cross-lingual transfer of monolingual language models.

WECHSEL Code for WECHSEL: Effective initialization of subword embeddings for cross-lingual transfer of monolingual language models. arXiv: https://arx

Institute of Computational Perception 45 Dec 29, 2022
NOD: Taking a Closer Look at Detection under Extreme Low-Light Conditions with Night Object Detection Dataset

NOD (Night Object Detection) Dataset NOD: Taking a Closer Look at Detection under Extreme Low-Light Conditions with Night Object Detection Dataset, BM

Igor Morawski 17 Nov 05, 2022
CFNet: Cascade and Fused Cost Volume for Robust Stereo Matching(CVPR2021)

CFNet(CVPR 2021) This is the implementation of the paper CFNet: Cascade and Fused Cost Volume for Robust Stereo Matching, CVPR 2021, Zhelun Shen, Yuch

106 Dec 28, 2022
Text Summarization - WCN — Weighted Contextual N-gram method for evaluation of Text Summarization

Text Summarization WCN — Weighted Contextual N-gram method for evaluation of Text Summarization In this project, I fine tune T5 model on Extreme Summa

Aditya Shah 1 Jan 03, 2022
Simple and Robust Loss Design for Multi-Label Learning with Missing Labels

Simple and Robust Loss Design for Multi-Label Learning with Missing Labels Official PyTorch Implementation of the paper Simple and Robust Loss Design

Xinyu Huang 28 Oct 27, 2022
PyTorch implementation of the WarpedGANSpace: Finding non-linear RBF paths in GAN latent space (ICCV 2021)

Authors official PyTorch implementation of the "WarpedGANSpace: Finding non-linear RBF paths in GAN latent space" [ICCV 2021].

Christos Tzelepis 100 Dec 06, 2022
DI-smartcross - Decision Intelligence Platform for Traffic Crossing Signal Control

DI-smartcross DI-smartcross - Decision Intelligence Platform for Traffic Crossin

OpenDILab 213 Jan 02, 2023
3DMV jointly combines RGB color and geometric information to perform 3D semantic segmentation of RGB-D scans.

3DMV 3DMV jointly combines RGB color and geometric information to perform 3D semantic segmentation of RGB-D scans. This work is based on our ECCV'18 p

Владислав Молодцов 0 Feb 06, 2022
Making a music video with Wav2CLIP and VQGAN-CLIP

music2video Overview A repo for making a music video with Wav2CLIP and VQGAN-CLIP. The base code was derived from VQGAN-CLIP The CLIP embedding for au

Joel Jang | 장요엘 163 Dec 26, 2022
Official Implementation for HyperStyle: StyleGAN Inversion with HyperNetworks for Real Image Editing

HyperStyle: StyleGAN Inversion with HyperNetworks for Real Image Editing Yuval Alaluf*, Omer Tov*, Ron Mokady, Rinon Gal, Amit H. Bermano *Denotes equ

885 Jan 06, 2023
SenseNet is a sensorimotor and touch simulator for deep reinforcement learning research

SenseNet is a sensorimotor and touch simulator for deep reinforcement learning research

59 Feb 25, 2022
The official code repo of "HTS-AT: A Hierarchical Token-Semantic Audio Transformer for Sound Classification and Detection"

Hierarchical Token Semantic Audio Transformer Introduction The Code Repository for "HTS-AT: A Hierarchical Token-Semantic Audio Transformer for Sound

Knut(Ke) Chen 134 Jan 01, 2023
Full Transformer Framework for Robust Point Cloud Registration with Deep Information Interaction

Full Transformer Framework for Robust Point Cloud Registration with Deep Information Interaction. arxiv This repository contains python scripts for tr

12 Dec 12, 2022