Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add shuffling to examples in example features #136

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

johnvorsten
Copy link

Example_features are made of tensors of shape (batch_size, list_size,
feature_space). If examples are passed in a predictable order (ex.
ranked from most relevant to least relevant) the model might not generalize
well. Add 'shuffle_peritem':True to the Estimator's params to shuffle
example features and labels along list_size.

For example, when creating the estimator add the key:value pair 'shuffle_peritem':True

ranker = tf.estimator.Estimator(
    model_fn=model_fn,
    model_dir=_MODEL_DIR,
    config=run_config,
    params={'shuffle_peritem':True})

Example_features are made of tensors of shape (batch_size, list_size,
feature_space). If examples are passed in a predictable order (ex.
ranked from most relevant to least relevant) the model might not generalize
well. Add 'shuffle_peritem':True to the Estimator's params to shuffle
example features and labels along list_size.
@eggie5
Copy link
Contributor

eggie5 commented Feb 25, 2020

Do you see any difference in practice?

@johnvorsten
Copy link
Author

I did not see a difference in practice over my original dataset. However I’m not sure there was any relationship between my input features and my target ranking in the first place.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants