Compare commits
2 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
638be9a256
|
|||
|
8ea487a72a
|
@@ -43,15 +43,16 @@ async fn main()->Result<(),Error>{
|
||||
const ONE_SECOND:u64=1<<32;
|
||||
#[derive(Default)]
|
||||
struct FoldState{
|
||||
count:usize,
|
||||
count:u64,
|
||||
jumps:u64,
|
||||
duration:u64,
|
||||
settings:u64,
|
||||
absolute_sens:u64,
|
||||
outliers:Vec<PathBuf>,
|
||||
}
|
||||
impl std::fmt::Display for FoldState{
|
||||
fn fmt(&self,f:&mut std::fmt::Formatter<'_>)->std::fmt::Result{
|
||||
write!(f,"count={} jumps={} duration={:.3} settings={}",self.count,self.jumps,self.duration as f64/(ONE_SECOND as f64),self.settings)
|
||||
write!(f,"count={} jumps={} duration={:.3} settings={} absolute_sens={}",self.count,self.jumps,self.duration as f64/(ONE_SECOND as f64),self.settings,self.absolute_sens)
|
||||
}
|
||||
}
|
||||
impl FoldState{
|
||||
@@ -76,6 +77,9 @@ async fn main()->Result<(),Error>{
|
||||
.filter(|event|run_start.time<event.time)
|
||||
.count() as u64;
|
||||
}
|
||||
if let Some(_setting)=block.setting_events.iter().find(|event|matches!(event.event.setting_type,v0::SettingType::AbsoluteSensitivity)&&event.event.value==1.0){
|
||||
self.absolute_sens+=1;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user