diff --git a/pyannote/audio/core/model.py b/pyannote/audio/core/model.py index 5cb6c0e6b..bedb7f6c4 100644 --- a/pyannote/audio/core/model.py +++ b/pyannote/audio/core/model.py @@ -198,12 +198,13 @@ def __example_output( example_output: torch.Tensor, specifications: Specifications = None, ) -> Output: - _, num_frames, dimension = example_output.shape - if specifications.resolution == Resolution.FRAME: + _, num_frames, dimension = example_output.shape frame_duration = specifications.duration / num_frames frames = SlidingWindow(step=frame_duration, duration=frame_duration) else: + _, dimension = example_output.shape + num_frames = None frames = None return Output(