TanujInsane commited on
Commit ·
cdd19a1
1
Parent(s): d13f865
Fix LogisticRegression multi_class error
Browse files- baseline_inference.py +1 -1
baseline_inference.py
CHANGED
|
@@ -30,7 +30,7 @@ def train_model(difficulty):
|
|
| 30 |
all_labels.append(label)
|
| 31 |
pipeline = Pipeline([
|
| 32 |
("tfidf", TfidfVectorizer(ngram_range=(1,2), max_features=5000, sublinear_tf=True)),
|
| 33 |
-
("clf", LogisticRegression(max_iter=1000, C=5.0, solver="lbfgs"
|
| 34 |
])
|
| 35 |
pipeline.fit(all_texts, all_labels)
|
| 36 |
save_path = os.path.join(CACHE_DIR, f"model_{difficulty}.pkl")
|
|
|
|
| 30 |
all_labels.append(label)
|
| 31 |
pipeline = Pipeline([
|
| 32 |
("tfidf", TfidfVectorizer(ngram_range=(1,2), max_features=5000, sublinear_tf=True)),
|
| 33 |
+
("clf", LogisticRegression(max_iter=1000, C=5.0, solver="lbfgs"))
|
| 34 |
])
|
| 35 |
pipeline.fit(all_texts, all_labels)
|
| 36 |
save_path = os.path.join(CACHE_DIR, f"model_{difficulty}.pkl")
|