From 4191215284cd3dd9c4c538004bd29b58ef336a10 Mon Sep 17 00:00:00 2001 From: Roope Salmi Date: Sun, 16 May 2021 16:11:20 +0300 Subject: [PATCH] Hio koodidokumentaatiota --- src/correlation_match.rs | 2 +- src/display.rs | 4 +++- suorituskyky/plot_parametrized_comparison.py | 0 3 files changed, 4 insertions(+), 2 deletions(-) mode change 100755 => 100644 suorituskyky/plot_parametrized_comparison.py diff --git a/src/correlation_match.rs b/src/correlation_match.rs index f33f39e..e94242b 100644 --- a/src/correlation_match.rs +++ b/src/correlation_match.rs @@ -62,7 +62,7 @@ impl CorrelationMatch { /// the period of the signal is also returned as the second item in the tuple. This can be used /// to compute the fundamental frequency of the signal. /// - /// All arrays must be less than the maximum size given on `new`. + /// No array should exceed the maximum size given on `new`. pub fn compute(&mut self, a: &[Num], b: &[Num], w: &[Num]) -> (Num, Option) { assert!(a.len() <= self.max_size); assert!(b.len() <= a.len()); diff --git a/src/display.rs b/src/display.rs index 6278483..cea70de 100644 --- a/src/display.rs +++ b/src/display.rs @@ -83,7 +83,9 @@ impl DisplayBuffer { /// /// The `memory_decay` and `period_decay` parameters determine the decay coefficient of the /// memory buffer, and the interval average respectively: - /// `average = coeff * new + (1. - coeff) * average;` + /// ```none + /// average = coeff * new + (1. - coeff) * average; + /// ``` /// Set to `1.0` to bypass smoothing. /// /// [`update_display`](Self::update_display) should be called separately to update the display buffer. diff --git a/suorituskyky/plot_parametrized_comparison.py b/suorituskyky/plot_parametrized_comparison.py old mode 100755 new mode 100644