@@ -51,6 +51,17 @@ class Arsenal(BaseClassifier):
5151 Default of 0 means n_estimators is used.
5252 contract_max_n_estimators : int, default=100
5353 Max number of estimators when time_limit_in_minutes is set.
54+ class_weight{“balanced”, “balanced_subsample”}, dict or list of dicts, default=None
55+ From sklearn documentation:
56+ If not given, all classes are supposed to have weight one.
57+ The “balanced” mode uses the values of y to automatically adjust weights
58+ inversely proportional to class frequencies in the input data as
59+ n_samples / (n_classes * np.bincount(y))
60+ The “balanced_subsample” mode is the same as “balanced” except that weights
61+ are computed based on the bootstrap sample for every tree grown.
62+ For multi-output, the weights of each column of y will be multiplied.
63+ Note that these weights will be multiplied with sample_weight (passed through
64+ the fit method) if sample_weight is specified.
5465 n_jobs : int, default=1
5566 The number of jobs to run in parallel for both `fit` and `predict`.
5667 ``-1`` means using all processors.
@@ -76,17 +87,6 @@ class Arsenal(BaseClassifier):
7687 The collections of estimators trained in fit.
7788 weights_ : list of shape (n_estimators) of float
7889 Weight of each estimator in the ensemble.
79- class_weight{“balanced”, “balanced_subsample”}, dict or list of dicts, default=None
80- From sklearn documentation:
81- If not given, all classes are supposed to have weight one.
82- The “balanced” mode uses the values of y to automatically adjust weights
83- inversely proportional to class frequencies in the input data as
84- n_samples / (n_classes * np.bincount(y))
85- The “balanced_subsample” mode is the same as “balanced” except that weights
86- are computed based on the bootstrap sample for every tree grown.
87- For multi-output, the weights of each column of y will be multiplied.
88- Note that these weights will be multiplied with sample_weight (passed through
89- the fit method) if sample_weight is specified.
9090 n_estimators_ : int
9191 The number of estimators in the ensemble.
9292
@@ -147,10 +147,10 @@ def __init__(
147147 self .n_features_per_kernel = n_features_per_kernel
148148 self .time_limit_in_minutes = time_limit_in_minutes
149149 self .contract_max_n_estimators = contract_max_n_estimators
150- self .class_weight = class_weight
151150
152- self .random_state = random_state
151+ self .class_weight = class_weight
153152 self .n_jobs = n_jobs
153+ self .random_state = random_state
154154
155155 self .n_cases_ = 0
156156 self .n_channels_ = 0
0 commit comments