lib/rumale/ensemble/stacking_classifier.rb
# Predict class labels for samples.
#
# @param x [Numo::DFloat] (shape: [n_samples, n_features]) The samples to predict the labels.
# @return [Numo::Int32] (shape: [n_samples]) The predicted class label per sample.
Predict class labels for samples.
Predict class labels for samples .
def predict(x)
        x = check_convert_sample_array(x)
        z = transform(x)
        Numo::Int32.cast(@encoder.inverse_transform(@meta_estimator.predict(z)))
      end
def predict ( x ) x = check_convert_sample_array ( x ) z = transform ( x ) Numo :: Int32 . cast ( @encoder . inverse_transform ( @meta_estimator . predict ( z ) ) ) end
Predict class labels for samples.
Predict class labels for samples .
[n_samples]) The predicted class label per sample.
[ n_samples ] ) The predicted class label per sample .
Numo::Int32
x
[n_samples, n_features]) The samples to predict the labels.
[ n_samples n_features ] ) The samples to predict the labels .