tweaks
This commit is contained in:
@@ -43,14 +43,14 @@ async fn main()->Result<(),Error>{
|
||||
}
|
||||
impl std::fmt::Display for FoldState{
|
||||
fn fmt(&self,f:&mut std::fmt::Formatter<'_>)->std::fmt::Result{
|
||||
write!(f,"count={} jumps={} duration={} settings={}",self.count,self.jumps,self.duration as f64/(ONE_SECOND as f64),self.settings)
|
||||
write!(f,"count={} jumps={} duration={:.3} settings={}",self.count,self.jumps,self.duration as f64/(ONE_SECOND as f64),self.settings)
|
||||
}
|
||||
}
|
||||
impl FoldState{
|
||||
fn accumulate(&mut self,path:&Path,block:&v0::Block){
|
||||
if let (Some(first),Some(last))=(block.output_events.first(),block.output_events.last()){
|
||||
let last=last.time*(ONE_SECOND as f64);
|
||||
let first=first.time*(ONE_SECOND as f64);
|
||||
let last=last.time*ONE_SECOND as f64;
|
||||
let first=first.time*ONE_SECOND as f64;
|
||||
let duration=last as u64-first as u64;
|
||||
if 30000*ONE_SECOND<duration{
|
||||
self.outliers.push(path.to_owned());
|
||||
|
||||
Reference in New Issue
Block a user