Grouping: Which side of multiple records of the same subject

The same person, commodity, device or document can produce multiple highly relevant records.

Thematic shorts • IntroductionCollate in 2 self-measured2 First-hand sources
Start Body
Learning objectives and first steps2 objectives 2 first fixes

Try to do it after reading

  • Selecting group units according to the object of deployment
  • Distinguishing future projections of new and known subjects

Suggested first

  • Target function to oversee learning
  • Basic training and validation cycle

Randomly divide records, possibly without a user

The same person, commodity, device or document can produce multiple highly relevant records. If the training and validation were to include the same subject, the model might identify the main feature rather than learn to generalize to the new subject. The question of composition depends on the deployment target: predicting the next behaviour of the older user and predicting the new user is two distinct tasks.

Setup user A has two almost identical records, tags 1, and user B, tags zero. The training may have seen A and B after random row-by-line splits, and the verification is only to identify familiar subjects. By user grouping, the problem is significantly more difficult if only A is trained and only B is certified. This very small example is not used to estimate performance, but to demonstrate that the subject of the assessment has changed.

Tools such as GroupKFold ensure that the same group does not cross the respective training verification boundary, but do not select a group definition for you. Grouping by order does not eliminate cross orders leaks from the same user; Grouping by user does not eliminate the connection between the same family, the same institution or the duplicate content. The smallest independent unit associated with a possible memory path should be selected.

Grouping changes the sample distribution

Some large users have thousands of records, and grouping turns may result in an uneven ratio of records to categories. The number of groups, samples, positives and key attributes will need to be checked, rather than just looking at the same dashes. Grouping constraints and tiered constraints may not be perfectly met at the same time, and the actual distribution should be reported.

When serving both old and new subjects, it is possible to construct an assessment of older and older users on a separate basis, rather than mix it with a random score. The different slices correspond to different generalizations and the results should not be simply added; The overall weight also corresponds to the target population.

Pre-treatment must also comply with the boundary line. Group splitting begins with the calculation of target mean coding for all users, and the validation label is still brought into training. The group members correctly cover only one layer of agreements, and the characteristics generation, de-weighting and labelling maturity need to be examined separately.

This section uses the current scikit-learn group cross-checking concept, with four composite records for example, without training the classifier. There is no automatic separation method that represents all future use scenarios and the assessment report should make clear the “to whom and when” projection.

Is the order grouping equal to the user-segregated for each order?

Not equal. The same user may have multiple orders, which may still occur across both sides, and the main unit should be selected based on the deployment target.

Grouping to verify lower scores, does this explain the variation of the model?

Not necessarily. The possibility of assessing the problem has evolved from familiar subjects to new subjects, and the two scores should be interpreted in their own context and not be compared with the same agreement.

Sources and reconciliations

Definitions, methods and interfaces are available.

  1. scikit-learn — Cross-validation: evaluating estimator performance
  2. scikit-learn — GroupKFold

Figures and calculations are reorganized according to this chapter. Mathematical measurements, framework operations and real business effects are described separately in the body of the text.

← Back to the knowledge directory
Ask Max Ask about this site
Ask Max ↗

Opening the assistant…

Paper figure

Photo comments

LEAVE A NOTE

About this photograph

Connecting to the discussion board…

    Comments become public after moderation. You can delete your own comments from this browser.
    No email is required. Clearing cookies prevents this browser from claiming earlier comments.

    MAX WANG / INDEX

    Find something

    Enter a keyword, or explore the directory below.