sync_opti_active.cpp File Reference

Functions to sync optical and passive data with active_wire system. More...

#include "postprocess.h"
#include <algorithm>
Include dependency graph for sync_opti_active.cpp:

Functions

bool IsOdd (const vector< double > i)
int sync_opti_active (vector< vector< double > > &active_wire_data, vector< vector< double > > &optical_data, int num_opti_markers)
 Sync optical data with active_wire system.
int filter_sync_passive_active (vector< vector< double > > active_wire_data, vector< vector< double > > &passive_wire_data)
 Filter and sync passive wire data with active wire data.
double adj_labview_tmstamp (double tmstamp)
 Change from Labview epoch to UTC epoch.

Detailed Description

Functions to sync optical and passive data with active_wire system.


Function Documentation

double adj_labview_tmstamp ( double  tmstamp)

Change from Labview epoch to UTC epoch.

Labview uses a different epoch for timestamps unlike UTC/Unix timestamps. This functions adjusts the Labview timestamps by adding the UTC value of the epoch 1/1/1904, 0:0:0 to Labview value.

Parameters:
[in,out]tmpstampNumber of seconds elapsed since epoch

Referenced by load_passive_data().

Here is the caller graph for this function:

int filter_sync_passive_active ( vector< vector< double > >  active_wire_data,
vector< vector< double > > &  passive_wire_data 
)

Filter and sync passive wire data with active wire data.

Change the timestamps from Labview format to UTC time, filter out the noise and discard all data taken before active_wire system has begun, and downsample from 1Khz to approx 100 Hz (synchronizing with active data)

Parameters:
[in]active_wire_dataActive wire data needed to synchronize passive data
[in,out]passive_wire_dataPassive wire data to remove spurious noise.

References extract_data_point(), and gsl_low_pass_filter_data().

Referenced by load_all_measures().

Here is the call graph for this function:

Here is the caller graph for this function:

bool IsOdd ( const vector< double >  i)

Referenced by sync_opti_active().

Here is the caller graph for this function:

int sync_opti_active ( vector< vector< double > > &  active_wire_data,
vector< vector< double > > &  optical_data,
int  num_opti_markers 
)

Sync optical data with active_wire system.

Active wire system has relatively low levels of measurement noise. Hence it is quite suitable for syncing optical data. This function would ideally perform best when used with readings of active wire 1,3 or 4. Function to be run before assigning optical data vector to tibia or femur structures

References first_local_extrema_vec(), IsOdd(), and opti_first_extrema().

Referenced by load_all_measures().

Here is the call graph for this function:

Here is the caller graph for this function:

 All Data Structures Files Functions Variables Typedefs Defines