Skip to content

Commit

Permalink
Add number of splats to CLI
Browse files Browse the repository at this point in the history
  • Loading branch information
ArthurBrussee committed Feb 11, 2025
1 parent 9316ca4 commit 6e9739c
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion crates/brush-cli/src/ui.rs
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,12 @@ pub async fn process_ui(process: RunningProcess) {
]),
);

let stats_spinner = ProgressBar::new_spinner().with_style(
ProgressStyle::with_template("{spinner:.blue} {msg}")
.expect("Invalid indicatif config")
.tick_strings(&["ℹ️", "ℹ️"]),
);

let eval_spinner = ProgressBar::new_spinner().with_style(
ProgressStyle::with_template("{spinner:.blue} {msg}")
.expect("Invalid indicatif config")
Expand All @@ -53,6 +59,7 @@ pub async fn process_ui(process: RunningProcess) {
let main_spinner = sp.add(main_spinner);
let train_progress = sp.add(train_progress);
let eval_spinner = sp.add(eval_spinner);
let stats_spinner = sp.add(stats_spinner);

main_spinner.enable_steady_tick(Duration::from_millis(120));

Expand All @@ -61,6 +68,8 @@ pub async fn process_ui(process: RunningProcess) {
process.start_args.process_config.eval_every,
));

stats_spinner.set_message("Starting up");

if cfg!(debug_assertions) {
let _ =
sp.println("ℹ️ running in debug mode, compile with --release for best performance");
Expand Down Expand Up @@ -105,13 +114,14 @@ pub async fn process_ui(process: RunningProcess) {
main_spinner.set_message("Dataset loaded");
}
ProcessMessage::TrainStep {
splats: _,
splats,
stats: _,
iter,
timestamp: _,
} => {
main_spinner.set_message("Training");
train_progress.set_position(iter as u64);
stats_spinner.set_message(format!("Current splat count {}", splats.num_splats()));
// Progress bar.
}
ProcessMessage::RefineStep { .. } => {
Expand Down

0 comments on commit 6e9739c

Please sign in to comment.