Sous chaque méthode, ses extensions (Q CS XT Z ZZ IB W U) : en gras et cochée, elle existe ; barrée, elle n'existe pas. Les extensions et leur sens
Exemples : 0 viennent des tests de la bibliothèque ; 2 ont été composés à partir de la signature de chaque méthode et exécutés pour cette page, sur un objet neuf, par exemple oDS = new stzTrainingSet([]) oDS.AddExample([ 1, 1 ], "yes") oDS.AddExample([ 1, 0 ], "yes") oDS.AddExample([ 0, 1 ], "no") oDS.AddExample([ 0, 0 ], "no") o1 = new stzLogisticRegression(oDS). 9 méthodes n'en ont pas encore. Exemples exécutés le 2026-10-03 20:23 dans la bibliothèque au commit 0e72e2e2c.
Méthode
Explication, telle que la source la porte
init
(sans commentaire dans la source : le nom se lit comme une phrase)initaucune extension
TrainingSetQ
THE HELD SET IS LIVE THROUGH HERE. Haro COPIES an object into an attribute, so the set handed to the constructor is a SNAPSHOT: growing the caller's own object afterwards would NOT reach this learner. Grow it through this accessor -- oLearner.TrainingSetQ().AddExample(...) -- which reaches the real held set (accessor + method call is live in Haro).aucune extension
SetLearningRate
(sans commentaire dans la source : le nom se lit comme une phrase)set learning rateaucune extension
The drift against the old loop was measured, not assumed, and it is never zero: 1e-16 after ONE epoch, 1e-15 at ten, 1e-14 at a hundred and still 1e-14 at five hundred. That is the one thing that could not be held fixed -- Haro's exp is the C library's, the engine's is Zig's, they agree to within an ulp, and gradient descent feeds each step into the next so the difference grows about a decade per five hundred epochs. Against weights of magnitude 1 to 10 it stays around 1e-15 relative, and both loops classify identically. 1 exemples exécutésaucune extension
SCORED BY THE RULE IT WAS FITTED BY. This goes through the engine too, and not for speed -- one row is dominated by marshalling. It is here because Haro's exp and Zig's exp agree only to within an ulp, and a model whose predictions come from a slightly different function than its fit is a question nobody should have to think about. One definition, both ends. 1 exemples exécutésaucune extension
Probabilities
Probabilities for many rows in ONE crossing. TrainingAccuracy() below is the reason this exists: it scores every training example, and a round trip per row would have made the diagnostic cost more than the fit it diagnoses.aucune extension
Needing standardised features is the normal requirement for stochastic gradient descent, not a defect here -- but nothing surfaced the failure. This does: a diverged model scores around chance on data it has already seen, where a converged one scores near 1. 1 exemples exécutésexemple composé