ppforest2 v0.1.0
Projection Pursuit Decision Trees and Random Forests
Loading...
Searching...
No Matches
Train.hpp
Go to the documentation of this file.
1
9#pragma once
10
11#include "cli/CLIOptions.hpp"
12#include "utils/Types.hpp"
13#include "models/Model.hpp"
14
15namespace CLI {
16 class App;
17}
18
19namespace ppforest2::cli {
21 void setup_train(CLI::App& app, Params& params);
22
24 void add_model_options(CLI::App* sub, ModelParams& model);
25
31
44
49 int run_train(Params& params);
50}
CLI argument parsing, validation, and configuration for ppforest2.
std::shared_ptr< Model > Ptr
Definition Model.hpp:31
Definition Benchmark.hpp:21
Command-line interface: argument parsing, subcommands, and benchmark/evaluation orchestration.
Definition Benchmark.hpp:25
void setup_train(CLI::App &app, Params &params)
Register train subcommand options on app.
int run_train(Params &params)
Run the train subcommand.
void add_model_options(CLI::App *sub, ModelParams &model)
Add shared model options (size, lambda, threads, seed, vars) to sub.
TrainResult train_model(ppforest2::types::FeatureMatrix const &x, ppforest2::types::OutcomeVector const &y, Params const &params)
Train a single model (Forest or Tree) on the given dataset.
Eigen::Matrix< Feature, Eigen::Dynamic, Eigen::Dynamic > FeatureMatrix
Dynamic-size matrix of feature values.
Definition Types.hpp:33
Eigen::Matrix< Outcome, Eigen::Dynamic, 1 > OutcomeVector
Dynamic-size column vector of predictions.
Definition Types.hpp:42
Model training parameters shared by train and evaluate.
Definition ModelParams.hpp:14
All CLI options and runtime parameters.
Definition CLIOptions.hpp:33
Result of a train operation containing the model and training duration.
Definition Train.hpp:27
long long duration
Definition Train.hpp:29
ppforest2::Model::Ptr model
Definition Train.hpp:28