deepbox
Release Notes
What changed in Deepbox 1.5.0, released 2026-10-03.
- v1.5.0
- 2026-10-03
A quality release. Every source file was reviewed line by line, and the results were checked against NumPy, SciPy, scikit-learn, PyTorch and pandas. About 1,500 issues were fixed, many of them wrong results in 1.0.0. The release also makes the API more consistent: tensors share one method surface, training works on plain tensors, mixed dtypes promote instead of throwing, and every export has a camelCase name.
No export, option or method was removed or renamed. Some results change because they were wrong before, some dtypes change because of the new dtype rules, and one type changed (forward(Tensor) on layers); all of this is listed under "Upgrading from 1.0".
The migration notes have their own page: Upgrading from 1.0.
- Tensor methods.
TensorandGradTensorshare one method surface, so code reads the same with or without gradient tracking:t.add(1).mul(2).sum(),t.T,t.matmul(w),t.softmax(-1),t.argmax(1), comparisons, rounding,sort,flip,squeeze,unsqueeze,gather,item()and more. Plain tensors also haverequiresGrad(false),grad(null) and abackward()that explains why it cannot run. - ndarray:
argmax,argmin,nonzero,argwhere,countNonzero,takeAlongAxis,putAlongAxis,nanvar,nanmedian,nanprod,nanargmin,nanargmax,nancumsum,nanquantile;uniqueoptions (returnIndex,returnInverse,returnCounts,axis); batchedcross;dotandmatmulbroadcast batch dimensions likenumpy.matmul; activationsrelu6,selu,celu,softsign,hardsigmoid,hardswish,logSigmoid,hardshrink,softshrink; exact GELU throughgelu(t, { approximate: "none" }). New differentiableGradTensormethods (sin,cos,tan,log1p,expm1,maximum,minimum,cumsum,prod,std,var,softplus,mish,swish,selu,clone) and multi-axis reductions. - core:
promoteTypes. - nn:
MultiheadAttentionoptionsneedWeightsandkeyPaddingMask; Transformer layersactivation("relu"or"gelu") andnormFirst; convolutiondilation,groupsandpadding: "same" | "valid"; poolingceilMode; layersReLU6,LogSigmoid,CELU,Softshrink,HardshrinkandThreshold;TraineroptionsaccumulationStepsandrestoreBestWeights;tripletMarginLosssupports autograd and aswapoption; loss functions accept the output ofModule.forwarddirectly. - metrics: multiclass
rocAucScore(multiClass: "ovr" | "ovo"),logLoss,jaccardScoreandmatthewsCorrcoef; an options object{ average, labels, zeroDivision, sampleWeight }forprecision,recall,f1Score,fbetaScoreandjaccardScore;sampleWeightfor the common classification and regression metrics;meanAbsolutePercentageError(scikit-learn semantics, a fraction). - dataframe:
fillnawith per-column values andmethod: "ffill" | "bfill", plusffill()andbfill();corrwithmethod("pearson","spearman","kendall") andminPeriods;samplewithfrac,replaceandweights;groupBywithgetGroup,nunique,quantile,transformand named aggregation;rollingwithminPeriodsandcenter;concatwithjoinandignoreIndex;valueCountswithnormalizeanddropna. - ml: trees and forests accept
sampleWeight,classWeight,minImpurityDecrease,maxLeafNodesandccpAlpha; every estimator hasclone();Ridgewithalpha: 0on rank-deficient input returns the minimum-norm solution, as scikit-learn does. - stats: an
alternativeoption onpearsonr,spearmanr,kendalltauandpointbiserialr;kendalltauvariantandmethod;wilcoxonzeroMethod;benjaminiYekutieliandhochberg. - datasets:
fetch20NewsgroupsandfetchIMDBload the official archives by default (the 1.0.0 default URLs returned 404). - Names. Every snake_case export now has a camelCase name, for example
matrixPower,blockDiag,solveBanded,toDatetime,dateRange,crossValScore,crossValidate,exportText,multivariateNormal,studentT,gaussianKde,ttest1samp,checkXYandcheckArray. The same holds for methods (DataFrame.dropDuplicates,resetIndex,setIndex,pctChange,valueCounts,memoryUsageandpivotTable; thedtaccessor'sisLeapYear,dayName,dayOfWeekand friends;str.getDummies;style.highlightMax,highlightMin,highlightNullandbackgroundGradient) and for options (leftOnandrightOninDataFrame.merge,bwMethodinkdeplot). When both spellings of an option are given, the camelCase one wins. - Tooling:
typecheck:docstype-checks every example and project against the source, andprose:checkkeeps em dashes out of the repository. Both run invalidate:all.
- The snake_case names that now have camelCase equivalents, and the lowercase
dtnamesdayofweek,dayofyear,weekofyearanddaysinmonth. They keep working and are marked@deprecatedin the type declarations.
The list below names the most significant fixes. Every module received many smaller ones (edge cases, validation, error messages, strided views, int64 input, documentation).
- nn:
Trainerpassed plain tensors to the model, so layers returned untracked results, no gradients reached the optimizer, and real models never trained.MultiheadAttentionand the Transformer layers threw for float64 or float16 input.EarlyStoppingkept state betweenfitcalls. Init functions wrote to the wrong elements of non-contiguous tensors. - ml:
OneClassSVMflagged most training rows as outliers (88 percent withnu = 0.1; scikit-learn: 10 percent).SVCpredictions,PCAprojections,HuberRegressor,LocalOutlierFactorscores,IsolationForestthresholds,CalibratedClassifierCV(Platt and isotonic), and random forest bootstrapping andmaxFeatures(which was ignored) now match scikit-learn. Estimators accept int64 input. Trees and forests return float64 results. - ndarray:
cumsumandcumprodwithout an axis returned the wrong shape;medianrejected multiple axes; leaf gradients could share one buffer, so gradient clipping scaled it several times;maxandminbackward failed for float32;floorDivandmoddisagreed with NumPy for large or fractional values; int32 multiplication lost low bits;corrcoef,covandtensordotreturned silent garbage on bad input. - linalg: non-symmetric
eig(now a real Francis double-shift QR), Hessenberg and QR on matrices with tiny entries, the symmetry test used byeig, and float64 results fortrace,matrixPower,expm,logmandsqrtm. - stats: special functions are accurate to about 1e-14 (the old
erfwas accurate to about 1e-7); p-value tails no longer underflow; binomial, Poisson and related pmfs use the saddle-point method;kstest,ks_2samp,anderson,mannwhitneyuandwilcoxonmatch SciPy 1.17, including exact small-sample p-values; Welch degrees of freedom are no longer rounded down. - metrics: metrics read strided and transposed tensors correctly, reject NaN labels, and match scikit-learn for
hingeLoss,coverageError,adjustedMutualInfoScoreandfbetaScoreon multiclass input. - preprocess:
TargetEncoderleaked the target across folds;RFEandRFECVranked eliminated features in reverse and did not work with the library's own tree models;KBinsDiscretizerput values on bin edges in the wrong bin; the seeded generator cycled after about 16,000 values. - dataframe:
tail(n)withnlarger than the frame,fromTensoron views, sorting with infinities,queryoperator precedence,evalparsing, cumulative operations with NaN,round(now half-to-even),ewmwith missing rows,str.match(now anchored like pandas) and nearest interpolation. - optim: state dicts were live references, loaded non-atomically and could pair state with the wrong parameter; tied weights were updated twice per step; strided parameters were updated in the wrong elements;
LBFGSignoredlineSearchFn: "strong_wolfe"; centeredRMSpropandRAdamnow match PyTorch exactly. - random: shuffling a view changed elements outside it;
categoricalwithout replacement could loop forever;dirichletwith small concentrations returned uniform rows;multivariateNormalaccepted invalid covariances. - datasets: one value in the bundled data tables was wrong (all five now equal scikit-learn's);
makeFriedman2,makeFriedman3,makeSparseUncorrelatedandmakeLowRankMatrixfollow scikit-learn's definitions;parseCSVread empty cells as 0;DataLoader.lengthignored the sampler; dataset ids are validated before they reach a URL. - plot: PNG output now draws grids and text and blends translucent colors;
fill_between,area,stackedBarandgroupedBardraw correctly;twinxshares the x axis; log-scale ranges; animated SVG timelines; tick labels (2.5 was drawn as "3"). - core:
toJSONturned NaN, Infinity and -0 into other values;setConfigreseeded the global generator on every call;WorkerPool.reduceapplied the initial value once per chunk, and an invalidmaxWorkerscould hang the process. On WebGPU, NaN handling,tanhandgelufor large inputs, average-pool backward, and launches above 16.7 million elements (which returned zeros) are fixed.
Hot paths in reductions, sorting, trees, metrics, DataFrame operations and autograd were reworked where results stay identical, for example an O(n log n) Kendall tau and a three-way quickselect that no longer degrades to quadratic time on constant input. binomial uses BTPE (as NumPy does) for means of 30 and above: a draw with n = 1e12 went from about 2.5 ms to a few microseconds, with exact results.
Beyond the unit tests (13,000+), every module was checked against its reference library with randomized differential tests: reductions against NumPy, estimators and metrics against scikit-learn, layers, gradients and optimizers against PyTorch, DataFrame operations against pandas, and statistics against SciPy. The unchanged 1.0.0 test suite was also run against this release, and every difference is one of the changes listed above.
README, SKILL.md, all examples and projects were updated to the 1.5.0 API and rewritten in plainer language. Defaults that differ from NumPy, pandas, scikit-learn and PyTorch are documented where they apply.
Found a mistake? Open an issue.