Cli Ml
- class dffml.cli.ml.Accuracy(*args, **kwargs)[source]
Assess model accuracy on data from given sources
- CONFIG
alias of
dffml.cli.ml.AccuracyCMDConfig
- class dffml.cli.ml.AccuracyCMDConfig(model: dffml.model.model.Model, scorer: dffml.accuracy.accuracy.AccuracyScorer, features: dffml.feature.feature.Features = [], sources: dffml.source.source.Sources = <factory>)[source]
- no_enforce_immutable()
By default, all properties of a config object are immutable. If you would like to mutate immutable properties, you must explicitly call this method using it as a context manager.
Examples
>>> from dffml import config >>> >>> @config ... class MyConfig: ... C: int >>> >>> config = MyConfig(C=2) >>> with config.no_enforce_immutable(): ... config.C = 1
- class dffml.cli.ml.MLCMD(*args, **kwargs)[source]
Commands which use models share many similar arguments.
- class dffml.cli.ml.MLCMDConfig(model: dffml.model.model.Model, sources: dffml.source.source.Sources = <factory>)[source]
- no_enforce_immutable()
By default, all properties of a config object are immutable. If you would like to mutate immutable properties, you must explicitly call this method using it as a context manager.
Examples
>>> from dffml import config >>> >>> @config ... class MyConfig: ... C: int >>> >>> config = MyConfig(C=2) >>> with config.no_enforce_immutable(): ... config.C = 1
- class dffml.cli.ml.Predict(extra_config=None, **kwargs)[source]
Evaluate features against records and produce a prediction
- record
alias of
dffml.cli.ml.PredictRecord
- class dffml.cli.ml.PredictAll(*args, **kwargs)[source]
Predicts for all sources
- CONFIG
alias of
dffml.cli.ml.PredictAllConfig
- class dffml.cli.ml.PredictAllConfig(model: dffml.model.model.Model, sources: dffml.source.source.Sources = <factory>, update: bool = False, pretty: bool = False)[source]
- no_enforce_immutable()
By default, all properties of a config object are immutable. If you would like to mutate immutable properties, you must explicitly call this method using it as a context manager.
Examples
>>> from dffml import config >>> >>> @config ... class MyConfig: ... C: int >>> >>> config = MyConfig(C=2) >>> with config.no_enforce_immutable(): ... config.C = 1
- class dffml.cli.ml.PredictRecord(*args, **kwargs)[source]
Predictions for individual records
- CONFIG
alias of
dffml.cli.ml.PredictRecordConfig
- class dffml.cli.ml.PredictRecordConfig(keys: List[str], model: dffml.model.model.Model, sources: dffml.source.source.Sources = <factory>, update: bool = False, pretty: bool = False)[source]
- no_enforce_immutable()
By default, all properties of a config object are immutable. If you would like to mutate immutable properties, you must explicitly call this method using it as a context manager.
Examples
>>> from dffml import config >>> >>> @config ... class MyConfig: ... C: int >>> >>> config = MyConfig(C=2) >>> with config.no_enforce_immutable(): ... config.C = 1
- class dffml.cli.ml.Train(*args, **kwargs)[source]
Train a model on data from given sources
- CONFIG
alias of
dffml.cli.ml.MLCMDConfig