Skip to content

IndexError in self.correct branch of DBNDownBeatTrackingProcessor process function. #488

@omareldeeb

Description

@omareldeeb

Expected behaviour

If no valid path could be decoded using the Viterbi algorithm, an empty array should be returned.

Actual behaviour

If self.correct == True, an IndexError is thrown in line 301 of downbeats.py, due to beat_range being empty.

Steps needed to reproduce the behaviour

import madmom
import numpy as np
import scipy

beat_tracker = madmom.features.downbeats.DBNDownBeatTrackingProcessor(fps=100.0, correct=True, beats_per_bar=4)
beat_activation = np.random.uniform(0, 1, 100)
downbeat_activation = np.random.uniform(0, 1, 100)

beat_decoder.process(np.dstack((beat_activation, downbeat_activation))[0])

Information about installed software

Please provide some information about installed software.

madmom.version == '0.16.1'
np.version == '1.19.5'
scipy.version == '1.7.2'

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions