Overview
Comment: | [build] graph data display |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | build | rg |
Files: | files | file ages | folders |
SHA3-256: |
a7352c0d8f64d4471afcc95424fc5bf0 |
User & Date: | olr on 2018-08-18 13:07:09 |
Other Links: | branch diff | manifest | tags |
Context
2018-08-18
| ||
13:29 | [core] gc engine: don’t check regexes on some META tokens check-in: 209474b757 user: olr tags: core, rg | |
13:07 | [build] graph data display check-in: a7352c0d8f user: olr tags: build, rg | |
11:26 | [build] graph bookmark display check-in: bc2b809d0e user: olr tags: build, rg | |
Changes
Modified compile_rules_graph.py from [899bcecea3] to [70fe4f2ca1].
︙ | ︙ | |||
392 393 394 395 396 397 398 399 400 401 402 403 404 405 | else: print("Unknown line:") print(sLine) # processing rules print(" preparing rules...") for sGraphName, lRuleLine in dAllGraph.items(): lPreparedRule = [] for i, sRuleGroup, sTokenLine, iActionBlock, sActions, nPriority in lRuleLine: for lRule in createRule(i, sRuleGroup, sTokenLine, iActionBlock, sActions, nPriority, dOptPriority, dDef): lPreparedRule.append(lRule) # Graph creation oDARG = darg.DARG(lPreparedRule, sLang) dAllGraph[sGraphName] = oDARG.createGraph() | > | 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 | else: print("Unknown line:") print(sLine) # processing rules print(" preparing rules...") for sGraphName, lRuleLine in dAllGraph.items(): print("{:>8,} rules in {:<24} ".format(len(lRuleLine), "<"+sGraphName+">"), end="") lPreparedRule = [] for i, sRuleGroup, sTokenLine, iActionBlock, sActions, nPriority in lRuleLine: for lRule in createRule(i, sRuleGroup, sTokenLine, iActionBlock, sActions, nPriority, dOptPriority, dDef): lPreparedRule.append(lRule) # Graph creation oDARG = darg.DARG(lPreparedRule, sLang) dAllGraph[sGraphName] = oDARG.createGraph() |
︙ | ︙ |
Modified darg.py from [11706e17f5] to [29c743b753].
︙ | ︙ | |||
13 14 15 16 17 18 19 | class DARG: """DIRECT ACYCLIC RULE GRAPH""" # This code is inspired from Steve Hanov’s DAWG, 2011. (http://stevehanov.ca/blog/index.php?id=115) def __init__ (self, lRule, sLangCode): | | | 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 | class DARG: """DIRECT ACYCLIC RULE GRAPH""" # This code is inspired from Steve Hanov’s DAWG, 2011. (http://stevehanov.ca/blog/index.php?id=115) def __init__ (self, lRule, sLangCode): print(" > DARG", end="") # Preparing DARG self.sLangCode = sLangCode self.nRule = len(lRule) self.aPreviousRule = [] Node.resetNextId() self.oRoot = Node() |
︙ | ︙ |