Skip to content

OverflowError: n_iter too high in bpr.FMRecommender #147

@rhjohnstone

Description

@rhjohnstone

When I try to set a massive number of iterations, e.g.

fm = bpr.FMRecommender(n_iter=10000000000000, init_stdev=0.1, step_size=0.01, rank=10, random_state=123)
fm.fit(X, compares)

I get as an error (which occurs when the fit method is called):

OverflowError: value too large to convert to int

I also tried calling the fit method twice with n_iter=100 to see if I could train in batches, but found the output was the same after the first 100 as after the second 100, so I suppose fit also resets everything?

Is the maximum possible n_iter related to the size of the training data?

And is there any way to continue training the bpr.FMRecommender after n_iter iterations have been performed?

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