CuckooSearch<T>
Models & Types · AiDotNet.Preprocessing.FeatureSelection.Metaheuristic
Cuckoo Search for feature selection.
Inheritance: TransformerBase<T, Matrix<T>, Matrix<T>> → CuckooSearch<T>
Implements: IFixedCountFeatureSelector<T>, ISupervisedFeatureSelector<T>
For Beginners
Cuckoos lay eggs in other birds’ nests. If the host bird finds the foreign egg, it throws it out and rebuilds. In optimization, poor solutions are “discovered” and replaced with new random ones, while good solutions survive and improve through Lévy flights (big random jumps).
How It Works
Cuckoo Search is inspired by the brood parasitism of cuckoo birds. Cuckoos lay eggs in other birds’ nests; if discovered, the host bird may abandon the nest. This translates to solution replacement and exploration.
Constructors
| Constructor | Summary |
|---|---|
CuckooSearch(int nFeaturesToSelect, int populationSize, int maxIterations, double discoveryRate, int? randomState, int[] columnIndices) |
Properties
| Property | Summary |
|---|---|
Vector<T> FeatureScores { get; } |
|
bool SupportsInverseTransform { get; } |
|
double DiscoveryRate { get; } |
|
int MaxIterations { get; } |
|
int NFeaturesToSelect { get; } |
|
int PopulationSize { get; } |
|
int[] SelectedIndices { get; } |
Methods
| Method | Summary |
|---|---|
Matrix<T> FitTransform(Matrix<T> data, Vector<T> target) |
|
bool[] GetSupportMask() |
|
string[] GetFeatureNamesOut(string[] inputFeatureNames) |
|
void Fit(Matrix<T> data, Vector<T> target) |