def _train(self):
        m = Model((Document(set(v), type=type) for type, v in self._vectors), weight=BINARY)
        f = sorted(m.features, key=getattr(m, self._method), reverse=True)
        sys.setrecursionlimit(max(len(f) * 2, 1000))
        self._root = self._tree([(v, type) for type, v in self._vectors], features=f)
Calculates information gain ratio for the features in the training data.
dataset/ETHPy150Open clips/pattern/pattern/vector/__init__.py/IGTree._train