classification/tree_manager.py
def create_trees(self, importance_values: List[int]) -> None:
        """
        Make the decision trees and train them. The trees are stored in this class, separated by
        the importance of the fail class.
        """
        target_names = ["Fail", "Pass"]
        trees = defaultdict(list)
        for importance in importance_values:
            for i in range(7):
                print(f'making tree for week {i + 1} with importance {importance}')
                x_train, x_test, y_train, y_test = self.prep_tree_data(i + 1)
                tree = TreeClassifier(x_train, x_test, y_train, y_test, target_names, importance)
                tree.run_model()
                trees[importance].append(tree)

        self.trees = trees

        Make the decision trees and train them. The trees are stored in this class, separated by
        the importance of the fail class.
        
Make the decision trees and train them. The trees are stored in this class, separated by
the importance of the fail class.
Make the decision trees and train them . The trees are stored in this class separated by the importance of the fail class .
def create_trees(self, importance_values: List[int]) -> None:
        target_names = ["Fail", "Pass"]
        trees = defaultdict(list)
        for importance in importance_values:
            for i in range(7):
                print(f'making tree for week {i + 1} with importance {importance}')
                x_train, x_test, y_train, y_test = self.prep_tree_data(i + 1)
                tree = TreeClassifier(x_train, x_test, y_train, y_test, target_names, importance)
                tree.run_model()
                trees[importance].append(tree)
        self.trees = trees
def create_trees ( self , importance_values : List [ int ] ) -> None : target_names = [ "Fail" , "Pass" ] trees = defaultdict ( list ) for importance in importance_values : for i in range ( 7 ) : print ( f'making tree for week {i + 1} with importance {importance}' ) x_train , x_test , y_train , y_test = self . prep_tree_data ( i + 1 ) tree = TreeClassifier ( x_train , x_test , y_train , y_test , target_names , importance ) tree . run_model ( ) trees [ importance ] . append ( tree ) self . trees = trees
Make the decision trees and train them.
Make the decision trees and train them .
"""
        Make the decision trees and train them. The trees are stored in this class, separated by
        the importance of the fail class.
        """
self
importance_values
List[int]