class sklearn.neural_network.MLPClassifier(hidden_layer_sizes=(100, ), activation=’relu’, solver=’adam’, alpha=0.0001, batch_size=’auto’, learning_rate=’constant’, learning_rate_init=0.001, power_t=0.5, max_iter=200, shuffle=True, random_state=None, tol=0.0001, verbose=False, warm_start=False, momentum=0.9, nesterovs_momentum=True, early_stopping=False, validation_fraction=0.1, beta_1=0.9, beta_2=0.999, epsilon=1e08, n_iter_no_change=10)
[source]
Multilayer Perceptron classifier.
This model optimizes the logloss function using LBFGS or stochastic gradient descent.
New in version 0.18.
Parameters: 


Attributes: 

MLPClassifier trains iteratively since at each time step the partial derivatives of the loss function with respect to the model parameters are computed to update the parameters.
It can also have a regularization term added to the loss function that shrinks model parameters to prevent overfitting.
This implementation works with data represented as dense numpy arrays or sparse scipy arrays of floating point values.
fit (X, y)  Fit the model to data matrix X and target(s) y. 
get_params ([deep])  Get parameters for this estimator. 
predict (X)  Predict using the multilayer perceptron classifier 
predict_log_proba (X)  Return the log of probability estimates. 
predict_proba (X)  Probability estimates. 
score (X, y[, sample_weight])  Returns the mean accuracy on the given test data and labels. 
set_params (**params)  Set the parameters of this estimator. 
__init__(hidden_layer_sizes=(100, ), activation=’relu’, solver=’adam’, alpha=0.0001, batch_size=’auto’, learning_rate=’constant’, learning_rate_init=0.001, power_t=0.5, max_iter=200, shuffle=True, random_state=None, tol=0.0001, verbose=False, warm_start=False, momentum=0.9, nesterovs_momentum=True, early_stopping=False, validation_fraction=0.1, beta_1=0.9, beta_2=0.999, epsilon=1e08, n_iter_no_change=10)
[source]
fit(X, y)
[source]
Fit the model to data matrix X and target(s) y.
Parameters: 


Returns: 

get_params(deep=True)
[source]
Get parameters for this estimator.
Parameters: 


Returns: 

partial_fit
Fit the model to data matrix X and target y.
Parameters: 


Returns: 

predict(X)
[source]
Predict using the multilayer perceptron classifier
Parameters: 


Returns: 

predict_log_proba(X)
[source]
Return the log of probability estimates.
Parameters: 


Returns: 

predict_proba(X)
[source]
Probability estimates.
Parameters: 


Returns: 

score(X, y, sample_weight=None)
[source]
Returns the mean accuracy on the given test data and labels.
In multilabel classification, this is the subset accuracy which is a harsh metric since you require for each sample that each label set be correctly predicted.
Parameters: 


Returns: 

set_params(**params)
[source]
Set the parameters of this estimator.
The method works on simple estimators as well as on nested objects (such as pipelines). The latter have parameters of the form <component>__<parameter>
so that it’s possible to update each component of a nested object.
Returns: 


sklearn.neural_network.MLPClassifier
© 2007–2018 The scikitlearn developers
Licensed under the 3clause BSD License.
http://scikitlearn.org/stable/modules/generated/sklearn.neural_network.MLPClassifier.html