Logistic regression model with different versions
Browse files- logreg_1_0_model.pkl +3 -0
- requirements.txt +9 -0
- requirements2.txt +9 -0
- sk_1_0.ipynb +0 -0
- sk_1_1.ipynb +68 -0
logreg_1_0_model.pkl
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:93b1c50eadf8ff94f9a87e5aa24181226c7c1a874100d628f7bcb9970098b108
|
3 |
+
size 991
|
requirements.txt
ADDED
@@ -0,0 +1,9 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
joblib==1.2.0
|
2 |
+
numpy==1.24.0
|
3 |
+
pandas==1.5.2
|
4 |
+
python-dateutil==2.8.2
|
5 |
+
pytz==2022.7
|
6 |
+
scikit-learn==1.0
|
7 |
+
scipy==1.9.3
|
8 |
+
six==1.16.0
|
9 |
+
threadpoolctl==3.1.0
|
requirements2.txt
ADDED
@@ -0,0 +1,9 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
joblib==1.2.0
|
2 |
+
numpy==1.24.0
|
3 |
+
pandas==1.5.2
|
4 |
+
python-dateutil==2.8.2
|
5 |
+
pytz==2022.7
|
6 |
+
scikit-learn==1.1.0
|
7 |
+
scipy==1.9.3
|
8 |
+
six==1.16.0
|
9 |
+
threadpoolctl==3.1.0
|
sk_1_0.ipynb
ADDED
The diff for this file is too large to render.
See raw diff
|
|
sk_1_1.ipynb
ADDED
@@ -0,0 +1,68 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"cells": [
|
3 |
+
{
|
4 |
+
"cell_type": "code",
|
5 |
+
"execution_count": 1,
|
6 |
+
"metadata": {},
|
7 |
+
"outputs": [],
|
8 |
+
"source": [
|
9 |
+
"#Import important libraries\n",
|
10 |
+
"import pandas as pd\n",
|
11 |
+
"import numpy as np\n",
|
12 |
+
"\n",
|
13 |
+
"#Model saving\n",
|
14 |
+
"import pickle"
|
15 |
+
]
|
16 |
+
},
|
17 |
+
{
|
18 |
+
"cell_type": "code",
|
19 |
+
"execution_count": 2,
|
20 |
+
"metadata": {},
|
21 |
+
"outputs": [
|
22 |
+
{
|
23 |
+
"name": "stderr",
|
24 |
+
"output_type": "stream",
|
25 |
+
"text": [
|
26 |
+
"/Users/ipinmi/Desktop/hugging_face/sklearn_1_1/lib/python3.10/site-packages/sklearn/base.py:329: UserWarning: Trying to unpickle estimator LogisticRegression from version 1.0 when using version 1.1.0. This might lead to breaking code or invalid results. Use at your own risk. For more info please refer to:\n",
|
27 |
+
"https://scikit-learn.org/stable/modules/model_persistence.html#security-maintainability-limitations\n",
|
28 |
+
" warnings.warn(\n"
|
29 |
+
]
|
30 |
+
}
|
31 |
+
],
|
32 |
+
"source": [
|
33 |
+
"# Load Model from version 1.0\n",
|
34 |
+
"filePath = \"logreg_1_0_model.pkl\"\n",
|
35 |
+
"\n",
|
36 |
+
"with open(filePath, \"rb\") as file:\n",
|
37 |
+
" logreg_model = pickle.load(file)"
|
38 |
+
]
|
39 |
+
}
|
40 |
+
],
|
41 |
+
"metadata": {
|
42 |
+
"kernelspec": {
|
43 |
+
"display_name": "sklearn_1_1",
|
44 |
+
"language": "python",
|
45 |
+
"name": "python3"
|
46 |
+
},
|
47 |
+
"language_info": {
|
48 |
+
"codemirror_mode": {
|
49 |
+
"name": "ipython",
|
50 |
+
"version": 3
|
51 |
+
},
|
52 |
+
"file_extension": ".py",
|
53 |
+
"mimetype": "text/x-python",
|
54 |
+
"name": "python",
|
55 |
+
"nbconvert_exporter": "python",
|
56 |
+
"pygments_lexer": "ipython3",
|
57 |
+
"version": "3.10.2"
|
58 |
+
},
|
59 |
+
"orig_nbformat": 4,
|
60 |
+
"vscode": {
|
61 |
+
"interpreter": {
|
62 |
+
"hash": "8adb9513855e895f6a0284d0176802441835b96b96bae97ff79cda37d822e792"
|
63 |
+
}
|
64 |
+
}
|
65 |
+
},
|
66 |
+
"nbformat": 4,
|
67 |
+
"nbformat_minor": 2
|
68 |
+
}
|