Closed hmgomes closed 1 year ago
Updated the AdaptiveRandomForestTest.ref to reflect the changes to the base learner (ARFHoeffdingTree).
Updated the code to allow the last feature to also be selected in the random selection.
Also, adding another version of AdaptiveRandomForestTest.ref
to reflect the changes in ARFHoeffdingTree
code.
This change address an issue when the subspaceSizeOption was set to 1. Effectively, when the subspaceSize was set to 1, the AttributeClassObserver for that attribute was not initialised.
Furthermore, also made two other changes:
1) If the subspace size is greater than the number of features, there is no need to randomly create the subspaces (just use the original feature set) 2) Set the minimum value of subspaceSizeOption to 1 to prevent the occurrence of zero or negative values. If other classes utilizing the ARFHoeffdingTree need to implement custom logic for handling negative subspace sizes (e.g., totalNumberOfFeatures - subspaceSize), such handling should be the responsibility of those respective classes For example, the AdaptiveRandomForest class handle such cases here