Database Reference
In-Depth Information
</Action>
</Event_VectorMagnitude_Classification_high>
</Cycling_Events>
It is also necessary to support the use of functions to explicitly define complex
algorithms, the results of which can be used as part of the condition. Example 2
shows the result of a function FnVectorMagnitude (which detects the direction
and force of the power produced by the cyclist, allowing for the detection of
the part of the pedal stroke at a given point in time) being used as part of
the condition. In effect, we treat the output from the sensor and function in an
identical manner. We support operators EQ, LT (less-than), GT, GE (greater-
than-or-equal-to) and GT. The action is always an update of a sensor data file.
A simple user interface to define events means that the user is only required is
to select from the list of sensors or functions; the relevant properties, decide on
the criteria for satisfying an occurance of an event, and define what to update.
Functions allow advanced algorithms to be applied which could not have been
applied using XQuery alone.
4 Experiments and Evaluation
Experiments were run on identical servers with a 2.66GHz Intel Core2 Duo CPU
and 4GB of RAM. The aim of the experiments is to compare query times on
the contextually enriched data with equivalent queries on data which is only
structurally enriched. We also measure the time taken for the once-off contex-
tual enrichment, and illustrate the comparitive ease of querying for the encoded
domain events.
Table 2. Sample Event Detection Execution times
Filename (Event)
Size Values Enabled Enriched Result Size
1 wickm.xml (Strong Cadence)
3MB 17,798
178ms
82ms
2,111
2 raim.xml (Strong Cadence)
30MB 65,536
399ms
150ms
7,631
3 wickm.xml (Low Vector Magnitude) 3MB 17,798
n/a
104ms
5,652
4 raim.xml (Low Vector Magnitude)
30MB 65,536
n/a
374ms
29,490
5 wickgps.xml (Steep Climb Terrain)
150kb 655
77ms
75ms
49
A summary of the experiments is presented in Table 2. Two accelerometer
sensor data files were queried to detect all occurences of a low vector magnitude,
and all occurences of a strong cadence. This was performed twice to detect the
cadence, once on the enabled data, where the cadence requirement is included
as part of an XQuery expression, and secondly the query is performed following
contextual enrichment, using a simple XQuery expression to detect occurences
of a strong cadence.
Due to its complex nature, the algorithm for Vector Magnitude cannot be
queried using XQuery and thus, the query for low vector magnitude was per-
formed on the contextually enriched data only. We chose two files to query, one
 
Search WWH ::




Custom Search