from huggingface_hub import hf_hub_url, cached_download
import joblib
import pandas as pd
REPO_ID = "julien-c/wine-quality"
FILENAME = "sklearn_model.joblib"
model = joblib.load(cached_download(
hf_hub_url(REPO_ID, FILENAME)
))
# model is a `sklearn.pipeline.Pipeline`
Get sample data from this repo
data_file = cached_download(
hf_hub_url(REPO_ID, "winequality-red.csv")
)
winedf = pd.read_csv(data_file, sep=";")
X = winedf.drop(["quality"], axis=1)
Y = winedf["quality"]
print(X[:3])
fixed acidity
volatile acidity
citric acid
residual sugar
chlorides
free sulfur dioxide
total sulfur dioxide
density
pH
sulphates
alcohol
0
7.4
0.7
0
1.9
0.076
11
34
0.9978
3.51
0.56
9.4
1
7.8
0.88
0
2.6
0.098
25
67
0.9968
3.2
0.68
9.8
2
7.8
0.76
0.04
2.3
0.092
15
54
0.997
3.26
0.65
9.8
Get your prediction
labels = model.predict(X[:3])
# [5, 5, 5]
Eval
model.score(X, Y)
# 0.6616635397123202
🍷 Disclaimer
No red wine was drunk (unfortunately) while training this model 🍷
Runs of julien-c wine-quality on huggingface.co
77
Total runs
0
24-hour runs
1
3-day runs
3
7-day runs
-78
30-day runs
More Information About wine-quality huggingface.co Model
wine-quality huggingface.co
wine-quality huggingface.co is an AI model on huggingface.co that provides wine-quality's model effect (), which can be used instantly with this julien-c wine-quality model. huggingface.co supports a free trial of the wine-quality model, and also provides paid use of the wine-quality. Support call wine-quality model through api, including Node.js, Python, http.
wine-quality huggingface.co is an online trial and call api platform, which integrates wine-quality's modeling effects, including api services, and provides a free online trial of wine-quality, you can try wine-quality online for free by clicking the link below.
julien-c wine-quality online free url in huggingface.co:
wine-quality is an open source model from GitHub that offers a free installation service, and any user can find wine-quality on GitHub to install. At the same time, huggingface.co provides the effect of wine-quality install, users can directly use wine-quality installed effect in huggingface.co for debugging and trial. It also supports api for free installation.