9cabb26008ca466ff5cc9f1651162757917a8e9a,skater/core/local_interpretation/text_interpreter.py,,vectorize_as_tf_idf,#Any#,45

Before Change




def vectorize_as_tf_idf(data):
    tfidf_vec = TfidfVectorizer(sublinear_tf=True, max_df=0.5,
                    stop_words="english")
    X = tfidf_vec.fit_transform(data)
    return tfidf_vec, X

After Change


    Term Frequency times Inverse Document Frequency
    // TODO: extend support to other forms of Vectorization schemes - Feature Hashing
    // Converting raw document to tf-idf feature matrix
    tfidf_vec = TfidfVectorizer(sublinear_tf=kwargs["sublinear_tf"], max_df=kwargs["max_df"],
                    stop_words=kwargs["stop_words"], smooth_idf=kwargs["smooth_idf"],
                                ngram_range=kwargs["ngram_range"])
    X = tfidf_vec.fit_transform(data)
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 4

Instances


Project Name: datascienceinc/Skater
Commit Name: 9cabb26008ca466ff5cc9f1651162757917a8e9a
Time: 2017-11-24
Author: pramitchoudhary@ip-172-30-0-2.us-west-2.compute.internal
File Name: skater/core/local_interpretation/text_interpreter.py
Class Name:
Method Name: vectorize_as_tf_idf


Project Name: nishitpatel01/Fake_News_Detection
Commit Name: 95b8e2a603f66cc3091e3266a717c0f206be3e95
Time: 2017-12-03
Author: nkp3@illinois.edu
File Name: FeatureSelection.py
Class Name:
Method Name:


Project Name: nishitpatel01/Fake_News_Detection
Commit Name: 3b49ffd98696ad697cf2b9685e581459d51ea0b1
Time: 2017-12-03
Author: nkp3@illinois.edu
File Name: FeatureSelection.py
Class Name:
Method Name: