ReedyHarbour/10707-nocaps

Python

0

19 commits

updated Apr 30, 2022

See the code

README

Discriminative Methods using Language Modeling

Code Structure

Modifies from updown-baseline, by adding files

Preparation

Download data from nocaps.org, modify the paths in baseline/configs/updown_nocaps_val.yaml. To get data for fluency classifier, run

 python classifier/prepare_captions.py

Install required packages in baseline/requirements.txt

Training

Run the following code to run the correlation classifier

 python classifier/train_sim.py
--config configs/updown_nocaps_val.yaml --output_dir checkpoints/sim

Run the following code to run the fluency classifier

python classifier/train_natural.py
--config configs/updown_nocaps_val.yaml --output_dir checkpoints/nat

Prediction

Run python predict_sim.py with corresponding functions to get output csv files

Reference

Huggingface Transformers Library

ReedyHarbour/10707-nocaps

Python

0

19 commits

updated Apr 30, 2022

See the code

README

Discriminative Methods using Language Modeling

Code Structure

Modifies from updown-baseline, by adding files

Preparation

Download data from nocaps.org, modify the paths in baseline/configs/updown_nocaps_val.yaml. To get data for fluency classifier, run

 python classifier/prepare_captions.py

Install required packages in baseline/requirements.txt

Training

Run the following code to run the correlation classifier

 python classifier/train_sim.py
--config configs/updown_nocaps_val.yaml --output_dir checkpoints/sim

Run the following code to run the fluency classifier

python classifier/train_natural.py
--config configs/updown_nocaps_val.yaml --output_dir checkpoints/nat

Prediction

Run python predict_sim.py with corresponding functions to get output csv files

Reference

Huggingface Transformers Library