1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
//! Integration tests for the `machine_learning` feature.
//!
//! This is the crate root of the `machine_learning` test binary, declared as a `[[test]]`
//! target in `Cargo.toml`. Each per-algorithm file in this directory is a submodule.
//!
//! Shared helpers (a seeded RNG constructor and `assert_allclose`) live in [`common`].
/// Shared helpers: a seeded RNG constructor and `assert_allclose`.
/// Tests for `DBSCAN`: constructor validation, fit and predict errors, and cluster correctness.
/// Tests for the decision tree classifier: constructor validation and closed-form predictions.
/// Tests for `IsolationForest`: constructor validation, scoring, and outlier detection.
/// Tests for kernel PCA: constructor validation and per-kernel fit and transform checks.
/// Tests for `KMeans`: fit and predict errors, inertia, determinism, and save/load round-trips.
/// Tests for the KNN classifier: distance metrics, weighting, and save/load round-trips.
/// Tests for `LDA` (linear discriminant analysis): fit and predict, and closed-form checks.
/// Tests for `LinearRegression`: constructor validation, both solvers, and regularization.
/// Tests for `LinearSVC`: constructor validation, label domain, and penalties.
/// Tests for `LogisticRegression` and `generate_polynomial_features`.
/// Tests for `MeanShift` clustering and `estimate_bandwidth`.
/// Cross-cutting tests for the Fit and Predict traits, save/load, and NotFitted errors.
/// Tests for PCA: construction, validation, and each SVD solver.
/// Tests for `SVC`: label domain and decision function sign.
/// Tests for `TSNE`: fit_transform shape, determinism, and neighborhood preservation.