def to_dict(self):
        """Convert to dictionary.

        :return (dict): A dict mapping from strings to vectors.
        """
        d = {}
        for word, idx in self.vocab.iteritems():
            d[word] = self.array[idx].tolist()
        return d
Convert to dictionary.

        :return (dict): A dict mapping from strings to vectors.