From 93387c3602503a33666a0303af18d4175d002f98 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Kruli=C5=A1?= Date: Sat, 13 Jun 2020 00:34:52 +0200 Subject: [PATCH] Updated Score Calculators (markdown) --- Score-Calculators.md | 30 +++++++++++++++++++++++++++--- 1 file changed, 27 insertions(+), 3 deletions(-) diff --git a/Score-Calculators.md b/Score-Calculators.md index bc04360..47ad4d0 100644 --- a/Score-Calculators.md +++ b/Score-Calculators.md @@ -12,8 +12,8 @@ Computes overall score as weighted average of individual test scores. The calcul ``` testWeights: - "Test 01": 300 - "Test 02": 200 + "Test 01": 200 + "Test 02": 300 "Test 03": 100 ``` @@ -40,4 +40,28 @@ Internal nodes (functions): * `min` - computes minimum of all children values * `max` - computes maximum of all children values * `avg` - computes arithmetic average of all children values -* `clamp` - unary node that clamps its operand value into [0,1] range \ No newline at end of file +* `clamp` - unary node that clamps its operand value into [0,1] range + +For practical reasons, we have decided to implement one optimization. Value literals may be also encoded as simple float numbers (instead of objects) in the child list. The `value`-typed objects and float literals are treated as equal; however, root node must be always an object (even when it is a literal). + +#### Example + +``` +type: div +children: + - type: avg + children: + - type: mul + children: + - 2.0 + - type: test-result + test: "Test 01" + - type: mul + children: + - 3.0 + - type: test-result + test: "Test 02" + - type: test-result + test: "Test 02" + - 5.0 +``` \ No newline at end of file