Versions in this module Expand all Collapse all v0 v0.1.0 Oct 21, 2026 Changes in this version + const AutoExactMaxRows + func RegisterLoss(name string, dec LossDecoder) + type Huber struct + Delta float64 + func (l Huber) GradHess(y, raw float64) (g, h float64) + func (l Huber) InitScore(y, w []float64) float64 + func (l Huber) LossParams() map[string]float64 + func (l Huber) Metric(y, raw, w []float64) float64 + func (l Huber) Name() string + func (l Huber) Transform(raw float64) float64 + func (l Huber) Validate([]float64) error + type ImportanceType int + const SplitCount + const TotalGain + type LeafRenewer interface + RenewLeaf func(residual, w []float64) float64 + type Logistic struct + func (Logistic) GradHess(y, raw float64) (g, h float64) + func (Logistic) InitScore(y, w []float64) float64 + func (Logistic) Metric(y, raw, w []float64) float64 + func (Logistic) Name() string + func (Logistic) Transform(raw float64) float64 + func (Logistic) Validate(y []float64) error + type Loss interface + GradHess func(y, raw float64) (grad, hess float64) + InitScore func(y, w []float64) float64 + Metric func(y, raw, w []float64) float64 + Name func() string + Transform func(raw float64) float64 + type LossDecoder func(params map[string]float64) (Loss, error) + type LossValidator interface + Validate func(y []float64) error + type Model struct + BaseScore float64 + BestIteration int + BestScore float64 + LearningRate float64 + Loss Loss + Monotone []int + NumFeatures int + Trees []Tree + func Load(r io.Reader) (*Model, error) + func Train(X [][]float64, y, w []float64, p Params) (*Model, error) + func (m *Model) FeatureImportance(kind ImportanceType) []float64 + func (m *Model) MarshalJSON() ([]byte, error) + func (m *Model) Predict(x []float64) float64 + func (m *Model) PredictBatch(X [][]float64) []float64 + func (m *Model) PredictRaw(x []float64) float64 + func (m *Model) Save(w io.Writer) error + func (m *Model) UnmarshalJSON(b []byte) error + type Node struct + Cover float64 + DefaultLeft bool + Feature int + Gain float64 + Leaf bool + Left int + Right int + Threshold float64 + Value float64 + type ParamLoss interface + LossParams func() map[string]float64 + type Params struct + ColSample float64 + EarlyStoppingRounds int + Lambda float64 + LearningRate float64 + Loss Loss + MaxBins int + MaxDepth int + Method TreeMethod + MinChildWeight float64 + MinSplitGain float64 + Monotone []int + Rounds int + Seed uint64 + Subsample float64 + Validation *ValidationSet + Workers int + func DefaultParams() Params + type Quantile struct + Alpha float64 + func (l Quantile) GradHess(y, raw float64) (g, h float64) + func (l Quantile) InitScore(y, w []float64) float64 + func (l Quantile) LossParams() map[string]float64 + func (l Quantile) Metric(y, raw, w []float64) float64 + func (l Quantile) Name() string + func (l Quantile) RenewLeaf(residual, w []float64) float64 + func (l Quantile) Transform(raw float64) float64 + func (l Quantile) Validate([]float64) error + type SquaredError struct + func (SquaredError) GradHess(y, raw float64) (g, h float64) + func (SquaredError) InitScore(y, w []float64) float64 + func (SquaredError) Metric(y, raw, w []float64) float64 + func (SquaredError) Name() string + func (SquaredError) Transform(raw float64) float64 + type Tree struct + Nodes []Node + type TreeMethod int + const Auto + const Exact + const Hist + type ValidationSet struct + W []float64 + X [][]float64 + Y []float64