def METHOD_NAME(self, text):
    ngrams = {}
    for word in white_space_re.split(text):
        word = "_%s_" % word
        size = len(word)
        for i in range(size - 1):
            for s in (1, 2, 3, 4):
                end = i + s
                if end >= size:
                    break
                sub = word[i:end]
                if sub not in ngrams:
                    ngrams[sub] = 0
                ngrams[sub] += 1
    self.ngrams = ngrams
    return self