Buggy code:
public final double mloss ( double [ ] u , int a ) { } public static double mloss ( double [ ] u , int a , GLRMModel . GLRMParameters . Loss multi_loss ) { } public final double [ ] mlgrad ( double [ ] u , int a ) { } public static double [ ] mlgrad ( double [ ] u , int a , GLRMModel . GLRMParameters . Loss multi_loss ) { } public final double regularize_x ( double [ ] u ) { } public final double regularize_y ( double [ ] u ) { } public final double regularize ( double [ ] u , GLRMModel . GLRMParameters . Regularizer regularization ) { } public final double regularize_x ( double [ ] [ ] u ) { } public final double regularize_y ( double [ ] [ ] u ) { } public final double regularize ( double [ ] [ ] u , GLRMModel . GLRMParameters . Regularizer regularization ) { } public final double [ ] rproxgrad_x ( double [ ] u , double alpha , Random rand ) { } public final double [ ] rproxgrad_y ( double [ ] u , double alpha , Random rand ) { } static double [ ] rproxgrad ( double [ ] u , double alpha , double gamma , GLRMModel . GLRMParameters . Regularizer regularization , Random rand ) { } public final double [ ] project_x ( double [ ] u , Random rand ) { } public final double [ ] project_y ( double [ ] u , Random rand ) { } public final double [ ] project ( double [ ] u , GLRMModel . GLRMParameters . Regularizer regularization , Random rand ) { } public final double impute ( double u ) { } public static double impute ( double u , GLRMModel . GLRMParameters . Loss loss ) { } public final int mimpute ( double [ ] u ) { } public static int mimpute ( double [ ] u , GLRMModel . GLRMParameters . Loss multi_loss ) { } } public static class GLRMOutput extends Model . Output { public int _iterations ; public double _objective ; public double _avg_change_obj ; public double [ ] _history_avg_change_obj = new double [ 0 ] ; public TwoDimTable _archetypes ; public Archetypes _archetypes_raw ; public double [ ] _history_step_size = new double [ 0 ] ; public double [ ] [ ] _eigenvectors_raw ; public TwoDimTable _eigenvectors ; public double [ ] _singular_vals ; public Key < Frame > _loading_key ; public int _ncats ; public int _nnums ; public long _nobs ; public int [ ] _catOffsets ; public double [ ] _normSub ; public double [ ] _normMul ; public int [ ] _permutation ; public String [ ] _names_expanded ; public GLRMModel . GLRMParameters . Loss [ ] _lossFunc ; public long [ ] _training_time_ms = new long [ 0 ] ; public GLRMOutput ( GLRM b ) { } @ Override public int nfeatures ( ) { } @ Override public ModelCategory getModelCategory ( ) { } } public GLRMModel ( Key selfKey , GLRMModel . GLRMParameters parms , GLRMModel . GLRMOutput output ) { } @ Override protected Frame predictScoreImpl ( Frame orig , Frame adaptedFr , String destination_key ) { final int ncols = _names . length ; assert ncols == ( adaptedFr . numCols ( ) ) ; String prefix = "reconstr_" ; Frame fullFrm = new Frame ( adaptedFr ) ; Frame loadingFrm = DKV . get ( _loading_key ) . get ( ) ; fullFrm . add ( loadingFrm ) ; String [ ] [ ] adaptedDomme = adaptedFr . domains ( ) ; for ( int i = 0 ; i < ncols ; i ++ ) { Vec v = fullFrm . anyVec ( ) . makeZero ( ) ; v . setDomain ( adaptedDomme [ i ] ) ; fullFrm . add ( ( prefix + ( _output . _names [ i ] ) ) , v ) ; } GLRMModel . GLRMScore gs = new GLRMModel . GLRMScore ( ncols , _parms . _k , true ) . doAll ( fullFrm ) ; int x = ncols + ( _parms . _k ) ; int y = fullFrm . numCols ( ) ; Frame f = fullFrm . extractFrame ( x , y ) ; f = new Frame ( ( null == destination_key ? Key . make ( ) : Key . make ( destination_key ) ) , f . names ( ) , f . vecs ( ) ) ; DKV . put ( f ) ; <START_BUG> gs . _mb . makeModelMetrics ( this , adaptedFr ) ; <END_BUG> return f ; } private class GLRMScore extends MRTask < GLRMModel . GLRMScore > { final int _ncolA ; final int _ncolX ; final boolean _save_imputed ; MetricBuilder _mb ; GLRMScore ( int ncolA , int ncolX , boolean save_imputed ) { } @ Override public void map ( Chunk [ ] chks ) { } @ Override public void reduce ( GLRMModel . GLRMScore other ) { } @ Override protected void postGlobal ( ) { } private float [ ] compute_metrics ( Chunk [ ] chks , int row_in_chunk , float [ ] tmp , double [ ] preds ) { } private double [ ] impute_data ( Chunk [ ] chks , int row_in_chunk , double [ ] tmp , double [ ] preds ) { } private double [ ] impute_data ( double [ ] tmp , double [ ] preds ) { } } @ Override protected double [ ] score0 ( double [ ] data , double [ ] preds ) { } public ModelMetricsGLRM scoreMetricsOnly ( Frame frame ) { } @ Override public MetricBuilder makeMetricBuilder ( String [ ] domain ) { } }

Fix:
gs . _mb . makeModelMetrics ( this , orig ) ;