prteek/mnist1d_1v7
Viewer โข Updated โข 800
How to use prteek/mnist1d_clf_1v7 with Scikit-learn:
from huggingface_hub import hf_hub_download
import joblib
model = joblib.load(
hf_hub_download("prteek/mnist1d_clf_1v7", "sklearn_model.joblib")
)
# only load pickle files from sources you trust
# read more about it here https://skops.readthedocs.io/en/stable/persistence.htmlA binary classifier that tells apart the digits 1 and 7 in the MNIST-1D dataset.
A scikit-learn pipeline: StandardScaler followed by LogisticRegression(max_iter=1000).
Trained on prteek/mnist1d_f: the
y == 1 and y == 7 rows of the christopher/mnist1d train split (800 rows). Each
example has 40 features (x_0 โฆ x_39) and a label y.
80% of the rows were used for training and 20% were held out for testing, split
stratified on y with random_state=42.
| Metric | Held-out test set (160 rows) |
|---|---|
| Accuracy | 0.887 |
import joblib
from huggingface_hub import hf_hub_download
model = joblib.load(hf_hub_download("prteek/mnist1d_clf", "model.joblib"))
preds = model.predict(X) # X: DataFrame with columns x_0 โฆ x_39; returns 1 or 7
joblib files can run arbitrary code when loaded, so only load models you trust.