[INFO] cloning repository https://github.com/LambdaAK/SimpleML [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/LambdaAK/SimpleML" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FLambdaAK%2FSimpleML", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FLambdaAK%2FSimpleML'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] 16e2758447be231c39180893ad27307f7268b8a7 [INFO] checking LambdaAK/SimpleML/16e2758447be231c39180893ad27307f7268b8a7 against master#ab869e094a907cc5d19b4080f22eccaf347f1f95 for pr-129604 [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FLambdaAK%2FSimpleML" "/workspace/builds/worker-4-tc1/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-4-tc1/source'... [INFO] [stderr] done. [INFO] validating manifest of git repo https://github.com/LambdaAK/SimpleML on toolchain ab869e094a907cc5d19b4080f22eccaf347f1f95 [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+ab869e094a907cc5d19b4080f22eccaf347f1f95" "metadata" "--manifest-path" "Cargo.toml" "--no-deps", kill_on_drop: false }` [INFO] removed /workspace/builds/worker-4-tc1/source/rust-toolchain.toml [INFO] started tweaking git repo https://github.com/LambdaAK/SimpleML [INFO] finished tweaking git repo https://github.com/LambdaAK/SimpleML [INFO] tweaked toml for git repo https://github.com/LambdaAK/SimpleML written to /workspace/builds/worker-4-tc1/source/Cargo.toml [INFO] crate git repo https://github.com/LambdaAK/SimpleML already has a lockfile, it will not be regenerated [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+ab869e094a907cc5d19b4080f22eccaf347f1f95" "fetch" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] [stderr] Blocking waiting for file lock on package cache [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-4-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-4-tc1/source:/opt/rustwide/workdir:ro,Z" "-v" "/var/lib/crater-agent-workspace/cargo-home:/opt/rustwide/cargo-home:ro,Z" "-v" "/var/lib/crater-agent-workspace/rustup-home:/opt/rustwide/rustup-home:ro,Z" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "CARGO_TARGET_DIR=/opt/rustwide/target" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-w" "/opt/rustwide/workdir" "-m" "1610612736" "--user" "0:0" "--network" "none" "ghcr.io/rust-lang/crates-build-env/linux@sha256:923055f121b5182466d55868a8b05e67af8ba4a3a3f6bad814e953ca3cd3ac2a" "/opt/rustwide/cargo-home/bin/cargo" "+ab869e094a907cc5d19b4080f22eccaf347f1f95" "metadata" "--no-deps" "--format-version=1", kill_on_drop: false }` [INFO] [stdout] b1cac84827785efa7f0f90f33c3d3aac1673ac77cc74b2525447e1524f841f15 [INFO] running `Command { std: "docker" "start" "-a" "b1cac84827785efa7f0f90f33c3d3aac1673ac77cc74b2525447e1524f841f15", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "b1cac84827785efa7f0f90f33c3d3aac1673ac77cc74b2525447e1524f841f15", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "b1cac84827785efa7f0f90f33c3d3aac1673ac77cc74b2525447e1524f841f15", kill_on_drop: false }` [INFO] [stdout] b1cac84827785efa7f0f90f33c3d3aac1673ac77cc74b2525447e1524f841f15 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-4-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-4-tc1/source:/opt/rustwide/workdir:ro,Z" "-v" "/var/lib/crater-agent-workspace/cargo-home:/opt/rustwide/cargo-home:ro,Z" "-v" "/var/lib/crater-agent-workspace/rustup-home:/opt/rustwide/rustup-home:ro,Z" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "CARGO_TARGET_DIR=/opt/rustwide/target" "-e" "CARGO_INCREMENTAL=0" "-e" "RUST_BACKTRACE=full" "-e" "RUSTFLAGS=--cap-lints=forbid" "-e" "RUSTDOCFLAGS=--cap-lints=forbid" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-w" "/opt/rustwide/workdir" "-m" "1610612736" "--user" "0:0" "--network" "none" "ghcr.io/rust-lang/crates-build-env/linux@sha256:923055f121b5182466d55868a8b05e67af8ba4a3a3f6bad814e953ca3cd3ac2a" "/opt/rustwide/cargo-home/bin/cargo" "+ab869e094a907cc5d19b4080f22eccaf347f1f95" "check" "--frozen" "--all" "--all-targets" "--message-format=json", kill_on_drop: false }` [INFO] [stdout] 9ff85893cd7ac3269daaf4cb95af5df022b60fb9ed72103df5a9960a9df6b54a [INFO] running `Command { std: "docker" "start" "-a" "9ff85893cd7ac3269daaf4cb95af5df022b60fb9ed72103df5a9960a9df6b54a", kill_on_drop: false }` [INFO] [stderr] Compiling libc v0.2.155 [INFO] [stderr] Checking byteorder v1.5.0 [INFO] [stderr] Compiling syn v2.0.72 [INFO] [stderr] Checking getrandom v0.2.15 [INFO] [stderr] Checking rand_core v0.6.4 [INFO] [stderr] Compiling zerocopy-derive v0.7.35 [INFO] [stderr] Checking zerocopy v0.7.35 [INFO] [stderr] Checking ppv-lite86 v0.2.20 [INFO] [stderr] Checking rand_chacha v0.3.1 [INFO] [stderr] Checking rand v0.8.5 [INFO] [stderr] Checking ml-library v0.1.0 (/opt/rustwide/workdir) [INFO] [stdout] warning: unused macro definition: `matrix` [INFO] [stdout] --> src/matrix.rs:6:14 [INFO] [stdout] | [INFO] [stdout] 6 | macro_rules! matrix { [INFO] [stdout] | ^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_macros)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `logistic_regression::LogisticRegression` [INFO] [stdout] --> src/main.rs:2:5 [INFO] [stdout] | [INFO] [stdout] 2 | use logistic_regression::LogisticRegression; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `lr::LinearRegression` [INFO] [stdout] --> src/main.rs:3:5 [INFO] [stdout] | [INFO] [stdout] 3 | use lr::LinearRegression; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `math::Expr` [INFO] [stdout] --> src/main.rs:4:5 [INFO] [stdout] | [INFO] [stdout] 4 | use math::Expr; [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `Kernel` [INFO] [stdout] --> src/main.rs:5:22 [INFO] [stdout] | [INFO] [stdout] 5 | use matrix::{ColVec, Kernel}; [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `crate::matrix::Matrix` [INFO] [stdout] --> src/main.rs:8:5 [INFO] [stdout] | [INFO] [stdout] 8 | use crate::matrix::Matrix; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `crate::perceptron::Perceptron` [INFO] [stdout] --> src/main.rs:10:5 [INFO] [stdout] | [INFO] [stdout] 10 | use crate::perceptron::Perceptron; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::cmp::Ordering` [INFO] [stdout] --> src/KNN.rs:1:5 [INFO] [stdout] | [INFO] [stdout] 1 | use std::cmp::Ordering; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `SystemTime` and `UNIX_EPOCH` [INFO] [stdout] --> src/main.rs:17:17 [INFO] [stdout] | [INFO] [stdout] 17 | use std::time::{SystemTime, UNIX_EPOCH}; [INFO] [stdout] | ^^^^^^^^^^ ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `logistic_regression::LogisticRegression` [INFO] [stdout] --> src/main.rs:2:5 [INFO] [stdout] | [INFO] [stdout] 2 | use logistic_regression::LogisticRegression; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused macro definition: `matrix` [INFO] [stdout] --> src/main.rs:25:14 [INFO] [stdout] | [INFO] [stdout] 25 | macro_rules! matrix { [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused macro definition: `row_vec` [INFO] [stdout] --> src/main.rs:44:14 [INFO] [stdout] | [INFO] [stdout] 44 | macro_rules! row_vec { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `lr::LinearRegression` [INFO] [stdout] --> src/main.rs:3:5 [INFO] [stdout] | [INFO] [stdout] 3 | use lr::LinearRegression; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused macro definition: `col_vec` [INFO] [stdout] --> src/main.rs:61:14 [INFO] [stdout] | [INFO] [stdout] 61 | macro_rules! col_vec { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `math::Expr` [INFO] [stdout] --> src/main.rs:4:5 [INFO] [stdout] | [INFO] [stdout] 4 | use math::Expr; [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `Kernel` [INFO] [stdout] --> src/main.rs:5:22 [INFO] [stdout] | [INFO] [stdout] 5 | use matrix::{ColVec, Kernel}; [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `crate::matrix::Matrix` [INFO] [stdout] --> src/main.rs:8:5 [INFO] [stdout] | [INFO] [stdout] 8 | use crate::matrix::Matrix; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `crate::perceptron::Perceptron` [INFO] [stdout] --> src/main.rs:10:5 [INFO] [stdout] | [INFO] [stdout] 10 | use crate::perceptron::Perceptron; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::cmp::Ordering` [INFO] [stdout] --> src/KNN.rs:1:5 [INFO] [stdout] | [INFO] [stdout] 1 | use std::cmp::Ordering; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `SystemTime` and `UNIX_EPOCH` [INFO] [stdout] --> src/main.rs:17:17 [INFO] [stdout] | [INFO] [stdout] 17 | use std::time::{SystemTime, UNIX_EPOCH}; [INFO] [stdout] | ^^^^^^^^^^ ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused macro definition: `matrix` [INFO] [stdout] --> src/main.rs:25:14 [INFO] [stdout] | [INFO] [stdout] 25 | macro_rules! matrix { [INFO] [stdout] | ^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_macros)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused macro definition: `row_vec` [INFO] [stdout] --> src/main.rs:44:14 [INFO] [stdout] | [INFO] [stdout] 44 | macro_rules! row_vec { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused macro definition: `col_vec` [INFO] [stdout] --> src/main.rs:61:14 [INFO] [stdout] | [INFO] [stdout] 61 | macro_rules! col_vec { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `num_rows` [INFO] [stdout] --> src/perceptron.rs:25:9 [INFO] [stdout] | [INFO] [stdout] 25 | let num_rows: usize = x.rows(); [INFO] [stdout] | ^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_num_rows` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `f` [INFO] [stdout] --> src/math.rs:444:23 [INFO] [stdout] | [INFO] [stdout] 444 | Expr::BinaryApp(f, a, b) => { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_f` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `a` [INFO] [stdout] --> src/math.rs:444:26 [INFO] [stdout] | [INFO] [stdout] 444 | Expr::BinaryApp(f, a, b) => { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_a` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `b` [INFO] [stdout] --> src/math.rs:444:29 [INFO] [stdout] | [INFO] [stdout] 444 | Expr::BinaryApp(f, a, b) => { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_b` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `num_rows` [INFO] [stdout] --> src/perceptron.rs:25:9 [INFO] [stdout] | [INFO] [stdout] 25 | let num_rows: usize = x.rows(); [INFO] [stdout] | ^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_num_rows` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `f` [INFO] [stdout] --> src/math.rs:444:23 [INFO] [stdout] | [INFO] [stdout] 444 | Expr::BinaryApp(f, a, b) => { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_f` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `a` [INFO] [stdout] --> src/math.rs:444:26 [INFO] [stdout] | [INFO] [stdout] 444 | Expr::BinaryApp(f, a, b) => { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_a` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `b` [INFO] [stdout] --> src/math.rs:444:29 [INFO] [stdout] | [INFO] [stdout] 444 | Expr::BinaryApp(f, a, b) => { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_b` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `num_rows` [INFO] [stdout] --> src/SVM.rs:68:9 [INFO] [stdout] | [INFO] [stdout] 68 | let num_rows: usize = x.rows(); [INFO] [stdout] | ^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_num_rows` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `num_cols` [INFO] [stdout] --> src/SVM.rs:69:9 [INFO] [stdout] | [INFO] [stdout] 69 | let num_cols: usize = x.cols(); [INFO] [stdout] | ^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_num_cols` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `all_same` is assigned to, but never used [INFO] [stdout] --> src/DecisionTree.rs:101:13 [INFO] [stdout] | [INFO] [stdout] 101 | let mut all_same = true; [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: consider using `_all_same` instead [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: value assigned to `all_same` is never read [INFO] [stdout] --> src/DecisionTree.rs:105:9 [INFO] [stdout] | [INFO] [stdout] 105 | all_same = false; [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: maybe it is overwritten before being read? [INFO] [stdout] = note: `#[warn(unused_assignments)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Kernel` is never constructed [INFO] [stdout] --> src/matrix.rs:78:12 [INFO] [stdout] | [INFO] [stdout] 78 | pub struct Kernel { [INFO] [stdout] | ^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated items `new` and `eval` are never used [INFO] [stdout] --> src/matrix.rs:83:12 [INFO] [stdout] | [INFO] [stdout] 82 | impl Kernel { [INFO] [stdout] | ----------- associated items in this implementation [INFO] [stdout] 83 | pub fn new(kernel: Box f64>) -> Kernel { [INFO] [stdout] | ^^^ [INFO] [stdout] ... [INFO] [stdout] 89 | pub fn eval(&self, x: &ColVec, y: &ColVec) -> f64 { [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated functions `linear`, `polynomial`, and `rbf` are never used [INFO] [stdout] --> src/matrix.rs:95:12 [INFO] [stdout] | [INFO] [stdout] 94 | impl Kernel { [INFO] [stdout] | ----------- associated functions in this implementation [INFO] [stdout] 95 | pub fn linear() -> Kernel { [INFO] [stdout] | ^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 99 | pub fn polynomial(degree: i32) -> Kernel { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 103 | pub fn rbf(sigma: f64) -> Kernel { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `EigenSpace` is never constructed [INFO] [stdout] --> src/matrix.rs:279:12 [INFO] [stdout] | [INFO] [stdout] 279 | pub struct EigenSpace { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Perceptron` is never constructed [INFO] [stdout] --> src/perceptron.rs:6:12 [INFO] [stdout] | [INFO] [stdout] 6 | pub struct Perceptron { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated items `new`, `train`, and `predict` are never used [INFO] [stdout] --> src/perceptron.rs:22:10 [INFO] [stdout] | [INFO] [stdout] 10 | impl Perceptron { [INFO] [stdout] | --------------- associated items in this implementation [INFO] [stdout] ... [INFO] [stdout] 22 | pub fn new(x: Matrix, y: Matrix) -> Perceptron { [INFO] [stdout] | ^^^ [INFO] [stdout] ... [INFO] [stdout] 58 | fn train(&mut self, x: Matrix, y: Matrix, max_epochs: usize) { [INFO] [stdout] | ^^^^^ [INFO] [stdout] ... [INFO] [stdout] 110 | pub fn predict(&self, x: &Matrix) -> Matrix { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `n` is never used [INFO] [stdout] --> src/math.rs:633:8 [INFO] [stdout] | [INFO] [stdout] 633 | pub fn n(n: f64) -> Expr { [INFO] [stdout] | ^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `e` is never used [INFO] [stdout] --> src/math.rs:637:8 [INFO] [stdout] | [INFO] [stdout] 637 | pub fn e() -> Expr { [INFO] [stdout] | ^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `pi` is never used [INFO] [stdout] --> src/math.rs:641:8 [INFO] [stdout] | [INFO] [stdout] 641 | pub fn pi() -> Expr { [INFO] [stdout] | ^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `ln` is never used [INFO] [stdout] --> src/math.rs:645:8 [INFO] [stdout] | [INFO] [stdout] 645 | pub fn ln(x: Expr) -> Expr { [INFO] [stdout] | ^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `relu` is never used [INFO] [stdout] --> src/math.rs:649:8 [INFO] [stdout] | [INFO] [stdout] 649 | pub fn relu(x: Expr) -> Expr { [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `relu_prime` is never used [INFO] [stdout] --> src/math.rs:653:8 [INFO] [stdout] | [INFO] [stdout] 653 | pub fn relu_prime(x: Expr) -> Expr { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `max` is never used [INFO] [stdout] --> src/math.rs:657:8 [INFO] [stdout] | [INFO] [stdout] 657 | pub fn max(x: Expr, y: Expr) -> Expr { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `var` is never used [INFO] [stdout] --> src/math.rs:661:8 [INFO] [stdout] | [INFO] [stdout] 661 | pub fn var(v: &str) -> Expr { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: multiple variants are never constructed [INFO] [stdout] --> src/token.rs:3:3 [INFO] [stdout] | [INFO] [stdout] 2 | pub enum Token { [INFO] [stdout] | ----- variants in this enum [INFO] [stdout] 3 | LeftParen, [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] 4 | RightParen, [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] 5 | Num(f64), [INFO] [stdout] | ^^^ [INFO] [stdout] 6 | Add, [INFO] [stdout] | ^^^ [INFO] [stdout] 7 | Sub, [INFO] [stdout] | ^^^ [INFO] [stdout] 8 | Mul, [INFO] [stdout] | ^^^ [INFO] [stdout] 9 | Div, [INFO] [stdout] | ^^^ [INFO] [stdout] 10 | Pow, [INFO] [stdout] | ^^^ [INFO] [stdout] 11 | Var(String), [INFO] [stdout] | ^^^ [INFO] [stdout] 12 | Fun(FunctionToken), [INFO] [stdout] | ^^^ [INFO] [stdout] 13 | Const(ConstantToken) [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `str_to_fun` is never used [INFO] [stdout] --> src/token.rs:17:4 [INFO] [stdout] | [INFO] [stdout] 17 | fn str_to_fun(s: &str) -> Option { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `str_to_const` is never used [INFO] [stdout] --> src/token.rs:25:4 [INFO] [stdout] | [INFO] [stdout] 25 | fn str_to_const(s: &str) -> Option { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `FUNCTION_NAMES` is never used [INFO] [stdout] --> src/token.rs:33:7 [INFO] [stdout] | [INFO] [stdout] 33 | const FUNCTION_NAMES: [&str; 2] = ["ln", "relu"]; [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variants `Ln` and `ReLU` are never constructed [INFO] [stdout] --> src/token.rs:36:3 [INFO] [stdout] | [INFO] [stdout] 35 | pub enum FunctionToken { [INFO] [stdout] | ------------- variants in this enum [INFO] [stdout] 36 | Ln, [INFO] [stdout] | ^^ [INFO] [stdout] 37 | ReLU [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `lex_single_token` is never used [INFO] [stdout] --> src/token.rs:112:8 [INFO] [stdout] | [INFO] [stdout] 112 | pub fn lex_single_token(input: &[char]) -> (Token, &[char]) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `lex_tokens` is never used [INFO] [stdout] --> src/token.rs:171:8 [INFO] [stdout] | [INFO] [stdout] 171 | pub fn lex_tokens(input: &str) -> Vec { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `function_token_to_fun` is never used [INFO] [stdout] --> src/parser.rs:5:4 [INFO] [stdout] | [INFO] [stdout] 5 | fn function_token_to_fun(token: &FunctionToken) -> UnaryFun { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `parse_l5` is never used [INFO] [stdout] --> src/parser.rs:12:8 [INFO] [stdout] | [INFO] [stdout] 12 | pub fn parse_l5 (tokens: &[Token]) -> (Expr, &[Token]) { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `parse_l4` is never used [INFO] [stdout] --> src/parser.rs:34:4 [INFO] [stdout] | [INFO] [stdout] 34 | fn parse_l4(tokens: &[Token]) -> (Expr, &[Token]) { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `parse_l3` is never used [INFO] [stdout] --> src/parser.rs:57:4 [INFO] [stdout] | [INFO] [stdout] 57 | fn parse_l3(tokens: &[Token]) -> (Expr, &[Token]) { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `parse_l2` is never used [INFO] [stdout] --> src/parser.rs:74:4 [INFO] [stdout] | [INFO] [stdout] 74 | fn parse_l2(tokens: &[Token]) -> (Expr, &[Token]) { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `parse_l1` is never used [INFO] [stdout] --> src/parser.rs:93:4 [INFO] [stdout] | [INFO] [stdout] 93 | fn parse_l1 (tokens: &[Token]) -> (Expr, &[Token]) { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `KNN` is never constructed [INFO] [stdout] --> src/KNN.rs:8:12 [INFO] [stdout] | [INFO] [stdout] 8 | pub struct KNN { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated items `new`, `sort_labels_by_floats`, and `predict` are never used [INFO] [stdout] --> src/KNN.rs:23:10 [INFO] [stdout] | [INFO] [stdout] 14 | impl KNN { [INFO] [stdout] | -------- associated items in this implementation [INFO] [stdout] ... [INFO] [stdout] 23 | pub fn new(k: i32, x: Matrix, y: Matrix) -> KNN { [INFO] [stdout] | ^^^ [INFO] [stdout] ... [INFO] [stdout] 44 | fn sort_labels_by_floats(labels: Vec, distances: Vec) -> Vec { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 60 | pub fn predict(&self, x: Matrix) -> f64 { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `LinearRegression` is never constructed [INFO] [stdout] --> src/lr.rs:6:12 [INFO] [stdout] | [INFO] [stdout] 6 | pub struct LinearRegression { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated items `new_closed`, `new_optim`, and `predict` are never used [INFO] [stdout] --> src/lr.rs:19:10 [INFO] [stdout] | [INFO] [stdout] 13 | impl LinearRegression { [INFO] [stdout] | --------------------- associated items in this implementation [INFO] [stdout] ... [INFO] [stdout] 19 | pub fn new_closed(x: Matrix, y: Matrix) -> LinearRegression { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 71 | pub fn new_optim(x: Matrix, y: Matrix, lr: f64, iter: i32) -> LinearRegression { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 142 | pub fn predict(&self, x: Matrix) -> f64 { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Optim` is never constructed [INFO] [stdout] --> src/optim.rs:6:12 [INFO] [stdout] | [INFO] [stdout] 6 | pub struct Optim { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated items `new` and `optimize` are never used [INFO] [stdout] --> src/optim.rs:20:10 [INFO] [stdout] | [INFO] [stdout] 12 | impl Optim { [INFO] [stdout] | ---------- associated items in this implementation [INFO] [stdout] ... [INFO] [stdout] 20 | pub fn new(learning_rate: f64, max_iter: i32) -> Optim { [INFO] [stdout] | ^^^ [INFO] [stdout] ... [INFO] [stdout] 37 | pub fn optimize(&self, f: &Expr) -> ColVec { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `LogisticRegression` is never constructed [INFO] [stdout] --> src/logistic_regression.rs:3:12 [INFO] [stdout] | [INFO] [stdout] 3 | pub struct LogisticRegression { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated items `compute_loss_function`, `new`, `sigmoid`, and `predict` are never used [INFO] [stdout] --> src/logistic_regression.rs:11:6 [INFO] [stdout] | [INFO] [stdout] 10 | impl LogisticRegression { [INFO] [stdout] | ----------------------- associated items in this implementation [INFO] [stdout] 11 | fn compute_loss_function(x: Matrix, y: Matrix, lambda: f64) -> Expr { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 79 | pub fn new(x: Matrix, y: Matrix, lambda: f64) -> LogisticRegression { [INFO] [stdout] | ^^^ [INFO] [stdout] ... [INFO] [stdout] 109 | fn sigmoid(z: f64) -> f64 { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 113 | pub fn predict(&self, x: Matrix) -> f64 { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `SVM` is never constructed [INFO] [stdout] --> src/SVM.rs:3:12 [INFO] [stdout] | [INFO] [stdout] 3 | pub struct SVM { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated function `compute_loss_function` is never used [INFO] [stdout] --> src/SVM.rs:11:10 [INFO] [stdout] | [INFO] [stdout] 10 | impl SVM { [INFO] [stdout] | -------- associated function in this implementation [INFO] [stdout] 11 | pub fn compute_loss_function(x: Matrix, y: Matrix, C: f64) -> Expr { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated items `new` and `predict` are never used [INFO] [stdout] --> src/SVM.rs:63:10 [INFO] [stdout] | [INFO] [stdout] 61 | impl SVM { [INFO] [stdout] | -------- associated items in this implementation [INFO] [stdout] 62 | [INFO] [stdout] 63 | pub fn new (x: Matrix, y: Matrix, C: f64) -> SVM { [INFO] [stdout] | ^^^ [INFO] [stdout] ... [INFO] [stdout] 103 | pub fn predict(&self, x: Matrix) -> f64 { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `KernelPerceptron` is never constructed [INFO] [stdout] --> src/KernelPerceptron.rs:4:12 [INFO] [stdout] | [INFO] [stdout] 4 | pub struct KernelPerceptron { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated items `new` and `predict` are never used [INFO] [stdout] --> src/KernelPerceptron.rs:12:10 [INFO] [stdout] | [INFO] [stdout] 11 | impl KernelPerceptron { [INFO] [stdout] | --------------------- associated items in this implementation [INFO] [stdout] 12 | pub fn new(x: Matrix, y: ColVec, kernel: Kernel) -> KernelPerceptron { [INFO] [stdout] | ^^^ [INFO] [stdout] ... [INFO] [stdout] 87 | pub fn predict(&self, x: ColVec) -> f64 { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: module `KNN` should have a snake case name [INFO] [stdout] --> src/main.rs:14:5 [INFO] [stdout] | [INFO] [stdout] 14 | mod KNN; [INFO] [stdout] | ^^^ help: convert the identifier to snake case: `knn` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(non_snake_case)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: module `SVM` should have a snake case name [INFO] [stdout] --> src/main.rs:19:5 [INFO] [stdout] | [INFO] [stdout] 19 | mod SVM; [INFO] [stdout] | ^^^ help: convert the identifier to snake case: `svm` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: module `NN` should have a snake case name [INFO] [stdout] --> src/main.rs:20:5 [INFO] [stdout] | [INFO] [stdout] 20 | mod NN; [INFO] [stdout] | ^^ help: convert the identifier to snake case: `nn` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: module `KernelPerceptron` should have a snake case name [INFO] [stdout] --> src/main.rs:21:5 [INFO] [stdout] | [INFO] [stdout] 21 | mod KernelPerceptron; [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: convert the identifier to snake case: `kernel_perceptron` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: module `DecisionTree` should have a snake case name [INFO] [stdout] --> src/main.rs:22:5 [INFO] [stdout] | [INFO] [stdout] 22 | mod DecisionTree; [INFO] [stdout] | ^^^^^^^^^^^^ help: convert the identifier to snake case: `decision_tree` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `C` should have a snake case name [INFO] [stdout] --> src/SVM.rs:11:54 [INFO] [stdout] | [INFO] [stdout] 11 | pub fn compute_loss_function(x: Matrix, y: Matrix, C: f64) -> Expr { [INFO] [stdout] | ^ help: convert the identifier to snake case (notice the capitalization): `c` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `C` should have a snake case name [INFO] [stdout] --> src/SVM.rs:63:37 [INFO] [stdout] | [INFO] [stdout] 63 | pub fn new (x: Matrix, y: Matrix, C: f64) -> SVM { [INFO] [stdout] | ^ help: convert the identifier to snake case (notice the capitalization): `c` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `num_rows` [INFO] [stdout] --> src/SVM.rs:68:9 [INFO] [stdout] | [INFO] [stdout] 68 | let num_rows: usize = x.rows(); [INFO] [stdout] | ^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_num_rows` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `num_cols` [INFO] [stdout] --> src/SVM.rs:69:9 [INFO] [stdout] | [INFO] [stdout] 69 | let num_cols: usize = x.cols(); [INFO] [stdout] | ^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_num_cols` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `all_same` is assigned to, but never used [INFO] [stdout] --> src/DecisionTree.rs:101:13 [INFO] [stdout] | [INFO] [stdout] 101 | let mut all_same = true; [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: consider using `_all_same` instead [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: value assigned to `all_same` is never read [INFO] [stdout] --> src/DecisionTree.rs:105:9 [INFO] [stdout] | [INFO] [stdout] 105 | all_same = false; [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: maybe it is overwritten before being read? [INFO] [stdout] = note: `#[warn(unused_assignments)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Kernel` is never constructed [INFO] [stdout] --> src/matrix.rs:78:12 [INFO] [stdout] | [INFO] [stdout] 78 | pub struct Kernel { [INFO] [stdout] | ^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: 67 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated items `new` and `eval` are never used [INFO] [stdout] --> src/matrix.rs:83:12 [INFO] [stdout] | [INFO] [stdout] 82 | impl Kernel { [INFO] [stdout] | ----------- associated items in this implementation [INFO] [stdout] 83 | pub fn new(kernel: Box f64>) -> Kernel { [INFO] [stdout] | ^^^ [INFO] [stdout] ... [INFO] [stdout] 89 | pub fn eval(&self, x: &ColVec, y: &ColVec) -> f64 { [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated functions `linear`, `polynomial`, and `rbf` are never used [INFO] [stdout] --> src/matrix.rs:95:12 [INFO] [stdout] | [INFO] [stdout] 94 | impl Kernel { [INFO] [stdout] | ----------- associated functions in this implementation [INFO] [stdout] 95 | pub fn linear() -> Kernel { [INFO] [stdout] | ^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 99 | pub fn polynomial(degree: i32) -> Kernel { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 103 | pub fn rbf(sigma: f64) -> Kernel { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `EigenSpace` is never constructed [INFO] [stdout] --> src/matrix.rs:279:12 [INFO] [stdout] | [INFO] [stdout] 279 | pub struct EigenSpace { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Perceptron` is never constructed [INFO] [stdout] --> src/perceptron.rs:6:12 [INFO] [stdout] | [INFO] [stdout] 6 | pub struct Perceptron { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated items `new`, `train`, and `predict` are never used [INFO] [stdout] --> src/perceptron.rs:22:10 [INFO] [stdout] | [INFO] [stdout] 10 | impl Perceptron { [INFO] [stdout] | --------------- associated items in this implementation [INFO] [stdout] ... [INFO] [stdout] 22 | pub fn new(x: Matrix, y: Matrix) -> Perceptron { [INFO] [stdout] | ^^^ [INFO] [stdout] ... [INFO] [stdout] 58 | fn train(&mut self, x: Matrix, y: Matrix, max_epochs: usize) { [INFO] [stdout] | ^^^^^ [INFO] [stdout] ... [INFO] [stdout] 110 | pub fn predict(&self, x: &Matrix) -> Matrix { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `n` is never used [INFO] [stdout] --> src/math.rs:633:8 [INFO] [stdout] | [INFO] [stdout] 633 | pub fn n(n: f64) -> Expr { [INFO] [stdout] | ^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `e` is never used [INFO] [stdout] --> src/math.rs:637:8 [INFO] [stdout] | [INFO] [stdout] 637 | pub fn e() -> Expr { [INFO] [stdout] | ^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `pi` is never used [INFO] [stdout] --> src/math.rs:641:8 [INFO] [stdout] | [INFO] [stdout] 641 | pub fn pi() -> Expr { [INFO] [stdout] | ^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `ln` is never used [INFO] [stdout] --> src/math.rs:645:8 [INFO] [stdout] | [INFO] [stdout] 645 | pub fn ln(x: Expr) -> Expr { [INFO] [stdout] | ^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `relu` is never used [INFO] [stdout] --> src/math.rs:649:8 [INFO] [stdout] | [INFO] [stdout] 649 | pub fn relu(x: Expr) -> Expr { [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `relu_prime` is never used [INFO] [stdout] --> src/math.rs:653:8 [INFO] [stdout] | [INFO] [stdout] 653 | pub fn relu_prime(x: Expr) -> Expr { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `max` is never used [INFO] [stdout] --> src/math.rs:657:8 [INFO] [stdout] | [INFO] [stdout] 657 | pub fn max(x: Expr, y: Expr) -> Expr { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `var` is never used [INFO] [stdout] --> src/math.rs:661:8 [INFO] [stdout] | [INFO] [stdout] 661 | pub fn var(v: &str) -> Expr { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: multiple variants are never constructed [INFO] [stdout] --> src/token.rs:3:3 [INFO] [stdout] | [INFO] [stdout] 2 | pub enum Token { [INFO] [stdout] | ----- variants in this enum [INFO] [stdout] 3 | LeftParen, [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] 4 | RightParen, [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] 5 | Num(f64), [INFO] [stdout] | ^^^ [INFO] [stdout] 6 | Add, [INFO] [stdout] | ^^^ [INFO] [stdout] 7 | Sub, [INFO] [stdout] | ^^^ [INFO] [stdout] 8 | Mul, [INFO] [stdout] | ^^^ [INFO] [stdout] 9 | Div, [INFO] [stdout] | ^^^ [INFO] [stdout] 10 | Pow, [INFO] [stdout] | ^^^ [INFO] [stdout] 11 | Var(String), [INFO] [stdout] | ^^^ [INFO] [stdout] 12 | Fun(FunctionToken), [INFO] [stdout] | ^^^ [INFO] [stdout] 13 | Const(ConstantToken) [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `str_to_fun` is never used [INFO] [stdout] --> src/token.rs:17:4 [INFO] [stdout] | [INFO] [stdout] 17 | fn str_to_fun(s: &str) -> Option { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `str_to_const` is never used [INFO] [stdout] --> src/token.rs:25:4 [INFO] [stdout] | [INFO] [stdout] 25 | fn str_to_const(s: &str) -> Option { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `FUNCTION_NAMES` is never used [INFO] [stdout] --> src/token.rs:33:7 [INFO] [stdout] | [INFO] [stdout] 33 | const FUNCTION_NAMES: [&str; 2] = ["ln", "relu"]; [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variants `Ln` and `ReLU` are never constructed [INFO] [stdout] --> src/token.rs:36:3 [INFO] [stdout] | [INFO] [stdout] 35 | pub enum FunctionToken { [INFO] [stdout] | ------------- variants in this enum [INFO] [stdout] 36 | Ln, [INFO] [stdout] | ^^ [INFO] [stdout] 37 | ReLU [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `lex_single_token` is never used [INFO] [stdout] --> src/token.rs:112:8 [INFO] [stdout] | [INFO] [stdout] 112 | pub fn lex_single_token(input: &[char]) -> (Token, &[char]) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `lex_tokens` is never used [INFO] [stdout] --> src/token.rs:171:8 [INFO] [stdout] | [INFO] [stdout] 171 | pub fn lex_tokens(input: &str) -> Vec { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `function_token_to_fun` is never used [INFO] [stdout] --> src/parser.rs:5:4 [INFO] [stdout] | [INFO] [stdout] 5 | fn function_token_to_fun(token: &FunctionToken) -> UnaryFun { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `parse_l5` is never used [INFO] [stdout] --> src/parser.rs:12:8 [INFO] [stdout] | [INFO] [stdout] 12 | pub fn parse_l5 (tokens: &[Token]) -> (Expr, &[Token]) { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `parse_l4` is never used [INFO] [stdout] --> src/parser.rs:34:4 [INFO] [stdout] | [INFO] [stdout] 34 | fn parse_l4(tokens: &[Token]) -> (Expr, &[Token]) { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `parse_l3` is never used [INFO] [stdout] --> src/parser.rs:57:4 [INFO] [stdout] | [INFO] [stdout] 57 | fn parse_l3(tokens: &[Token]) -> (Expr, &[Token]) { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `parse_l2` is never used [INFO] [stdout] --> src/parser.rs:74:4 [INFO] [stdout] | [INFO] [stdout] 74 | fn parse_l2(tokens: &[Token]) -> (Expr, &[Token]) { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `parse_l1` is never used [INFO] [stdout] --> src/parser.rs:93:4 [INFO] [stdout] | [INFO] [stdout] 93 | fn parse_l1 (tokens: &[Token]) -> (Expr, &[Token]) { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `KNN` is never constructed [INFO] [stdout] --> src/KNN.rs:8:12 [INFO] [stdout] | [INFO] [stdout] 8 | pub struct KNN { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated items `new`, `sort_labels_by_floats`, and `predict` are never used [INFO] [stdout] --> src/KNN.rs:23:10 [INFO] [stdout] | [INFO] [stdout] 14 | impl KNN { [INFO] [stdout] | -------- associated items in this implementation [INFO] [stdout] ... [INFO] [stdout] 23 | pub fn new(k: i32, x: Matrix, y: Matrix) -> KNN { [INFO] [stdout] | ^^^ [INFO] [stdout] ... [INFO] [stdout] 44 | fn sort_labels_by_floats(labels: Vec, distances: Vec) -> Vec { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 60 | pub fn predict(&self, x: Matrix) -> f64 { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `LinearRegression` is never constructed [INFO] [stdout] --> src/lr.rs:6:12 [INFO] [stdout] | [INFO] [stdout] 6 | pub struct LinearRegression { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated items `new_closed`, `new_optim`, and `predict` are never used [INFO] [stdout] --> src/lr.rs:19:10 [INFO] [stdout] | [INFO] [stdout] 13 | impl LinearRegression { [INFO] [stdout] | --------------------- associated items in this implementation [INFO] [stdout] ... [INFO] [stdout] 19 | pub fn new_closed(x: Matrix, y: Matrix) -> LinearRegression { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 71 | pub fn new_optim(x: Matrix, y: Matrix, lr: f64, iter: i32) -> LinearRegression { [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 142 | pub fn predict(&self, x: Matrix) -> f64 { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `Optim` is never constructed [INFO] [stdout] --> src/optim.rs:6:12 [INFO] [stdout] | [INFO] [stdout] 6 | pub struct Optim { [INFO] [stdout] | ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated items `new` and `optimize` are never used [INFO] [stdout] --> src/optim.rs:20:10 [INFO] [stdout] | [INFO] [stdout] 12 | impl Optim { [INFO] [stdout] | ---------- associated items in this implementation [INFO] [stdout] ... [INFO] [stdout] 20 | pub fn new(learning_rate: f64, max_iter: i32) -> Optim { [INFO] [stdout] | ^^^ [INFO] [stdout] ... [INFO] [stdout] 37 | pub fn optimize(&self, f: &Expr) -> ColVec { [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `LogisticRegression` is never constructed [INFO] [stdout] --> src/logistic_regression.rs:3:12 [INFO] [stdout] | [INFO] [stdout] 3 | pub struct LogisticRegression { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated items `compute_loss_function`, `new`, `sigmoid`, and `predict` are never used [INFO] [stdout] --> src/logistic_regression.rs:11:6 [INFO] [stdout] | [INFO] [stdout] 10 | impl LogisticRegression { [INFO] [stdout] | ----------------------- associated items in this implementation [INFO] [stdout] 11 | fn compute_loss_function(x: Matrix, y: Matrix, lambda: f64) -> Expr { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 79 | pub fn new(x: Matrix, y: Matrix, lambda: f64) -> LogisticRegression { [INFO] [stdout] | ^^^ [INFO] [stdout] ... [INFO] [stdout] 109 | fn sigmoid(z: f64) -> f64 { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] ... [INFO] [stdout] 113 | pub fn predict(&self, x: Matrix) -> f64 { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `SVM` is never constructed [INFO] [stdout] --> src/SVM.rs:3:12 [INFO] [stdout] | [INFO] [stdout] 3 | pub struct SVM { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated function `compute_loss_function` is never used [INFO] [stdout] --> src/SVM.rs:11:10 [INFO] [stdout] | [INFO] [stdout] 10 | impl SVM { [INFO] [stdout] | -------- associated function in this implementation [INFO] [stdout] 11 | pub fn compute_loss_function(x: Matrix, y: Matrix, C: f64) -> Expr { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated items `new` and `predict` are never used [INFO] [stdout] --> src/SVM.rs:63:10 [INFO] [stdout] | [INFO] [stdout] 61 | impl SVM { [INFO] [stdout] | -------- associated items in this implementation [INFO] [stdout] 62 | [INFO] [stdout] 63 | pub fn new (x: Matrix, y: Matrix, C: f64) -> SVM { [INFO] [stdout] | ^^^ [INFO] [stdout] ... [INFO] [stdout] 103 | pub fn predict(&self, x: Matrix) -> f64 { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `KernelPerceptron` is never constructed [INFO] [stdout] --> src/KernelPerceptron.rs:4:12 [INFO] [stdout] | [INFO] [stdout] 4 | pub struct KernelPerceptron { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: associated items `new` and `predict` are never used [INFO] [stdout] --> src/KernelPerceptron.rs:12:10 [INFO] [stdout] | [INFO] [stdout] 11 | impl KernelPerceptron { [INFO] [stdout] | --------------------- associated items in this implementation [INFO] [stdout] 12 | pub fn new(x: Matrix, y: ColVec, kernel: Kernel) -> KernelPerceptron { [INFO] [stdout] | ^^^ [INFO] [stdout] ... [INFO] [stdout] 87 | pub fn predict(&self, x: ColVec) -> f64 { [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: module `KNN` should have a snake case name [INFO] [stdout] --> src/main.rs:14:5 [INFO] [stdout] | [INFO] [stdout] 14 | mod KNN; [INFO] [stdout] | ^^^ help: convert the identifier to snake case: `knn` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(non_snake_case)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: module `SVM` should have a snake case name [INFO] [stdout] --> src/main.rs:19:5 [INFO] [stdout] | [INFO] [stdout] 19 | mod SVM; [INFO] [stdout] | ^^^ help: convert the identifier to snake case: `svm` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: module `NN` should have a snake case name [INFO] [stdout] --> src/main.rs:20:5 [INFO] [stdout] | [INFO] [stdout] 20 | mod NN; [INFO] [stdout] | ^^ help: convert the identifier to snake case: `nn` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: module `KernelPerceptron` should have a snake case name [INFO] [stdout] --> src/main.rs:21:5 [INFO] [stdout] | [INFO] [stdout] 21 | mod KernelPerceptron; [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: convert the identifier to snake case: `kernel_perceptron` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: module `DecisionTree` should have a snake case name [INFO] [stdout] --> src/main.rs:22:5 [INFO] [stdout] | [INFO] [stdout] 22 | mod DecisionTree; [INFO] [stdout] | ^^^^^^^^^^^^ help: convert the identifier to snake case: `decision_tree` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `C` should have a snake case name [INFO] [stdout] --> src/SVM.rs:11:54 [INFO] [stdout] | [INFO] [stdout] 11 | pub fn compute_loss_function(x: Matrix, y: Matrix, C: f64) -> Expr { [INFO] [stdout] | ^ help: convert the identifier to snake case (notice the capitalization): `c` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `C` should have a snake case name [INFO] [stdout] --> src/SVM.rs:63:37 [INFO] [stdout] | [INFO] [stdout] 63 | pub fn new (x: Matrix, y: Matrix, C: f64) -> SVM { [INFO] [stdout] | ^ help: convert the identifier to snake case (notice the capitalization): `c` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: 66 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Finished `dev` profile [unoptimized + debuginfo] target(s) in 7.13s [INFO] running `Command { std: "docker" "inspect" "9ff85893cd7ac3269daaf4cb95af5df022b60fb9ed72103df5a9960a9df6b54a", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "9ff85893cd7ac3269daaf4cb95af5df022b60fb9ed72103df5a9960a9df6b54a", kill_on_drop: false }` [INFO] [stdout] 9ff85893cd7ac3269daaf4cb95af5df022b60fb9ed72103df5a9960a9df6b54a