hello-jinwoo / LOVEU-CVPR2021

27 stars 3 forks source link

LOVEU-CVPR2021

This is the code for track 1 of competition LOVEU@CVPR2021.

We have two main models. One of them is main (using_similarity_map) using similarity map, and the other one is simple(sf_tsn_each_branch) using comparably simple networks.(transformer, RNN, and CNN)

We provide the simple way to implement(train, validate, test using ensemble) our code below :)

Setup

Here, we provide our basic setup.

Video Features

You may locate feature data in 'data' folder of this repository.

Materials

You can download materials here.

You may locate file_list_5fold.pkl in each model's folder, model files (.pt) in folder 'models' of each model folder, and prob_result files (.pkl) in folder 'prob_results' of ensemble folder.

Implementation

You can change some values in config.py in both models.

Train

For both models, you can train model just using below code.

python main.py

Validate

If you want to validate models using saved model, follow below.


Test with ensemble

We predict the result by ensembling models from different folds(0~4) and model architecture(main and simple).

We save a probability score for each model and use it to produce final prediction.

With the probability scores, you can predict the final event boundary following below code in ensemble folder.

python test.py --ver $VERSION_NAME_YOU_WANT

Then, there will be the test result in results folder.