model composition andrew finney no relevant affiliation

22
Model Composition Andrew Finney No relevant affiliation

Upload: kory-daniels

Post on 08-Jan-2018

214 views

Category:

Documents


1 download

DESCRIPTION

The proposal prior to Newcastle Submodels –SBML document contains multiple models Instances –Copies of models appearing inside a referencing model Direct Links –Most references to object inside a model can be replaced with a path to an object inside an instance Example: a species reference can refer to a species inside an instance –This means you can create a reaction linking species in different instances Overloading Links –Explicit arc between a pair of objects Directed: One overloads or replaces the other Any reference to the overloaded object is acquired by the overloading object Example: –a species in one model replaces a species in another. –the species ends up with the union of all the species references Ports –Optional –Exposed name for internal object in model –Links can refer to Port instead of internal object

TRANSCRIPT

Page 1: Model Composition Andrew Finney No relevant affiliation

Model Composition

Andrew FinneyNo relevant affiliation

Page 2: Model Composition Andrew Finney No relevant affiliation

Overview• Review existing proposal• New Stuff figured out at Newcastle

Hackathon• Late Breaking - Proposal for new

‘module’:– Model Inclusion

• How the various Level 3 ‘modules’ interact

• Short Hand for Level 3• Conclusions

Page 3: Model Composition Andrew Finney No relevant affiliation

The proposal prior to Newcastle• Submodels

– SBML document contains multiple models • Instances

– Copies of models appearing inside a referencing model• Direct Links

– Most references to object inside a model can be replaced with a path to an object inside an instance

• Example: a species reference can refer to a species inside an instance

– This means you can create a reaction linking species in different instances

• Overloading Links– Explicit arc between a pair of objects

• Directed: One overloads or replaces the other• Any reference to the overloaded object is acquired by the

overloading object• Example:

– a species in one model replaces a species in another. – the species ends up with the union of all the species references

• Ports– Optional– Exposed name for internal object in model– Links can refer to Port instead of internal object

Page 4: Model Composition Andrew Finney No relevant affiliation

Model CompositionExample of Direct Links

Instance A of Model Z Instance B of Model Zf

g

h h

fg

i

Page 5: Model Composition Andrew Finney No relevant affiliation

Model CompositionExample of Direct Links

Flattened

a/f

a/g

a/h b/h

b/fb/g

i

Page 6: Model Composition Andrew Finney No relevant affiliation

Model CompositionExample of Link Overloading

Instance A of Model Z Instance B of Model Zf

g

h h

fg

i

Page 7: Model Composition Andrew Finney No relevant affiliation

Model CompositionExample of Link Overloading

Flattened

a/f

a/g

a/h

b/g

i

Page 8: Model Composition Andrew Finney No relevant affiliation

Model CompositionExample of Link Overloading

with InterfacesInstance A of Model Z Instance B of Model Z

f

g

h h

fg

iF

HG

H

F

G

Page 9: Model Composition Andrew Finney No relevant affiliation

Ideas from Newcastle• Explicit ‘Must Be Overloaded’ field

on Port• N to M links• The semantics of Overloading

Reactions• Garbage Collection

Page 10: Model Composition Andrew Finney No relevant affiliation

N to M Overloading Links• From overloads To• From can be either present or not present

– Not present indicates that the To set is deleted from the resulting model

– How do we handle ‘remaining’ references to the To object?

• cascaded deletion:– any referencing object is also deleted

• its an error– other overloads must be present to create a tidy

flattened model explicitly• More than one object in To

– simply indicates that the To set is replaced by the From object

• More than one object in From– flattened model has all the from objects and none of the

to objects• Nice for reactions but what about other objects?

Page 11: Model Composition Andrew Finney No relevant affiliation

Example: Species removed

Instance B of Model Z

fComposedModel

g

gFlattenedModel

Page 12: Model Composition Andrew Finney No relevant affiliation

Reaction Overloading• Consider reaction network to be bi-

partite graph – arcs (species references) link species nodes

to reaction nodes• Overload on species

– Flattened species node acquires union of incident edges

• Overload on reaction– Flattened reaction node retains incident

edges of the overloading reaction node only

Page 13: Model Composition Andrew Finney No relevant affiliation

Reaction Overloading: Example

Composed Model

Instance A of Model Z

Instance B of Model Y

f g h

nm

i

Page 14: Model Composition Andrew Finney No relevant affiliation

Reaction Overloading: Example

Flattened Model

g

nm

i

Page 15: Model Composition Andrew Finney No relevant affiliation

Reaction Overloading: Example

Garbage Collected Model

nm

i

Page 16: Model Composition Andrew Finney No relevant affiliation

What Next?(Model Composition building on L2

only)• Establish overloading rules for all

objects– Reactions

• only type to support N to M?– Species, Compartment

• can support 1 to M– Species Type, Compartment Type, Instance,

Parameter• can only support 1 to 1• Instance overload is fun!!!

– Requires Ports to match??• Species Type overload in Multi-component

context problematic

Page 17: Model Composition Andrew Finney No relevant affiliation

Model Inclusion• New Module

– separate from Model Composition

• covers combining separate XML documents into a single larger model

• Ideal for solving problems of reusing systems of multi-components

Page 18: Model Composition Andrew Finney No relevant affiliation

Model Inclusion: Implications

• Model Inclusion– Have a list of simple elements that pair a name

field value with a URL value for another model– Name value, the Inclusion Name, is in global

namespace in including model – Objects in these models can be referenced

using ObjectRef using the Inclusion name and the name of the object in the referenced model

• Model Composition – retain model instances that are instances of

model referenced by URL• semantics are different

Page 19: Model Composition Andrew Finney No relevant affiliation

How the Level 3 Modules Interact

ModelComposition

Arrays

Multi-componentSpecies

Arrays of Instances

Overloading Arrays

Arrays of binding sites

Observablesreferenced from

Ports

Spatial and Model Inclusion are orthogonal to these modules(or the there would be too many lines)

Page 20: Model Composition Andrew Finney No relevant affiliation

We need to be careful• If we want to have formal modularisation

of Level 3– leads to separate XML namespaces

• We need to– Explore in outline all the likely extensions

• identify common elements• identify pathological interactions

• Otherwise– Common elements repeated in different namespaces– Other embarrassing nastiness

• Suggestion/Example– Core Level 3 contains ObjectRef element

Page 21: Model Composition Andrew Finney No relevant affiliation

We need a short hand• Actual Level 3 models will be very

verbose• Short hand for email discussion

• Adapt Darren W’s tool ??

Page 22: Model Composition Andrew Finney No relevant affiliation

Conclusions• Newcastle meeting enabled us to

identify useful improvements – N to M overloading links– Reaction overloads

• Tactical work required on Model Composition– Rules for overloading

• Strategic Work required on Level 3– Establish Model Inclusion as separate module– Interactions between ‘modules’– Development of Short hand