@staticmethod<EOL><INDENT>def log(model_folder, binary_file="<STR_LIT>",<EOL>log_folder="<STR_LIT>"):<DEDENT>
file = join(model_folder, binary_file)<EOL>vectorizer = joblib.load(file)<EOL>output = []<EOL>for token in vectorizer.vocabulary_:<EOL><INDENT>index = vectorizer.vocabulary_[token]<EOL>ngram = len(token.split("<STR_LIT:U+0020>"))<EOL>output.append({<EOL>"<STR_LIT>": token,<EOL>"<STR_LIT>": ngram,<EOL>"<STR_LIT>": vectorizer.idf_[index],<EOL>"<STR_LIT>": vectorizer.period_[index].item(),<EOL>"<STR_LIT>": vectorizer.df_[index],<EOL>})<EOL><DEDENT>output = sorted(output, key=lambda item: item["<STR_LIT>"])<EOL>content = json.dumps(output, ensure_ascii=False)<EOL>write(join(log_folder, "<STR_LIT>"), content)<EOL>
Parameters
----------
model_folder : string
    folder contains binaries file of model
binary_file : string
    file path to tfidf binary file
log_folder : string
    log folder