Seminar Model Driven Software Engineering What is it? Topics Requirements Schedule Contact
„Model-based Software Development“, A famous painting by René Magritte
„Model-based Software Development“, Systems versus Modells The image (model) captures important properties and lets us reason about appeareance functions usability etc But with an image (model) we cannot smoke. isModelOf A system A model conformsTo
„Model-based Software Development“, Modells Represent Views of a System Termite population in France The System Models France 1453 French cheese map Railroads in France
„Model-based Software Development“, Metamodels explain Models How do we know what a map tells us? The „Legend“ explains the used symbols „Bicycle Lane“ …… The „Legend“ is the „metamodel“ of the map Metamodels model the language of models Elements & their legal use syntax Meaning of elements semantics
„Model-based Software Development“, Meta-Models The „Image of an image of an image“ is a meta-metamodel One could go on like this forever… The „image of an image of a pipe“ is a modell of a model – a metamodell It captures aspects of images Frame, contents, label, … The „image of a pipe“ is a model of the system It captures aspects of pipes Shape, colour,... The pipe is real – a system. modelOf
„Model-based Software Development“, The UML Metamodell ClassAttribute * 1 A UML-Model Spy Name : String The (Meta-)Modell-Pyramid M2M2 M1M1 Meta-Object-Facility Class Association source destination M3M3 conforms to A System („the real world“) MOF (Meta-Object-Facility) (model of UML metamodels) UML Metamodel (Model of UML models) UML Model (Model of a system) M0M0 My Name is... conforms to M0M0 M1M1 M2M2 M3M3
„Model-based Software Development“, Domain Specific Language (DSL) Domain An are of knowldege with tightly interrelated concepts Examples: Genetics, flight control, data base management, … DSL – Domain Specific Language Approach: The Concepts of a domain are defined by a metamodel Advantages compared to general purpose language Higher abstraction level Easier understanding by domain experts Automated mapping to lower abstraction levels Examples Representation of database schema by ER diagramm (grafical DSL) Representation of database schema by DDL script (textual DSL) MOF – Meta Object Facility Model based language for defining meta models Master form (unique metametamodell MMM)
„Model-based Software Development“, Concrete Syntax versus Abstract Syntax package demo; class C { int m(int i) { m(i); } var method C parent param type name type parent int i parent var access name i int m name m parent call block method class name demo name package 1 4 parent param(4, 3, ‘i'‚ int) method(3, 2, 'm', int,[4]) class(2, 1, 'C') package(1, 0, 'demo') block(5, 3, [6]) call(6, 5, null, 3 ) ident(7, 6, 4 )
„Model-based Software Development“, package(1, 0, 'demo'). ● Describes the structure of the input or output of a system ◆ Textual ◆ Graphical ● Specified by a grammar ◆ Textual → EBNF ◆ Graphical → Graph grammar ● Describes the structure of the internal representation (= the model) ◆ Objects ◆ Clauses ◆ Relations ● Specified by a meta-model ◆ See previous slides Concrete Syntax versus Abstract Syntax package demo;
„Model-based Software Development“, Families of Model Transformation Concrete Syntax (textual / grafical) Abstract Syntax (internal) Text-to-model Model-to-text Model-to-model
„Model-based Software Development“ Summer semester 2016 –– Core MDSE Topics
„Model-based Software Development“, Eclipse Modeling Framework ECORE as the basis of tool interoperability Transformation rules use the meta-models Tools use ECORE to understand the meta-models Meta-model of Source Model Source Model Meta-model of Target Model Target Model conforms to Transformation Rules ECORE conforms to
„Model-based Software Development“, Xtext: Define your own DSL! ● 1. Define the grammar of your language
„Model-based Software Development“, Xtext: Define your own DSL! ● 2. Automatically generate ◆ a parser ◆ an internal model ◆ a complete IDE for the new language
„Model-based Software Development“, Xtext: Customize your DSL! ● Configure the code generation workflow ◆ Workflow language (MWE2) ◆ Dependency injection (Google Guice) ◆ Continuous Integration (Maven) ● Customize ◆ Semantic checking ◆ Error reporting ◆ Outline ◆ Formatting ◆ Autocompletion
„Model-based Software Development“, Xtend: Model to Model Transformation ● Full programing language ● Java made easy ◆ Less boilerplate code ◆ Type inference ◆ … ● You can work on the model otherwise, but Xtrend makes it much easier
„Model-based Software Development“, Xtend: Model to text transformation ● Template language embedded into Xtend Literal output (fully formatted, no need for System.out.println(„…“) Start template End template Embedded code Reference to an attribute of the currently processed model element
„Model-based Software Development“, Viatra: Graph-based Model to Model Transformation ● Graph-based transformations
„Model-based Software Development“, ATL: Hybrid model-to-model transformation ● Declarative … …and operational
„Model-based Software Development“ Summer semester 2016 –– Application Topics
„Model-based Software Development“, Propositionalization ● What is Machine Learning? ◆ Learning models from observations ◆ E.g detect spam s, predict whether printing machine will fail ●O ften transformations to simple feature vectors ◆ Feature vector example: (sunny, 23.2 degrees Celsius, windy) ◆ Real world: often complex relationships e.g. social graphs of persons, complex interactions in machines Task : ● Look at transformation techniques from MDSE perspective and present comparative analysis with (dis-)advantages
„Model-based Software Development“, Propositionalization ● References: Ristoski, Petar, and Heiko Paulheim. "A comparison of propositionalization strategies for creating features from linked open data." Linked Data for Knowledge Discovery (2014): 6. Kramer, S., Lavrac, N., Flach, P.: Propositionalisation approaches to Relational Data Mining. In Dzeroski, S., Larac, N., eds.: Relational Data Mining. Springer, Berlin (2001) 262–291 Maier, Marc, et al. "Flattening network data for causal discovery: What could go wrong?." Workshop on Information in Networks
„Model-based Software Development“, Machine Learning ● Modelling: Each type of classifier is a model, which follows certain properties and learns a particular task. e.g. –Decision Trees –Neural Networks –Rule based Learners ● Task 1: Look at learning algorithms from MDSE perspective and present an analysis of models ● Task 2: Look at a machine learning tool e.g. WEKA, and present a comparative analysis of learning models from MDSE perspective
„Model-based Software Development“, Kernel based Learning ● Modelling layer : ● There are some classifiers called kernel based classifiers. ● They require data to be transformed in a particular manner. i.e. ð low dimensions ð linearly separable. ● Task: Explore different kernel techniques from MDSE perspective and present analysis of kernel based modelling methods
„Model-based Software Development“, Kernel based Learning References : lBishop, Christopher M. "Model-based machine learning." Philosophical Transactions of the Royal Society of London A: Mathematical, Physical and Engineering Sciences (2013): lhttp://research.microsoft.com/en-us/um/people/cmbishop/downloads/Bishop- MBML-2012.pdfhttp://research.microsoft.com/en-us/um/people/cmbishop/downloads/Bishop- MBML-2012.pdf models.html models.html
„Model-based Software Development“, Model based Optimization ● Given a complex optimization problem, the task is to find the values of parameters that optimize the problem. e.g. ð Data packet routing, ð Shortest path Function optimization ● There are different methods to model a solution to such problem. ● Mathematical Modelling –Gradient Descent ● Algorithmic Modelling –Genetic Algorithm ● Task : Explore any one type of such optimization algorithms with MDSE perspective and highlight the underlying modelling techniques
„Model-based Software Development“, Model based Optimization References : df df %20Survey%20of%20model- based%20methods%20for%20global%20optimization.pdf %20Survey%20of%20model- based%20methods%20for%20global%20optimization.pdf