XGBLearner
- class pyprophet.scoring.classifiers.XGBLearner(autotune, xgb_params, threads)[source]
Bases:
AbstractLearnerImplements an XGBoost-based learner for scoring.
- - tune
Tune hyperparameters using RandomizedSearchCV.
- - learn
Train the XGBoost model using decoy and target peaks.
- - score
Score the given peaks using the XGBoost model.
- - get_parameters
Retrieve the parameters of the XGBoost model.
- - set_parameters
Set the parameters of the XGBoost model.
- learn(decoy_peaks, target_peaks, use_main_score=True)[source]
Train the XGBoost model using decoy and target peaks.
- tune(decoy_peaks, target_peaks, use_main_score=True, cv_splits=3, n_jobs=-1)[source]
Tune hyperparameters using RandomizedSearchCV for faster optimization.
- Parameters:
decoy_peaks (Experiment) – Decoy peaks data.
target_peaks (Experiment) – Target peaks data.
use_main_score (bool) – Whether to use the main score.
cv_splits (int) – Number of cross-validation splits.
n_jobs (int) – Number of parallel jobs.
- Returns:
The tuned learner instance.
- Return type: