gsig / charades-algorithms

Activity Recognition Algorithms for the Charades Dataset
http://allenai.org/plato/charades/
201 stars 96 forks source link

Is the action score passed through softmax or not? #16

Closed leobxpan closed 5 years ago

leobxpan commented 5 years ago

Hi Gunnar,

Thanks for sharing the amazing codebase! I'm wondering under the classification evaluation mode (or localization), should the action score for each video / frame be the score after passed through softmax or before? From the example submission file it seems to be before (cuz there're negative values), but from the validate_video() function seems the after-softmax scores are added to the submission file.

Thanks in advance!

Boxiao

gsig commented 5 years ago

Hi Boxiao,

I think the final nonlinearity is now Sigmoid for most models, and since mAP just uses the ordering of the predictions, it actually doesn't matter. (The example submission file was created by a much older codebase, and using softmax where the normalization across the predictions actually mattered, especially when combining with flow later) I recently experimented with the different settings of applying sigmoid before or after the average pooling, and using average of either the log, or the final result, but I didn't see any significant difference.

Hope that helps!

leobxpan commented 5 years ago

Hi Gunnar,

Thanks for your reply! Before I actually experimented with these different settings I thought they would make a difference (since the ranking is done across multiple test examples, so although the ranking across different class scores within a single example won't change, the ranking across multiple examples within a single class might change. Please correct me if I'm wrong!), but the results showed that though the numbers are not exactly the same with values before / after softmax being passed in, they have very little difference (as you said, no any significant difference).

Thanks again for your help!