public class GLMModel extends hex.Model<GLMModel,GLMModel.GLMParameters,GLMModel.GLMOutput>
| Modifier and Type | Class and Description |
|---|---|
static class |
GLMModel.GLMOutput |
static class |
GLMModel.GLMParameters |
static class |
GLMModel.GLMWeights |
static class |
GLMModel.GLMWeightsFun |
static class |
GLMModel.RegularizationPath |
static class |
GLMModel.Submodel |
hex.Model.AdaptFrameParameters, hex.Model.BigScore, hex.Model.BigScoreChunkPredict, hex.Model.BigScorePredict, hex.Model.Contributions, hex.Model.DeepFeatures, hex.Model.ExemplarMembers, hex.Model.FeatureFrequencies, hex.Model.GetMostImportantFeatures, hex.Model.GetNTrees, hex.Model.GLRMArchetypes, hex.Model.GridSortBy, hex.Model.InteractionBuilder, hex.Model.InteractionPair, hex.Model.InteractionSpec, hex.Model.JavaModelStreamWriter, hex.Model.JavaScoringOptions, hex.Model.LeafNodeAssignment, hex.Model.Output, hex.Model.Parameters, hex.Model.PredictScoreResult, hex.Model.StagedPredictions, hex.Model.UpdateAuxTreeWeights| Modifier and Type | Field and Description |
|---|---|
double[] |
_betaCndCheckpoint |
static double |
_EPS |
double |
_lambda_max |
long |
_nobs |
long |
_nullDOF |
static double |
_OneOEPS |
static int |
_totalBetaLength |
double[] |
_ymu |
double |
_ySigma |
| Constructor and Description |
|---|
GLMModel(water.Key selfKey,
GLMModel.GLMParameters parms,
GLM job,
double[] ymu,
double ySigma,
double lambda_max,
long nobs) |
| Modifier and Type | Method and Description |
|---|---|
void |
addScoringInfo(GLMModel.GLMParameters parms,
int nclasses,
long currTime,
int iter) |
GLMModel |
addSubmodel(GLMModel.Submodel sm) |
protected double[] |
beta_internal() |
double[] |
beta_std(double lambda) |
double[] |
beta() |
double[] |
beta(double lambda) |
long |
checksum_impl() |
java.util.HashMap<java.lang.String,java.lang.Double> |
coefficients()
get beta coefficients in a map indexed by name
|
java.util.HashMap<java.lang.String,java.lang.Double> |
coefficients(boolean standardized) |
protected GLMModel |
deepClone(water.Key<GLMModel> result) |
double |
deviance(double w,
double y,
double f) |
DataInfo |
dinfo() |
water.util.TwoDimTable |
generateSummary(water.Key train,
int iter)
Re-do the TwoDim table generation with updated model.
|
water.util.TwoDimTable |
generateSummaryHGLM(water.Key train,
int iter)
This one is for HGLM
|
GLMMojoWriter |
getMojo() |
GLMModel.RegularizationPath |
getRegularizationPath() |
hex.ScoringInfo[] |
getScoringInfo() |
boolean |
haveMojo() |
boolean |
havePojo() |
void |
initActualParamValues() |
protected boolean |
isFeatureUsedInPredict(int featureIdx) |
double |
likelihood(double w,
double y,
double f) |
hex.ModelMetrics.MetricBuilder |
makeMetricBuilder(java.lang.String[] domain) |
java.lang.String[] |
makeScoringNames() |
java.lang.String[] |
names() |
protected boolean |
needsPostProcess() |
protected hex.Model.PredictScoreResult |
predictScoreImpl(water.fvec.Frame fr,
water.fvec.Frame adaptFrm,
java.lang.String destination_key,
water.Job j,
boolean computeMetrics,
water.udf.CFuncRef customMetricFunc)
Score an already adapted frame.
|
protected double[] |
score0(double[] data,
double[] preds) |
protected double[] |
score0(double[] data,
double[] preds,
double o) |
hex.ScoreKeeper[] |
scoreKeepers() |
protected hex.ModelMetrics.MetricBuilder |
scoreMetrics(water.fvec.Frame adaptFrm)
Score an already adapted frame.
|
protected java.lang.String[][] |
scoringDomains() |
void |
setVcov(double[][] inv) |
void |
setZValues(double[] zValues,
double dispersion,
boolean dispersionEstimated) |
protected boolean |
toJavaCheckTooBig() |
protected water.util.SBPrintStream |
toJavaInit(water.util.SBPrintStream sb,
water.codegen.CodeGeneratorPipeline fileCtx) |
protected void |
toJavaPredictBody(water.util.SBPrintStream body,
water.codegen.CodeGeneratorPipeline classCtx,
water.codegen.CodeGeneratorPipeline fileCtx,
boolean verboseCode) |
void |
update(double[] beta,
double[] ubeta,
double devianceTrain,
double devianceTest,
int iter) |
void |
update(double[] beta,
double devianceTrain,
double devianceTest,
int iter) |
GLMModel |
updateSubmodel(GLMModel.Submodel sm) |
adaptFrameForScore, adaptTestForTrain, adaptTestForTrain, adaptTestForTrain, addMetrics, addModelMetrics, addWarning, auc, AUCPR, classification_error, compareTo, computeDeviances, containsResponse, data, defaultThreshold, defaultThreshold, deleteCrossValidationFoldAssignment, deleteCrossValidationModels, deleteCrossValidationPreds, deviance, evaluateAutoModelParameters, exportBinaryModel, exportMojo, fetchAll, fillScoringInfo, getDefaultGridSortBy, getGenModelEncoding, getPojoInterfaces, getToEigenVec, importBinaryModel, isDistributionHuber, isFeatureUsedInPredict, isSupervised, last_scored, lift_top_group, logloss, loss, mae, makeAdaptFrameParameters, makeBigScoreTask, makeInteraction, makeInteractions, makeInteractions, makePojoWriter, makeSchema, makeScoringDomains, makeScoringNames, mean_per_class_error, modelDescriptor, mse, postProcessPredictions, r2, readAll_impl, remove_impl, resetThreshold, result, rmsle, score, score, score, score, score, score, score, score0, score0, score0PostProcessSupervised, scoring_history, setInputParms, setupBigScorePredict, testJavaScoring, testJavaScoring, testJavaScoring, testJavaScoring, testJavaScoring, toJava, toJava, toJava, toJavaAlgo, toJavaModelClassName, toJavaTransform, toJavaUUID, toMojo, toString, uploadBinaryModel, writeAll_impl, writeTodelete_and_lock, delete_and_lock, delete_and_lock, delete, delete, delete, delete, read_lock, read_lock, read_lock, unlock_all, unlock, unlock, unlock, unlock, update, update, update, write_lock_to_read_lock, write_lock, write_lock, write_lockchecksum_impl, checksum, checksum, getKey, readAll, remove_impl, remove_self_key_impl, remove, remove, remove, remove, remove, remove, removeQuietly, writeAllpublic static final double _EPS
public static final double _OneOEPS
public static int _totalBetaLength
public final double _lambda_max
public final double[] _ymu
public final long _nullDOF
public final double _ySigma
public final long _nobs
public double[] _betaCndCheckpoint
public GLMModel(water.Key selfKey,
GLMModel.GLMParameters parms,
GLM job,
double[] ymu,
double ySigma,
double lambda_max,
long nobs)
public void initActualParamValues()
initActualParamValues in class hex.Model<GLMModel,GLMModel.GLMParameters,GLMModel.GLMOutput>public hex.ScoreKeeper[] scoreKeepers()
public hex.ScoringInfo[] getScoringInfo()
public void addScoringInfo(GLMModel.GLMParameters parms, int nclasses, long currTime, int iter)
public void setVcov(double[][] inv)
public GLMModel.RegularizationPath getRegularizationPath()
protected boolean toJavaCheckTooBig()
toJavaCheckTooBig in class hex.Model<GLMModel,GLMModel.GLMParameters,GLMModel.GLMOutput>public DataInfo dinfo()
public hex.ModelMetrics.MetricBuilder makeMetricBuilder(java.lang.String[] domain)
makeMetricBuilder in class hex.Model<GLMModel,GLMModel.GLMParameters,GLMModel.GLMOutput>protected double[] beta_internal()
public double[] beta()
public double[] beta(double lambda)
public double[] beta_std(double lambda)
public java.lang.String[] names()
public double deviance(double w,
double y,
double f)
deviance in class hex.Model<GLMModel,GLMModel.GLMParameters,GLMModel.GLMOutput>public double likelihood(double w,
double y,
double f)
likelihood in class hex.Model<GLMModel,GLMModel.GLMParameters,GLMModel.GLMOutput>public GLMModel addSubmodel(GLMModel.Submodel sm)
public GLMModel updateSubmodel(GLMModel.Submodel sm)
public void update(double[] beta,
double devianceTrain,
double devianceTest,
int iter)
public void update(double[] beta,
double[] ubeta,
double devianceTrain,
double devianceTest,
int iter)
protected java.lang.String[][] scoringDomains()
scoringDomains in class hex.Model<GLMModel,GLMModel.GLMParameters,GLMModel.GLMOutput>public void setZValues(double[] zValues,
double dispersion,
boolean dispersionEstimated)
public java.util.HashMap<java.lang.String,java.lang.Double> coefficients()
public java.util.HashMap<java.lang.String,java.lang.Double> coefficients(boolean standardized)
public water.util.TwoDimTable generateSummary(water.Key train,
int iter)
public water.util.TwoDimTable generateSummaryHGLM(water.Key train,
int iter)
train - iter - public long checksum_impl()
checksum_impl in class hex.Model<GLMModel,GLMModel.GLMParameters,GLMModel.GLMOutput>protected double[] score0(double[] data,
double[] preds)
score0 in class hex.Model<GLMModel,GLMModel.GLMParameters,GLMModel.GLMOutput>protected double[] score0(double[] data,
double[] preds,
double o)
score0 in class hex.Model<GLMModel,GLMModel.GLMParameters,GLMModel.GLMOutput>protected boolean needsPostProcess()
needsPostProcess in class hex.Model<GLMModel,GLMModel.GLMParameters,GLMModel.GLMOutput>protected void toJavaPredictBody(water.util.SBPrintStream body,
water.codegen.CodeGeneratorPipeline classCtx,
water.codegen.CodeGeneratorPipeline fileCtx,
boolean verboseCode)
toJavaPredictBody in class hex.Model<GLMModel,GLMModel.GLMParameters,GLMModel.GLMOutput>protected water.util.SBPrintStream toJavaInit(water.util.SBPrintStream sb,
water.codegen.CodeGeneratorPipeline fileCtx)
toJavaInit in class hex.Model<GLMModel,GLMModel.GLMParameters,GLMModel.GLMOutput>protected hex.Model.PredictScoreResult predictScoreImpl(water.fvec.Frame fr,
water.fvec.Frame adaptFrm,
java.lang.String destination_key,
water.Job j,
boolean computeMetrics,
water.udf.CFuncRef customMetricFunc)
predictScoreImpl in class hex.Model<GLMModel,GLMModel.GLMParameters,GLMModel.GLMOutput>adaptFrm - Already adapted framecomputeMetrics - public java.lang.String[] makeScoringNames()
makeScoringNames in class hex.Model<GLMModel,GLMModel.GLMParameters,GLMModel.GLMOutput>protected hex.ModelMetrics.MetricBuilder scoreMetrics(water.fvec.Frame adaptFrm)
scoreMetrics in class hex.Model<GLMModel,GLMModel.GLMParameters,GLMModel.GLMOutput>adaptFrm - Already adapted framepublic boolean haveMojo()
haveMojo in class hex.Model<GLMModel,GLMModel.GLMParameters,GLMModel.GLMOutput>public boolean havePojo()
havePojo in class hex.Model<GLMModel,GLMModel.GLMParameters,GLMModel.GLMOutput>public GLMMojoWriter getMojo()
getMojo in class hex.Model<GLMModel,GLMModel.GLMParameters,GLMModel.GLMOutput>protected boolean isFeatureUsedInPredict(int featureIdx)
isFeatureUsedInPredict in class hex.Model<GLMModel,GLMModel.GLMParameters,GLMModel.GLMOutput>