Skip to content

Commit

Permalink
Merge pull request #160 from YaoZh1918/master
Browse files Browse the repository at this point in the history
fix bug in cross_validate

ret['train_' + m] was returning testset values
  • Loading branch information
NicolasHug committed Mar 30, 2018
2 parents 58f3508 + ff03506 commit 56e534a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion surprise/model_selection/validation.py
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ def cross_validate(algo, data, measures=['rmse', 'mae'], cv=None,
if return_train_measures:
train_measures[m] = np.asarray([d[m] for d in
train_measures_dicts])
ret['train_' + m] = test_measures[m]
ret['train_' + m] = train_measures[m]

ret['fit_time'] = fit_times
ret['test_time'] = test_times
Expand Down

0 comments on commit 56e534a

Please sign in to comment.