Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions components/segmenter/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ icu_locale = { workspace = true, optional = true }

[dev-dependencies]
icu = { path = "../../components/icu", default-features = false }
icu_benchmark_macros = { path = "../../tools/benchmark/macros" }
icu_locale_core = { workspace = true }
icu_properties = { path = "../properties", features = ["compiled_data"] }
itertools = { workspace = true }
Expand Down
10 changes: 7 additions & 3 deletions components/segmenter/examples/experimental_segmenter.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@
// called LICENSE at the top level of the ICU4X source tree
// (online at: https://github.com/unicode-org/icu4x/blob/main/LICENSE ).

#![no_main] // https://github.com/unicode-org/icu4x/issues/395
icu_benchmark_macros::instrument!();
use icu_benchmark_macros::println;

#[path = "../tests/adaboost/main.rs"]
mod adaboost;

Expand Down Expand Up @@ -29,7 +33,7 @@ fn main_adaboost(args: &[String]) {
print!("{}|", &s[prev..breakpoint]);
prev = breakpoint;
}
println!();
println!("");
println!("{} repetitions done in: {:?}", REPETITIONS, elapsed);
}

Expand Down Expand Up @@ -63,7 +67,7 @@ fn main_cnn(args: &[String]) {
print!("{}|", &s[prev..breakpoint]);
prev = breakpoint;
}
println!();
println!("");
println!("{} repetitions done in: {:?}", REPETITIONS, elapsed);
}

Expand All @@ -90,7 +94,7 @@ fn run_word_segmenter(segmenter: WordSegmenterBorrowed, s: &str) {
print!("{}|", &s[prev..breakpoint]);
prev = breakpoint;
}
println!();
println!("");
println!("{} repetitions done in: {:?}", REPETITIONS, elapsed);
}

Expand Down
Loading