spiceai/docs
Models
Getting Started
In this section, we will explore various models offered by the Spice Cloud Platform.
Model Types
- Classification Models: Used to categorize data into predefined classes.
- Regression Models: Used for predicting continuous values.
- Clustering Models: Used for grouping similar data points.
Example of a Classification Model
from sklearn import datasets
from sklearn.ensemble import RandomForestClassifier
# Load dataset
iris = datasets.load_iris()
X, y = iris.data, iris.target
# Create a classifier
clf = RandomForestClassifier(n_estimators=100)
clf.fit(X, y)
Advanced Features
Hyperparameter Tuning
- Use techniques like Grid Search or Random Search to optimize model performance.
Model Evaluation Metrics
- Accuracy: Ratio of correct predictions to total predictions.
- F1 Score: Balance between precision and recall.