diff --git a/Cargo.toml b/Cargo.toml index 2c1f4e1..b70ffbe 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -8,5 +8,7 @@ edition = "2021" [dependencies] clap = { version = "4.4.8", features = ["derive"]} derive_builder = "0.12.0" +rand = "0.8.5" +rand_distr = "0.4.3" serde = { version = "1.0.192", features = ["derive"]} toml = "0.8.8" diff --git a/Makefile b/Makefile index 99401c9..e7d47c8 100644 --- a/Makefile +++ b/Makefile @@ -2,7 +2,7 @@ check: cargo check run: - cargo run -- params.toml 2>/dev/null | python3 scripts/format.py + @cargo run -- params.toml 2>/dev/null | python3 scripts/format.py debug: cargo run -- params.toml diff --git a/params.toml b/params.toml index f360d24..4488db3 100644 --- a/params.toml +++ b/params.toml @@ -91,3 +91,7 @@ [types.gen_tuple] gen_each_field = 0.5 get_instant = 0.5 + +[dev] + float_gen_distro_pos_stddiv = 56713724e30 # DO NOT expand with zeros + float_gen_distro_neg_stddiv = 56713724e30 diff --git a/src/params.rs b/src/params.rs index c4c62e8..271b410 100644 --- a/src/params.rs +++ b/src/params.rs @@ -18,6 +18,7 @@ toml_struct!{ global_flow: GlobalFlow, statements: Statments, types: Types, + dev: Dev, } } @@ -149,6 +150,13 @@ toml_struct!{ } } +toml_struct!{ + struct Dev { + float_gen_distro_pos_stddiv: f32, + float_gen_distro_neg_stddiv: f32, + } +} + impl Params { pub fn parse(p: &PathBuf) -> Self { let file_string = fs::read_to_string(p)