def get_sentence_vector(self, text):
if text.find('<STR_LIT:\n>') != -<NUM_LIT:1>:<EOL><INDENT>raise ValueError(<EOL>"<STR_LIT>"<EOL>)<EOL><DEDENT>text += "<STR_LIT:\n>"<EOL>dim = self.get_dimension()<EOL>b = fasttext.Vector(dim)<EOL>self.f.getSentenceVector(b, text)<EOL>return np.array(b)<EOL>
Given a string, get a single vector represenation. This function
assumes to be given a single line of text. We split words on
whitespace (space, newline, tab, vertical tab) and the control
characters carriage return, formfeed and the null character.