TensorLearn
Back to Course
Machine Learning: The Engineering Approach
Module 1 of 13

1. The Scikit-Learn API

The Universal API

Scikit-Learn (sklearn) is beautiful because of its consistency. All models follow the same interface.

python
from sklearn.linear_model import LinearRegression # 1. Instantiate model = LinearRegression() # 2. Fit (Train) model.fit(X_train, y_train) # 3. Predict predictions = model.predict(X_test)

Hyperparameters vs Parameters

  • Hyperparameters: Settings YOU choose (e.g., Tree Depth). Set during instantiation.
  • Parameters: Values the MODEL learns (e.g., Weights). Available after .fit().

Mark as Completed

TensorLearn - AI Engineering for Professionals