[med-svn] [aghermann] 59/60: comments, whitespace, ICM
andrei zavada
hmmr-guest at alioth.debian.org
Mon Nov 4 23:50:02 UTC 2013
This is an automated email from the git hooks/post-receive script.
hmmr-guest pushed a commit to branch WIP
in repository aghermann.
commit f1c65e655593d5fcdb969b8bcddddf91ba388a1c
Author: Andrei Zavada <hmmr at ra>
Date: Tue Nov 5 01:48:28 2013 +0200
comments, whitespace, ICM
---
upstream/src/aghermann/expdesign/recording.hh | 6 +++---
upstream/src/aghermann/expdesign/subject.hh | 2 --
upstream/src/aghermann/rk1968/rk1968.hh | 4 ++--
upstream/src/aghermann/ui/sf/d/rk1968.cc | 2 +-
upstream/src/libmetrics/psd.hh | 16 ++++++++--------
upstream/src/libsigfile/page.cc | 16 ++++++++--------
6 files changed, 22 insertions(+), 24 deletions(-)
diff --git a/upstream/src/aghermann/expdesign/recording.hh b/upstream/src/aghermann/expdesign/recording.hh
index 2254e93..a67af4e 100644
--- a/upstream/src/aghermann/expdesign/recording.hh
+++ b/upstream/src/aghermann/expdesign/recording.hh
@@ -4,7 +4,7 @@
* Author: Andrei Zavada <johnhommer at gmail.com>
* Initial version: 2012-08-26
*
- * Purpose: experimental design primary classes: CRecording,
+ * Purpose: experimental design primary classes: CRecording
*
* License: GPL
*/
@@ -184,10 +184,10 @@ class CRecording {
// actual page counts based on actual edf samples
size_t
- total_pages() const
+ total_pages() const // this is actually 'full'
{ return _source().recording_time() / pagesize(); }
size_t
- full_pages() const
+ full_pages() const // please swap names with 'total_pages'
{ return round(_source().recording_time() / pagesize()); }
size_t
total_samples() const
diff --git a/upstream/src/aghermann/expdesign/subject.hh b/upstream/src/aghermann/expdesign/subject.hh
index aec343e..53fb96f 100644
--- a/upstream/src/aghermann/expdesign/subject.hh
+++ b/upstream/src/aghermann/expdesign/subject.hh
@@ -45,8 +45,6 @@ struct SEpisode {
time_t start_time() const { return sources.front()().start_time(); }
time_t end_time() const { return sources.front()().end_time(); }
- time_t start_time() { return sources.front()().start_time(); }
- time_t end_time() { return sources.front()().end_time(); }
time_t start_rel, // relative to start_time
end_rel;
diff --git a/upstream/src/aghermann/rk1968/rk1968.hh b/upstream/src/aghermann/rk1968/rk1968.hh
index 280f7f6..b54469a 100644
--- a/upstream/src/aghermann/rk1968/rk1968.hh
+++ b/upstream/src/aghermann/rk1968/rk1968.hh
@@ -9,8 +9,8 @@
* License: GPL
*/
-#ifndef AGH_AGHERMANN_RK1968_H_
-#define AGH_AGHERMANN_RK1968_H_
+#ifndef AGH_AGHERMANN_RK1968_RK1968_H_
+#define AGH_AGHERMANN_RK1968_RK1968_H_
#include <float.h>
#include <string>
diff --git a/upstream/src/aghermann/ui/sf/d/rk1968.cc b/upstream/src/aghermann/ui/sf/d/rk1968.cc
index 6281ae7..7f5ef41 100644
--- a/upstream/src/aghermann/ui/sf/d/rk1968.cc
+++ b/upstream/src/aghermann/ui/sf/d/rk1968.cc
@@ -18,7 +18,7 @@ SScoringFacility::SRK1968Dialog&
SScoringFacility::
rk1968_d()
{
- if ( not _rk1968_d )
+ if ( !_rk1968_d )
_rk1968_d = new SRK1968Dialog(*this);
return *_rk1968_d;
}
diff --git a/upstream/src/libmetrics/psd.hh b/upstream/src/libmetrics/psd.hh
index dbeb08d..c6c58c9 100644
--- a/upstream/src/libmetrics/psd.hh
+++ b/upstream/src/libmetrics/psd.hh
@@ -75,10 +75,10 @@ struct SPPack
{ reset(); }
bool
- same_as( const SPPack& rv) const
+ same_as( const SPPack& rv) const
{ return metrics::SPPack::same_as(rv); }
void
- make_same( const SPPack& rv)
+ make_same( const SPPack& rv)
{ metrics::SPPack::make_same(rv); }
size_t
@@ -86,7 +86,7 @@ struct SPPack
{ return (samplerate * pagesize + 1) / 2 / samplerate / binsize; }
void
- check() const
+ check() const
{
metrics::SPPack::check();
@@ -114,7 +114,7 @@ struct SPPack
}
void
- reset()
+ reset()
{
metrics::SPPack::reset();
binsize = .25;
@@ -132,18 +132,18 @@ class CProfile
CProfile (const sigfile::CTypedSource&, int sig_no,
const SPPack&);
- SPPack Pp;
+ SPPack Pp;
const char*
- metric_name() const
+ metric_name() const
{ return metrics::name( TType::psd); }
// in a frequency range
valarray<TFloat>
- course( double from, double upto) const
+ course( double from, double upto) const
{
valarray<TFloat> acc (0., steps());
- size_t bin_a = min( (size_t)(from / Pp.binsize), _bins),
+ size_t bin_a = min( (size_t)(from / Pp.binsize), _bins),
bin_z = min( (size_t)(upto / Pp.binsize), _bins);
for ( size_t b = bin_a; b < bin_z; ++b )
acc += metrics::CProfile::course(b);
diff --git a/upstream/src/libsigfile/page.cc b/upstream/src/libsigfile/page.cc
index cd142d5..15d9f1c 100644
--- a/upstream/src/libsigfile/page.cc
+++ b/upstream/src/libsigfile/page.cc
@@ -43,20 +43,20 @@ percent_scored( float *nrem_p, float *rem_p, float *wake_p) const
{
if ( nrem_p )
*nrem_p = (float)count_if(
- _pages.begin(), _pages.end(),
- mem_fun_ref (&SPage::is_nrem)) / _pages.size() * 100;
+ _pages.begin(), _pages.end(),
+ mem_fun_ref (&SPage::is_nrem)) / _pages.size() * 100;
if ( rem_p )
*rem_p = (float)count_if(
- _pages.begin(), _pages.end(),
- mem_fun_ref (&SPage::is_rem)) / _pages.size() * 100;
+ _pages.begin(), _pages.end(),
+ mem_fun_ref (&SPage::is_rem)) / _pages.size() * 100;
if ( wake_p )
*wake_p = (float)count_if(
- _pages.begin(), _pages.end(),
- mem_fun_ref (&SPage::is_wake)) / _pages.size() * 100;
+ _pages.begin(), _pages.end(),
+ mem_fun_ref (&SPage::is_wake)) / _pages.size() * 100;
return (float)count_if(
- _pages.begin(), _pages.end(),
- mem_fun_ref (&SPage::is_scored)) / _pages.size() * 100;
+ _pages.begin(), _pages.end(),
+ mem_fun_ref (&SPage::is_scored)) / _pages.size() * 100;
}
--
Alioth's /git/debian-med/git-commit-notice on /srv/git.debian.org/git/debian-med/aghermann.git
More information about the debian-med-commit
mailing list