linkedin / linkedin/photon-ml

featureShardConfigurations when scoring a mixed effects model with random intercept only

Open
#478 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Terra
Stars
795
Forks
175
PR merge metrics
No merged PRs in 30d

Description

In my first attempt using Photon-ML, I have trained a mixed effects model that includes an intercept-only random effect. I then try to use the scoring driver, using the tutorial as a template.

I'm having trouble specifying the right feature shard for the random intercept. During training, I assign no feature bags to the feature shard (by omitting it in the cli command). In the scoring part, what's the right thing to do?

Thanks in advance!

val globalFeatureShardId = "sGlobal"
val globalFeatureShard = Set("Bu", "Bg", "Bc")

val perUserFeatureShardId = "sUser"
val perUserFeatureShard = Set("uuid")
// only looking for random intercept and therefore the shard is empty, what do I enter here?
// should i put the userid (uuid) in a bag by itself and use it here?

val fixedShardConfigs = Map(globalFeatureShardId -> FeatureShardConfiguration(globalFeatureShard, true))
val mixedShardConfigs = Map(perUserFeatureShardId -> FeatureShardConfiguration(perUserFeatureShard, true)) ++ fixedShardConfigs

GameScoringDriver.set(GameScoringDriver.featureShardConfigurations, mixedShardConfigs)

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the tutorial and the GameScoringDriver.featureShardConfigurations entry point, then trace how FeatureShardConfiguration represents an empty random-intercept shard and compare it with the training CLI behavior described here. Done means confirming the correct scoring configuration for an intercept-only random effect, including whether the user ID belongs in a feature bag.

Written by the indexing model from the issue text.

Assessment

Tech stack
scala, spark
Domain
machine-learning
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.