Update qbmodel.py
Browse files- qbmodel.py +1 -2
qbmodel.py
CHANGED
@@ -1,7 +1,6 @@
|
|
1 |
from typing import List, Tuple
|
2 |
import nltk
|
3 |
import sklearn
|
4 |
-
import question_categorizer as qc
|
5 |
from .question_categorizer import TextClassificationModel
|
6 |
from .tfidf_model import NLPModel
|
7 |
import transformers
|
@@ -27,7 +26,7 @@ class QuizBowlModel:
|
|
27 |
|
28 |
self.categories = ['Geography', 'Religion', 'Philosophy', 'Trash','Mythology', 'Literature','Science', 'Social Science', 'History', 'Current Events', 'Fine Arts']
|
29 |
self.tfidf_models = [None for _ in range(len(self.categories))]
|
30 |
-
self.qc_model =
|
31 |
|
32 |
self.load_tfidf_models(clear=clear)
|
33 |
|
|
|
1 |
from typing import List, Tuple
|
2 |
import nltk
|
3 |
import sklearn
|
|
|
4 |
from .question_categorizer import TextClassificationModel
|
5 |
from .tfidf_model import NLPModel
|
6 |
import transformers
|
|
|
26 |
|
27 |
self.categories = ['Geography', 'Religion', 'Philosophy', 'Trash','Mythology', 'Literature','Science', 'Social Science', 'History', 'Current Events', 'Fine Arts']
|
28 |
self.tfidf_models = [None for _ in range(len(self.categories))]
|
29 |
+
self.qc_model = TextClassificationModel.load_model("models/categorizer")
|
30 |
|
31 |
self.load_tfidf_models(clear=clear)
|
32 |
|