Skip to content

HMath.MachineLearning

Module index · Numerical conventions

Description

Reproducible dense CPU estimators, preprocessing, clustering, and manifold methods. Features are finite rows; fitted state is immutable and independent of future transforms/predictions. Fit preprocessing separately within every training fold. Iterative fits expose residual, iterations, and convergence; no successful return alone implies an optimizer reached its optimum.

On this page

API Purpose
Dataset Finite observations as rows with a fixed, positive feature count.
MLConfig Positive iteration limittolerancerate and an explicit reproducible seed.
MLConfig Declaration and type contract below.
mlIterations Maximum outer iterations per fitted algorithm.
mlTolerance Absolute algorithm-specific stopping residual.
mlRate Positive gradient step size, where used.
mlSeed Seed for initialization, projection, or stochastic updates.
defaultMLConfig 500 iterations, absolute residual tolerance 1e-8, rate 0.05, PCG seed 42.
Fit A finite budget is a valid stopping point, distinct from convergence.
Fit Declaration and type contract below.
fitted Best fitted model retained when fitting stops.
fitIterations Completed fitting iterations.
fitResidual Algorithm-specific finite stopping residual at the returned model.
fitConverged Whether the selected stopping residual met tolerance; a budget stop may return False.

Documentation

Dataset

type Dataset = [[Double]] Source #

Finite observations as rows with a fixed, positive feature count.

MLConfig

data MLConfig Source #

Positive iteration limittolerancerate and an explicit reproducible seed.

Constructors

MLConfig 

Fields

Instances

Instances details
Show MLConfig Source # 
Instance details

Defined in HMath.MachineLearning.Internal

Eq MLConfig Source # 
Instance details

Defined in HMath.MachineLearning.Internal

defaultMLConfig

defaultMLConfig :: MLConfig Source #

500 iterations, absolute residual tolerance 1e-8, rate 0.05, PCG seed 42.

Fit

data Fit a Source #

A finite budget is a valid stopping point, distinct from convergence.

Constructors

Fit 

Fields

  • fitted :: a

    Best fitted model retained when fitting stops.

  • fitIterations :: Int

    Completed fitting iterations.

  • fitResidual :: Double

    Algorithm-specific finite stopping residual at the returned model.

  • fitConverged :: Bool

    Whether the selected stopping residual met tolerance; a budget stop may return False.

Instances

Instances details
Show a => Show (Fit a) Source # 
Instance details

Defined in HMath.MachineLearning.Internal

Methods

showsPrec :: Int -> Fit a -> ShowS #

show :: Fit a -> String #

showList :: [Fit a] -> ShowS #

Eq a => Eq (Fit a) Source # 
Instance details

Defined in HMath.MachineLearning.Internal

Methods

(==) :: Fit a -> Fit a -> Bool #

(/=) :: Fit a -> Fit a -> Bool #