'Transform documents to document-term matrix.
Uses the vocabulary and document frequencies (df) learned by fit (or
fit_transform).
Parameters
raw_documents : iterable
an iterable which yields either str, unicode or file objects
copy : boolean, default True
Whether to copy X and operate on the copy or perform in-place
operations.
Returns
X : sparse matrix, [n_samples, n_features]
Tf-idf-weighted document-term matrix.'

def transform(self, raw_documents, copy=True):

    check_is_fitted(self, u'_tfidf', u'The    tfidf    vector    is    not    fitted')
    X = super(TfidfVectorizer, self).transform(raw_documents)
    return self._tfidf.transform(X, copy=False)
