
Class-specific attention learning with MIL: In general scheme of MIL (multi-instance learning), training instances are arranged in sets, called bags, and a label is provided for the entire bag [1]}. In the context of weakly-supervised temporal action detection, each video is treated as a bag of action instances and the video-level action labels are provided. In order to compute the loss for each bag (video in this task), each video should be represented using a single confidence score per category. The confidence score for each category is computed as the average of top \(k\)  activation scores over the temporal dimension for that category. In a given video, suppose set \(\lbrace t^c_1,t^c_2,\cdots ,t^c_k\rbrace \)  are \(k\)  temporal positions with highest activation scores for class \(c\) . Then, the video-level class-wise confidence score \(s^c\)  for class \(c\)  is defined as:
\(s^c = \frac{1}{k} \sum _{l=1}^{k} A[c,t^c_l],\) 
