Skip to content

TLD bug in unstable #267

Description

@abagnall-riverside

Hi,

I was trying to use the predator implementation in ccv_tld.c (unstable), and encountered the following assertion failure:

ccv_tld.c:485: float _ccv_tld_sv_classify(ccv_tld_t *, ccv_dense_matrix_t *, int, int, int *, int *): Assertion `a->rows == tld->patch.height && a->cols == tld->patch.width' failed.

I think the problem is in this call to ccv_resample. It looks like the rows and cols parameters of ccv_resample have been changed at some point to rows_scale and cols_scale, but the corresponding change hasn't been applied at this call site.

I fixed it locally (or so I think) by changing

ccv_resample(c, b, type, tld->patch.height, tld->patch.width, CCV_INTER_AREA | CCV_INTER_CUBIC);

to

ccv_resample(c, b, type, tld->patch.height / (double)c->rows, tld->patch.width / (double)c->cols, CCV_INTER_AREA | CCV_INTER_CUBIC);

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions