def naive_transform( self, docs, vocabulary ):
		x = np.zeros(( len( docs ), len( vocabulary )))
		for row_i, doc in enumerate( docs ):
			for word in doc:
				x[row_i,:] *= self.alpha
				try:
					col_i = vocabulary[word]
				except __HOLE__:
					# not in vocabulary: a one-letter word or a word from a test set
					continue
				x[row_i, col_i] += 1
		return x
dataset/ETHPy150Open zygmuntz/classifying-text/fofe/fofe.py/FofeVectorizer.naive_transform