Home

Awesome

Disclaimer: This repo is not actively maintained and I do not plan to maintain it. If you need the dataset, please email me. Thank you for your understanding.

Protest Activity Detection and Perceived Violence Estimation from Social Media Images

Implementation of the model used in the paper Protest Activity Detection and Perceived Violence Estimation from Social Media Images (ACM Multimedia 2017) [arxiv] by Donghyeon Won, Zachary C. Steinert-Threlkeld, Jungseock Joo.

Requirements

Pytorch
NumPy
pandas
scikit-learn

Usage

Training

python train.py --data_dir UCLA-protest/ --batch_size 32 --lr 0.002 --print_freq 100 --epochs 100 --cuda

Evaluation

python pred.py --img_dir path/to/some/image/directory/ --output_csvpath result.csv --model model_best.pth.tar --cuda

UCLA Protest Image Dataset

You will need to download our UCLA Protest Image Dataset to train the model. Please e-mail me if you want to download our dataset!

Dataset Statistics

# of images: 40,764
# of protest images: 11,659

Protest & Visual Attributes
FieldsProtestSignPhotoFirePoliceChildrenGroup>20Group>100FlagNightShouting
# of Images11,6599,6694286677923478,5102,939970987548
Positive Rate0.2860.8290.0370.0570.0680.0300.7300.2520.0830.0850.047
Violence
MeanMedianSTD
0.3650.3520.144

Model

Architecture

We fine-tuned ImageNet pretrained ResNet50 to our data. You can download the model I trained from this Dropbox link.

Performance

<!-- |Fields |Protest|Sign |Photo|Fire |Law Enf.|Children|Group>20|Group>100|Flag |Night|Shout| |--------|-------|------|-----|-----|--------|--------|--------|---------|-----|-----|-----| |Accuracy|0.919 |0.890 |0.967|0.980|0.953 |0.970 |0.793 |0.803 |0.921|0.939|0.952| |ROC AUC |0.970 |0.922 |0.811|0.985|0.939 |0.827 |0.818 |0.839 |0.828|0.940|0.849| -->
ProtestSignPhoto
FirePoliceChildren
Group>20Group>100Flag
NightShoutingViolence