Download¶
The Download class is a supplement to all the models, and is intrinsically called upon by each model if the model files have not been downloaded onto the user’s storage. Should there be any problems during the intrinsic calls, the user can call the download class explicitly to get the same desired outcome.
gettags¶
class mitnewsclassify.download.download(model=None)
Downloads the model files for a given model.
- Parameters
- model (
string) - The model to be downloaded onto the user’s storage. - Default value is None and all models will be downloaded.
- Use
tfidffor the TF-IDF model,tfidf_bifor the TF-IDF Bigrams model,doc2vecfor the Doc2Vec model,gpt2for the GPT2 model,distilbertfor the DistilBERT model,ensemblefor the Ensemble model,trisemblefor the trisemble model andquadsemblefor the quadsemble model.
- model (
Example
>>> from mitnewsclassify import download
>>> download.download('tfidf')