Class TimeSeriesBase
- java.lang.Object
-
- com.datarobot.prediction.internal.TimeSeriesBase
-
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
TimeSeriesRegressionPredictorImpl
public class TimeSeriesBase extends Object
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected StringdateColumnNameprotected StringdateFormatprotected Map.Entry<Integer,Integer>fdwprotected LinkedHashMap<String,Class>featuresprotected Map<String,Integer>featuresIndexesprotected Map.Entry<Integer,Integer>fwprotected StringmodelIdprotected Map<String,String>modelInfoprotected intnumDoublesprotected intnumStringsprotected ConcurrentHashMap<String,String>sanitizedFeaturesCacheprotected com.datarobot.prediction.internal.PredictorBase.GenericEvent<ScoreEventT>scoreEventprotected StringseriesIdColumnNameprotected StringtargetNameprotected Map.Entry<Integer,String>timeStep
-
Constructor Summary
Constructors Modifier Constructor Description protectedTimeSeriesBase(TimeSeriesPredictor predictor)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected RowextractFeatures(Iterable<?> row)protected RowextractFeatures(Map<String,?> row)Extracts features that are needed from initial row.protected Map<String,?>extractFeaturesMap(Iterable<?> row)protected ArrayList<Row>extractRows(ArrayList<Map<String,?>> inputs)protected StringgetDefaultEmptyColumnName()Return label for empty column.protected ExplanationParamsgetDefaultParams()protected Set<String>getDoubleMissingValuesLabels()Returns the set of null labels.protected DoublegetDoubleValue(String featureName, Object value)Replaces double missing value with NaN.protected FieldgetField(Class<?> clazz, String fieldName)protected MethodgetPredictorMethod(String methodName, Class<?>... signature)protected Map<String,String>initializeModelInfo(PredictorT predictor)protected Stringsanitize(String name)Some pre-processing for feature name.protected voidsendScoreInfo(ScoreEventT eventInfo)
-
-
-
Field Detail
-
dateColumnName
protected final String dateColumnName
-
seriesIdColumnName
protected final String seriesIdColumnName
-
dateFormat
protected final String dateFormat
-
numDoubles
protected int numDoubles
-
numStrings
protected int numStrings
-
features
protected LinkedHashMap<String,Class> features
-
sanitizedFeaturesCache
protected ConcurrentHashMap<String,String> sanitizedFeaturesCache
-
modelId
protected String modelId
-
targetName
protected String targetName
-
scoreEvent
protected final com.datarobot.prediction.internal.PredictorBase.GenericEvent<ScoreEventT extends EventInfo> scoreEvent
-
-
Constructor Detail
-
TimeSeriesBase
protected TimeSeriesBase(TimeSeriesPredictor predictor)
-
-
Method Detail
-
extractFeatures
protected Row extractFeatures(Map<String,?> row)
Extracts features that are needed from initial row.- Parameters:
row- - Map of initial feature name to its value.- Returns:
- - internal type for scoring.
-
sanitize
protected String sanitize(String name)
Some pre-processing for feature name.- Parameters:
name- - original feature name.- Returns:
- - sanitized name.
-
getDoubleValue
protected Double getDoubleValue(String featureName, Object value)
Replaces double missing value with NaN.- Parameters:
featureName- - name of the feature.value- - object feature value.- Returns:
- - parsed Double value.
-
getDefaultEmptyColumnName
protected String getDefaultEmptyColumnName()
Return label for empty column.- Returns:
- - empty column name.
-
getDoubleMissingValuesLabels
protected Set<String> getDoubleMissingValuesLabels()
Returns the set of null labels.- Returns:
- - set of null labels.
-
sendScoreInfo
protected void sendScoreInfo(ScoreEventT eventInfo)
-
getDefaultParams
protected ExplanationParams getDefaultParams()
-
-