def vectorizer(sentence,vocab):
	"""
	Converts a text sentence into a vector representation in the vocabulary vector space.
	"""
	vocabulary = vocab.value
	vec = np.zeros(len(vocabulary))
	for word in sentence.split(" "):
		if vocabulary in word:
			vec[vocabulary.index(word)] += 1
	return Vectors.dense(vec)
dataset/ETHPy150Open DistrictDataLabs/spark-workshop/apps/lda_WarAndPeace.py/vectorizer/swapped operands of `in`