From 1f5cab77334817776618092501628ed70368dd6e Mon Sep 17 00:00:00 2001 From: Kristóf Marussy Date: Fri, 30 Aug 2019 15:52:45 +0200 Subject: FAM metamodel loader experiments --- ..._useful_ViatraSolver_polyhedral_typeHierarchy_Clp.json | 7 +++++-- .../hu/bme/mit/inf/dslreasoner/run/MetamodelLoader.xtend | 15 ++++++++------- 2 files changed, 13 insertions(+), 9 deletions(-) (limited to 'Tests/hu.bme.mit.inf.dslreasoner.run') diff --git a/Tests/hu.bme.mit.inf.dslreasoner.run/configs/FAM_useful_ViatraSolver_polyhedral_typeHierarchy_Clp.json b/Tests/hu.bme.mit.inf.dslreasoner.run/configs/FAM_useful_ViatraSolver_polyhedral_typeHierarchy_Clp.json index 26df3c74..1e2d4dd4 100644 --- a/Tests/hu.bme.mit.inf.dslreasoner.run/configs/FAM_useful_ViatraSolver_polyhedral_typeHierarchy_Clp.json +++ b/Tests/hu.bme.mit.inf.dslreasoner.run/configs/FAM_useful_ViatraSolver_polyhedral_typeHierarchy_Clp.json @@ -4,10 +4,13 @@ "timeout": 1200, "saveModels": true, "warmupIterations": 0, - "iterations": 1, + "iterations": 5, "domain": "FAM", "scope": "none", "sizes": [500], "solver": "ViatraSolver", - "scopePropagator": "basic" + "scopePropagator": "polyhedral", + "propagatedConstraints": "hints", + "polyhedronSolver": "Clp", + "scopeHeuristics": "polyhedral" } diff --git a/Tests/hu.bme.mit.inf.dslreasoner.run/src/hu/bme/mit/inf/dslreasoner/run/MetamodelLoader.xtend b/Tests/hu.bme.mit.inf.dslreasoner.run/src/hu/bme/mit/inf/dslreasoner/run/MetamodelLoader.xtend index 4b0791d4..1be03eed 100644 --- a/Tests/hu.bme.mit.inf.dslreasoner.run/src/hu/bme/mit/inf/dslreasoner/run/MetamodelLoader.xtend +++ b/Tests/hu.bme.mit.inf.dslreasoner.run/src/hu/bme/mit/inf/dslreasoner/run/MetamodelLoader.xtend @@ -85,8 +85,9 @@ class FAMLoader extends MetamodelLoader { val List classes = package.EClassifiers.filter(EClass).toList val List enums = package.EClassifiers.filter(EEnum).toList val List literals = enums.map[ELiterals].flatten.toList - val List references = classes.map[EReferences].flatten.filter[name != "type" && name != "model"]. - toList + val List references = classes.map[EReferences].flatten.filter [ reference | + !#{"model", "type"}.contains(reference.name) + ].toList val List attributes = classes.map[EAttributes].flatten.toList return new EcoreMetamodelDescriptor(classes, #{}, false, enums, literals, references, attributes) } @@ -196,7 +197,7 @@ class YakinduLoader extends MetamodelLoader { } override additionalConstraints() { - //#[[method|new SGraphInconsistencyDetector(method)]] + // #[[method|new SGraphInconsistencyDetector(method)]] emptyList } @@ -261,7 +262,7 @@ class FileSystemLoader extends MetamodelLoader { } override additionalConstraints() { - //#[[method|new FileSystemInconsistencyDetector(method)]] + // #[[method|new FileSystemInconsistencyDetector(method)]] emptyList } @@ -386,11 +387,11 @@ class SatelliteLoader extends MetamodelLoader { } override additionalConstraints() { #[] } - + override getHints(Ecore2Logic ecore2Logic, Ecore2Logic_Trace trace) { #[new SatelliteHint(ecore2Logic, trace)] } - + override getTypeQuantiles() { #{ "CubeSat3U" -> new TypeQuantiles(0.1, 0.25), @@ -402,5 +403,5 @@ class SatelliteLoader extends MetamodelLoader { "InterferometryPayload" -> new TypeQuantiles(0.15, 0.25) } } - + } -- cgit v1.2.3-70-g09d2