Add transcription functionality to ASR Classification models
For transcription, duration is a dummy value that's not precalculated. It would cost too much compute to precompute the durations of all the samples simply for logging. Hmm thinking about the vad case, it doesn't work with this dataloader at all. So feel free to push changes to this branch (or an addendum PR to this one) to add vad transcription. 

I think it would be cleaner to have a `transcribe_vad` or equivalent and properly accept or precompute durations for such batched segment inference as in vad case Hmm VAD is another case and we have a vad_infer and we have vad_frame_seq_collate_fn to handle this. > For transcription, duration is a dummy value that's not precalculated. It would cost too much compute to precompute the durations of all the samples simply for logging.

emm I didn’t mean precompute the durations of all the files for logging. Just wondering If we have a 5 sec audio, then what if we want my inference window to be 1.28s or 1.0s? This PR performs offline inference only - and is meant to consume the entire audio sequence and emit one label per sample only. That's why we should have a seperate method to perform segmented (aka infer every T seconds) that is not part of this PR. 

The .transcribe() method comes from the parent ASRModel and as such needs to have similar semantics - offline full scale transcription / classification over an entire sample at once go.  > The .transcribe() method comes from the parent ASRModel and as such needs to have similar semantics - offline full scale transcription / classification over an entire sample at once go.

Got it. Thanks for the explanation!  I thought it gonna perform streaming/average window inference so I was wondering did I miss anything from dataloader for it.  Yes, let's add another method (let's think of a good name, maybe transcribe_streaming or transcribe_segments or something like that) to perform actual stream classification over limited time segment. It's useful to have a method to do it rather than rely on notebook all the time.  > Yes, let's add another method (let's think of a good name, maybe transcribe_streaming or transcribe_segments or something like that) to perform actual stream classification over limited time segment. It's useful to have a method to do it rather than rely on notebook all the time.

Yes good idea! We have sliced/vad_frame_seq_collate_fn now. It's gonna be awesome to have unified **streaming transcribe** function for classification models, label models, and etc. So we can have more functionality coming in online/offline such as smoothing the inference results by using average window.
# Changelog
- Refactor TopKClassification accuracy to make `top_k` a property + perform top_k operation seperately
- Add tests for transcription scenarios

Signed-off-by: smajumdar <titu1994@gmail.com>