Unnormalizer.emadl 1.13 KB
Newer Older
1
2
3
4
5
6
7
package dp.subcomponents;

component Unnormalizer {
    ports in Q^{13,1,1} normalizedPredictions,
          out Affordance affordance;

    implementation Math {
Svetlana's avatar
Svetlana committed
8
9
10
11
12
13
14
15
16
17
18
19
20
        affordance.angle = (normalizedPredictions(0,0,0) - 0.5)*1.1;
        affordance.toMarkingLL = (normalizedPredictions(0,0,1) - 1.48181) * 6.8752;
        affordance.toMarkingML = (normalizedPredictions(0,0,2) - 0.98)*6.25;
        affordance.toMarkingMR = (normalizedPredictions(0,0,3) - 0.02)*6.25;
        affordance.toMarkingRR = (normalizedPredictions(0,0,4) + 0.48181)*6.8752;
        affordance.distLL = (normalizedPredictions(0,0,5) - 0.12)*95;
        affordance.distMM = (normalizedPredictions(0,0,6) - 0.12)*95;
        affordance.distRR = (normalizedPredictions(0,0,7) - 0.12)*95;
        affordance.toMarkingL = (normalizedPredictions(0,0,8) - 1.34445)*5.6249;
        affordance.toMarkingM = (normalizedPredictions(0,0,9) - 0.39091)*6.8752;
        affordance.toMarkingR = (normalizedPredictions(0,0,10) + 0.34445)*5.6249;
        affordance.distL = (normalizedPredictions(0,0,11) - 0.12)*95;
        affordance.distR = (normalizedPredictions(0,0,12) - 0.12)*95;
21
22
    }
}