mmlspark.automl package

Submodules

mmlspark.automl.FindBestModel module

class mmlspark.automl.FindBestModel.BestModel(java_model=None)[source]

Bases: mmlspark.automl._FindBestModel._BestModel

getAllModelMetrics()[source]

Returns a table of metrics from all models compared from the evaluation comparison.

getBestModel()[source]

Returns the best model.

getBestModelMetrics()[source]

Returns all of the best model metrics results from the evaluator.

getEvaluationResults()[source]

Returns the ROC curve with TPR, FPR.

getScoredDataset()[source]

Returns scored dataset for the best model.

class mmlspark.automl.FindBestModel.FindBestModel(evaluationMetric='accuracy', models=None)[source]

Bases: mmlspark.automl._FindBestModel._FindBestModel

mmlspark.automl.HyperparamBuilder module

class mmlspark.automl.HyperparamBuilder.DiscreteHyperParam(values, seed=0)[source]

Bases: object

Specifies a discrete list of values.

get()[source]
class mmlspark.automl.HyperparamBuilder.GridSpace(paramValues)[source]

Bases: object

Specifies a predetermined grid of values to search through.

space()[source]
class mmlspark.automl.HyperparamBuilder.HyperparamBuilder[source]

Bases: object

Specifies the search space for hyperparameters.

addHyperparam(est, param, hyperParam)[source]

Add a hyperparam to the builder

Parameters
  • param (Param) – The param to tune

  • dist (Dist) – Distribution of values

build()[source]

Builds the search space of hyperparameters, returns the map of hyperparameters to search through.

class mmlspark.automl.HyperparamBuilder.RandomSpace(paramDistributions)[source]

Bases: object

Specifies a random streaming range of values to search through.

space()[source]
class mmlspark.automl.HyperparamBuilder.RangeHyperParam(min, max, seed=0)[source]

Bases: object

Specifies a range of values.

get()[source]

mmlspark.automl.TuneHyperparameters module

class mmlspark.automl.TuneHyperparameters.TuneHyperparameters(evaluationMetric=None, models=None, numFolds=None, numRuns=None, parallelism=None, paramSpace=None, seed=0)[source]

Bases: mmlspark.automl._TuneHyperparameters._TuneHyperparameters

class mmlspark.automl.TuneHyperparameters.TuneHyperparametersModel(java_model=None)[source]

Bases: mmlspark.automl._TuneHyperparameters._TuneHyperparametersModel

getBestModel()[source]

Returns the best model.

getBestModelInfo()[source]

Returns the best model parameter info.

Module contents

MicrosoftML is a library of Python classes to interface with the Microsoft scala APIs to utilize Apache Spark to create distibuted machine learning models.

MicrosoftML simplifies training and scoring classifiers and regressors, as well as facilitating the creation of models using the CNTK library, images, and text.