Streaming Model Transformations by Complex Event Processing
1. Budapest University of Technology and Economics
Fault Tolerant Systems Research Group
Streaming Model Transformationsby Complex Event Processing
IstvánDávid1,2, IstvánRáth2, DánielVarró2,3
davidi@inf.mit.bme.hu
1Currently at the University of Antwerp, Belgium
2Budapest University of Technology and Economics, Hungary
3Université de Montréal, Canada & McGill University, Canada
2. Motivation
Scalability is a key challenge in the state-of-the-art
Streaming models and transformations
oNative (or natural) streams
oArtificial (generated) streams
oStreaming transformations for live models
•Rapidly changing models
“aspecialkindoftransformationinwhichthewholeinputmodelisnotcompletelyavailableatthebeginningofthetransformation,butitiscontinuouslygenerated”
SánchezCuadrado,J.,Lara,J.:Streamingmodeltransformations: Scenarios,challengesandinitialsolutions(2013)InDuddy,K., Kappel,G.,eds.:TheoryandPracticeofModelTransformations. Volume7909ofLectureNotesinComputerScience.SpringerBerlinHeidelberg(2013)116
3. Motivation
Scalability is a key challenge in the state-of-the-art
Streaming models and transformations
oNative (or natural) streams
oArtificial (generated) streams
oStreaming transformations for live models
•Rapidly changing models
4. Gesture recognition by live models
HW/SW stack for optical input: Kinect+jnect
Objectives
Capture postures
Identify gesturesas series of postures
Define actions(transformations) on gestures
5. Gesture recognition by live models
HW/SW stack for optical input: Kinect+jnect
Objectives
Capture postures
Identify gesturesas series of postures
Define actions(transformations) on gestures
A live model in the background @25FPS
6. Gesture recognition by live models
HW/SW stack for optical input: Kinect+jnect
Objectives
Capture postures
Identify gesturesas series of postures
Define actions(transformations) on gestures
A live model in the background @25FPS
Streaming model == Stream of change events
7. Contributions
Language for Streaming MT
•Complex Event Processing Language
•Streaming Transformation Rules
Runtime for Streaming MT
•Execution semantics
•Prototype tooling
Feasibility study
•Case study
•Experimental evaluation
8. Contributions
Language for Streaming MT
•Complex Event Processing Language
•Streaming Transformation Rules
Runtime for Streaming MT
•Execution semantics
•Prototype tooling
Feasibility study
•Case study
•Experimental evaluation
14. Structural Model Changes
Violates well-formednessconstraint (captured by a graph pattern: „circular”)
circular()
15. Structural Model Changes
Violates well-formednessconstraint (captured by a graph pattern: „circular”)
circular()
Remove a generalization (ANY)
16. Structural Model Changes
Change-driven transformations (CDT): react to compound changes
Violates well-formednessconstraint (captured by a graph pattern: „circular”)
circular()
Remove a generalization (ANY)
17. Structural Model Changes
Violates well-formednessconstraint (captured by a graph pattern: „circular”)
Remove the LASTgeneralization
circular()
Remove a generalization (ANY)
Change-driven transformations (CDT): react to compound changes
21. Change Events
newGen(A, B)
->newGen(B, C)
->newGen(C, A)
Complex event: specific sequence of atomic events
22. Change Events
newGen(A, B)
->newGen(B, C)
->newGen(C, A)
Complex event: specific sequence of atomic events
23. Change Events
newGen(A, B)
->newGen(B, C)
->newGen(C, A)
Complex event: specific sequence of atomic events
Remove the LASTgeneralization
24. A key issue
newGen(A, B)
->newGen(B, C)
->newGen(C, A)
How to detect more complex change events?
25. A key issue
newGen(A, B)
-> newGen(B, C)
-> newGen(C, A)
How to detect more complex change events?
26. A key issue
->
newGen(B, C) ->
newGen(C, A)
newGen(A, B)
->…
…
…
-> newGen(C, A)
How to detect more complex change events?
Too many atomic events to process in the execution phase
Too many events to work with in design phase
It would be nice to “pre-filter” the events to work with
28. Streaming transformations by CEP
Use also compound changesin complex event sequences!
newGen(A, B)
->…
…
…
-> newGen(C, A)
circular()
newGen(x, A)
->circular(A)
29. Streaming transformations by CEP
Use also compound changesin complex event sequences!
newGen(x, A)
->circular(A)
30. Streaming transformations by CEP
Use also compound changesin complex event sequences!
newGen(x, A)
->circular(A)
31. Streaming transformations by CEP
newGen(x, A)
->circular(A)
Use also compound changesin complex event sequences!
32. Gesture recognition by live models
HW/SW stack for optical input: Kinect+jnect
Objectives
Capture postures
Identify gesturesas series of postures
Define actions(transformations) on gestures
Graph patterns
Complex event patterns
33. Gesture recognition by live models
HW/SW stack for optical input: Kinect+jnect
Objectives
Capture postures
Identify gesturesas series of postures
Define actions(transformations) on gestures
Graph patterns
Complex event patterns
http://bit.ly/eclipsecon-kinect
34. Analogy
State space spanned by the model snapshots
„Step” to next snapshot (length 1)
35. Analogy
State space spanned by the model snapshots
„Jump” to an arbitrary snapshot (length n)
36. Analogy
State space spanned by the model snapshots
„Walk” of steps
„Walk” of
steps+ jumps
37. Contributions
Language for Streaming MT
•Complex Event Processing Language
•Streaming Transformation Rules
Runtime for Streaming MT
•Execution semantics
•Prototype tooling
Feasibility study
•Case study
•Experimental evaluation
44. Contributions
Language for Streaming MT
•Complex Event Processing Language
•Streaming Transformation Rules
Runtime for Streaming MT
•Execution semantics
•Prototype tooling
Feasibility study
•Case study
•Experimental evaluation
45. Performance assessment
Stress test
o2.9GHz processor, 4GB RAM
oThe theoretical upper limit of processing performance
•Events should be processed faster than the new ones are generated
•Otherwise the system would saturate
EVENT STREAM
VIATRA-CEP
replay
Graph patterns, complex event patterns
46. Performance assessment
Stress test
o2.9GHz processor, 4GB RAM
oThe theoretical upper limit of processing performance
•Events should be processed faster than the new ones are generated
•Otherwise the system would saturate
EVENT STREAM
VIATRA-CEP
replay
Graph patterns, complex event patterns
-theoreticalupperlimit:24bodies
-approximately24000complexevents/sec
-approximately150000atomicevents/sec