Running: ./testmodel.py --libraries=/home/hudson/saved_omc/libraries/.openmodelica/libraries --ompython_omhome=/usr Modelica_4.0.0_Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge.conf.json loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 4.0.0+maint.om/package.mo", uses=false) [Timeout 180] "Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 4.0.0+maint.om/package.mo): time 0.001733/0.001733, allocations: 119 kB / 17.78 MB, free: 5.227 MB / 14.72 MB " [Timeout remaining time 180] loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 4.0.0+maint.om/package.mo", uses=false) [Timeout 180] "Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 4.0.0+maint.om/package.mo): time 0.001893/0.001893, allocations: 197.2 kB / 20.73 MB, free: 2.285 MB / 14.72 MB " [Timeout remaining time 180] loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 4.0.0+maint.om/package.mo", uses=false) [Timeout 180] "Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 4.0.0+maint.om/package.mo): time 1.521/1.521, allocations: 225.6 MB / 249.1 MB, free: 3.629 MB / 190.1 MB " [Timeout remaining time 178] Using package Modelica with version 4.0.0 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 4.0.0+maint.om/package.mo) Using package Complex with version 4.0.0 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 4.0.0+maint.om/package.mo) Using package ModelicaServices with version 4.0.0 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 4.0.0+maint.om/package.mo) Running command: "" <> buildModelFMU(Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge,fileNamePrefix="Modelica_4_0_0_Modelica_Electrical_Batteries_Examples_BatteryDischargeCharge",fmuType="me",version="2.0",platforms={"static"}) "" <> buildModelFMU(Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge,fileNamePrefix="Modelica_4_0_0_Modelica_Electrical_Batteries_Examples_BatteryDischargeCharge",fmuType="me",version="2.0",platforms={"static"}) [Timeout 660] "Notification: Performance of FrontEnd - loaded program: time 0.001476/0.001476, allocations: 51.92 kB / 365.6 MB, free: 0.8789 MB / 286.1 MB Notification: Performance of FrontEnd - Absyn->SCode: time 0.09879/0.1003, allocations: 52.14 MB / 417.8 MB, free: 12.64 MB / 350.1 MB Notification: Performance of NFInst.instantiate(Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge): time 0.007412/0.1077, allocations: 5.821 MB / 423.6 MB, free: 6.801 MB / 350.1 MB Notification: Performance of NFInst.instExpressions: time 0.004319/0.112, allocations: 2.595 MB / 426.2 MB, free: 4.195 MB / 350.1 MB Notification: Performance of NFInst.updateImplicitVariability: time 0.0005521/0.1125, allocations: 27.81 kB / 426.2 MB, free: 4.168 MB / 350.1 MB Notification: Performance of NFTyping.typeComponents: time 0.00161/0.1142, allocations: 0.7699 MB / 427 MB, free: 3.395 MB / 350.1 MB Notification: Performance of NFTyping.typeBindings: time 0.001073/0.1152, allocations: 0.5166 MB / 427.5 MB, free: 2.875 MB / 350.1 MB Notification: Performance of NFTyping.typeClassSections: time 0.001103/0.1163, allocations: 0.5023 MB / 428 MB, free: 2.379 MB / 350.1 MB Notification: Performance of NFFlatten.flatten: time 0.001865/0.1182, allocations: 1.586 MB / 429.6 MB, free: 0.7812 MB / 350.1 MB Notification: Performance of NFFlatten.resolveConnections: time 0.0006533/0.1188, allocations: 434.5 kB / 430 MB, free: 344 kB / 350.1 MB Notification: Performance of NFEvalConstants.evaluate: time 0.0008717/0.1197, allocations: 0.6229 MB / 430.6 MB, free: 15.71 MB / 366.1 MB Notification: Performance of NFSimplifyModel.simplify: time 0.0009894/0.1207, allocations: 0.7783 MB / 431.4 MB, free: 14.93 MB / 366.1 MB Notification: Performance of NFPackage.collectConstants: time 0.0001877/0.1209, allocations: 132 kB / 431.5 MB, free: 14.8 MB / 366.1 MB Notification: Performance of NFFlatten.collectFunctions: time 0.0003745/0.1213, allocations: 215.8 kB / 431.8 MB, free: 14.59 MB / 366.1 MB Notification: Performance of NFScalarize.scalarize: time 0.0005495/0.1218, allocations: 0.6348 MB / 432.4 MB, free: 13.95 MB / 366.1 MB Notification: Performance of NFVerifyModel.verify: time 0.0008313/0.1227, allocations: 0.9166 MB / 433.3 MB, free: 13.03 MB / 366.1 MB Notification: Performance of NFConvertDAE.convert: time 0.002549/0.1252, allocations: 2.494 MB / 435.8 MB, free: 10.53 MB / 366.1 MB Notification: Performance of FrontEnd - DAE generated: time 4.368e-06/0.1252, allocations: 0 / 435.8 MB, free: 10.53 MB / 366.1 MB Notification: Performance of FrontEnd: time 2.074e-06/0.1252, allocations: 0 / 435.8 MB, free: 10.53 MB / 366.1 MB Notification: Performance of Transformations before backend: time 2.979e-05/0.1252, allocations: 0 / 435.8 MB, free: 10.53 MB / 366.1 MB Notification: Model statistics after passing the front-end and creating the data structures used by the back-end: * Number of equations: 215 * Number of variables: 215 Notification: Performance of Generate backend data structure: time 0.005228/0.1305, allocations: 2.636 MB / 438.4 MB, free: 7.832 MB / 366.1 MB Notification: Performance of prepare preOptimizeDAE: time 5.328e-05/0.1305, allocations: 12.03 kB / 438.4 MB, free: 7.82 MB / 366.1 MB Notification: Performance of preOpt introduceOutputAliases (simulation): time 0.0001981/0.1307, allocations: 139.5 kB / 438.6 MB, free: 7.676 MB / 366.1 MB Notification: Performance of preOpt normalInlineFunction (simulation): time 0.0004574/0.1312, allocations: 235.4 kB / 438.8 MB, free: 7.445 MB / 366.1 MB Notification: Performance of preOpt evaluateParameters (simulation): time 0.002602/0.1338, allocations: 1.552 MB / 440.4 MB, free: 5.848 MB / 366.1 MB Notification: Performance of preOpt simplifyIfEquations (simulation): time 0.0001138/0.1339, allocations: 100 kB / 440.5 MB, free: 5.746 MB / 366.1 MB Notification: Performance of preOpt expandDerOperator (simulation): time 0.0001308/0.134, allocations: 87.92 kB / 440.6 MB, free: 5.66 MB / 366.1 MB Notification: Performance of preOpt clockPartitioning (simulation): time 0.002082/0.1361, allocations: 1.108 MB / 441.7 MB, free: 4.473 MB / 366.1 MB Notification: Performance of preOpt findStateOrder (simulation): time 2.356e-05/0.1361, allocations: 0 / 441.7 MB, free: 4.473 MB / 366.1 MB Notification: Performance of preOpt replaceEdgeChange (simulation): time 0.0001101/0.1362, allocations: 40 kB / 441.7 MB, free: 4.434 MB / 366.1 MB Notification: Performance of preOpt inlineArrayEqn (simulation): time 2.49e-05/0.1363, allocations: 20 kB / 441.7 MB, free: 4.414 MB / 366.1 MB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.001523/0.1378, allocations: 0.7182 MB / 442.4 MB, free: 3.695 MB / 366.1 MB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.2249/0.3626, allocations: 4.597 MB / 447 MB, free: 28.43 MB / 366.1 MB Notification: Performance of preOpt comSubExp (simulation): time 0.00116/0.3638, allocations: 0.9047 MB / 447.9 MB, free: 27.92 MB / 366.1 MB Notification: Performance of preOpt resolveLoops (simulation): time 0.0006677/0.3645, allocations: 349.7 kB / 448.3 MB, free: 27.91 MB / 366.1 MB Notification: Performance of preOpt evalFunc (simulation): time 5.4e-05/0.3645, allocations: 7.422 kB / 448.3 MB, free: 27.91 MB / 366.1 MB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 2.93e-05/0.3645, allocations: 47.81 kB / 448.3 MB, free: 27.87 MB / 366.1 MB Notification: Performance of pre-optimization done (n=44): time 2.184e-06/0.3646, allocations: 2.75 kB / 448.3 MB, free: 27.87 MB / 366.1 MB Notification: Performance of matching and sorting (n=44): time 0.001654/0.3662, allocations: 0.8267 MB / 449.2 MB, free: 27.83 MB / 366.1 MB Notification: Performance of inlineWhenForInitialization (initialization): time 8.968e-05/0.3663, allocations: 423.9 kB / 449.6 MB, free: 27.33 MB / 366.1 MB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.003212/0.3695, allocations: 2.735 MB / 452.3 MB, free: 27.11 MB / 366.1 MB Notification: Performance of collectPreVariables (initialization): time 5.807e-05/0.3696, allocations: 44.86 kB / 452.4 MB, free: 27.08 MB / 366.1 MB Notification: Performance of collectInitialEqns (initialization): time 0.0006607/0.3702, allocations: 0.8833 MB / 453.2 MB, free: 26.83 MB / 366.1 MB Notification: Performance of collectInitialBindings (initialization): time 0.0001233/0.3703, allocations: 165.2 kB / 453.4 MB, free: 26.72 MB / 366.1 MB Notification: Performance of simplifyInitialFunctions (initialization): time 0.0002598/0.3706, allocations: 129.7 kB / 453.5 MB, free: 26.66 MB / 366.1 MB Notification: Performance of setup shared object (initialization): time 6.624e-05/0.3707, allocations: 331.4 kB / 453.9 MB, free: 26.34 MB / 366.1 MB Notification: Performance of preBalanceInitialSystem (initialization): time 0.0005584/0.3712, allocations: 257.4 kB / 454.1 MB, free: 26.27 MB / 366.1 MB Notification: Performance of partitionIndependentBlocks (initialization): time 0.0006484/0.3719, allocations: 0.5279 MB / 454.6 MB, free: 25.85 MB / 366.1 MB Notification: Performance of analyzeInitialSystem (initialization): time 0.0009182/0.3728, allocations: 0.6149 MB / 455.2 MB, free: 25.49 MB / 366.1 MB Notification: Performance of solveInitialSystemEqSystem (initialization): time 4.939e-06/0.3728, allocations: 2.25 kB / 455.2 MB, free: 25.49 MB / 366.1 MB Notification: Performance of matching and sorting (n=76) (initialization): time 0.001515/0.3743, allocations: 0.8548 MB / 456.1 MB, free: 25.17 MB / 366.1 MB Notification: Performance of prepare postOptimizeDAE: time 1.955e-05/0.3743, allocations: 14.66 kB / 456.1 MB, free: 25.17 MB / 366.1 MB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 1.247e-05/0.3744, allocations: 7.172 kB / 456.1 MB, free: 25.17 MB / 366.1 MB Notification: Performance of postOpt tearingSystem (initialization): time 2.425e-05/0.3744, allocations: 9.188 kB / 456.1 MB, free: 25.17 MB / 366.1 MB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0006088/0.375, allocations: 161.4 kB / 456.3 MB, free: 25.16 MB / 366.1 MB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 1.683e-05/0.375, allocations: 11.17 kB / 456.3 MB, free: 25.16 MB / 366.1 MB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.0009742/0.376, allocations: 166.6 kB / 456.5 MB, free: 25.12 MB / 366.1 MB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 5.412e-05/0.376, allocations: 27.42 kB / 456.5 MB, free: 25.12 MB / 366.1 MB Notification: Model statistics after passing the back-end for initialization: * Number of independent subsystems: 25 * Number of states: 0 () * Number of discrete variables: 6 (pulseSeries.on2,pulseSeries.on1,energy2.local_reset,battery2.limIntegrator.local_reset,energy1.local_reset,battery1.limIntegrator.local_reset) * Number of discrete states: 0 () * Number of clocked states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for initialization (76): * Single equations (assignments): 76 * Array equations: 0 * Algorithm blocks: 0 * Record equations: 0 * When equations: 0 * If-equations: 0 * Equation systems (not torn): 0 * Torn equation systems: 0 * Mixed (continuous/discrete) equation systems: 0 Notification: Performance of prepare postOptimizeDAE: time 0.000665/0.3767, allocations: 0.5602 MB / 457 MB, free: 24.86 MB / 366.1 MB Notification: Performance of postOpt lateInlineFunction (simulation): time 0.0002218/0.3769, allocations: 199.2 kB / 457.2 MB, free: 24.76 MB / 366.1 MB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.001331/0.3782, allocations: 0.6898 MB / 457.9 MB, free: 24.5 MB / 366.1 MB Notification: Performance of postOpt inlineArrayEqn (simulation): time 5.971e-06/0.3783, allocations: 4.25 kB / 457.9 MB, free: 24.5 MB / 366.1 MB Notification: Performance of postOpt constantLinearSystem (simulation): time 4.809e-06/0.3783, allocations: 0 / 457.9 MB, free: 24.5 MB / 366.1 MB Notification: Performance of postOpt simplifysemiLinear (simulation): time 8.105e-06/0.3783, allocations: 3.562 kB / 457.9 MB, free: 24.5 MB / 366.1 MB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.003041/0.3813, allocations: 2.116 MB / 460.1 MB, free: 23.59 MB / 366.1 MB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 3.968e-06/0.3813, allocations: 5.938 kB / 460.1 MB, free: 23.59 MB / 366.1 MB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.0004798/0.3818, allocations: 109.1 kB / 460.2 MB, free: 23.58 MB / 366.1 MB Notification: Performance of postOpt tearingSystem (simulation): time 6.522e-06/0.3818, allocations: 3.406 kB / 460.2 MB, free: 23.58 MB / 366.1 MB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 3.785e-05/0.3818, allocations: 15.06 kB / 460.2 MB, free: 23.57 MB / 366.1 MB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 5.62e-06/0.3818, allocations: 6.891 kB / 460.2 MB, free: 23.57 MB / 366.1 MB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 3.106e-06/0.3818, allocations: 5 kB / 460.2 MB, free: 23.57 MB / 366.1 MB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.001635/0.3835, allocations: 1.048 MB / 461.2 MB, free: 23.06 MB / 366.1 MB Notification: Performance of postOpt removeConstants (simulation): time 0.0005462/0.384, allocations: 417.5 kB / 461.7 MB, free: 22.8 MB / 366.1 MB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 0.0001595/0.3842, allocations: 15.16 kB / 461.7 MB, free: 22.8 MB / 366.1 MB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.001004/0.3852, allocations: 142 kB / 461.8 MB, free: 22.78 MB / 366.1 MB Notification: Performance of postOpt findZeroCrossings (simulation): time 0.0003048/0.3855, allocations: 158.8 kB / 462 MB, free: 22.76 MB / 366.1 MB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 3.837e-05/0.3855, allocations: 17.78 kB / 462 MB, free: 22.75 MB / 366.1 MB Notification: Performance of sorting global known variables: time 0.002556/0.3881, allocations: 1.947 MB / 463.9 MB, free: 22.1 MB / 366.1 MB Notification: Performance of sort global known variables: time 1.01e-07/0.3881, allocations: 0 / 463.9 MB, free: 22.1 MB / 366.1 MB Notification: Performance of remove unused functions: time 0.0009251/0.389, allocations: 312.5 kB / 464.2 MB, free: 22.06 MB / 366.1 MB Notification: Model statistics after passing the back-end for simulation: * Number of independent subsystems: 4 * Number of states: 6 (battery1.limIntegrator.y,energy1.y,battery2.limIntegrator.y,battery2.capacitor[1].v,battery2.capacitor[2].v,energy2.y) * Number of discrete variables: 2 (pulseSeries.on1,pulseSeries.on2) * Number of discrete states: 0 () * Number of clocked states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for simulation (44): * Single equations (assignments): 44 * Array equations: 0 * Algorithm blocks: 0 * Record equations: 0 * When equations: 0 * If-equations: 0 * Equation systems (not torn): 0 * Torn equation systems: 0 * Mixed (continuous/discrete) equation systems: 0 Notification: Performance of Backend phase and start with SimCode phase: time 0.003568/0.3926, allocations: 1.992 MB / 466.2 MB, free: 20.95 MB / 366.1 MB Notification: Performance of simCode: created initialization part: time 0.001207/0.3938, allocations: 0.5595 MB / 466.8 MB, free: 20.8 MB / 366.1 MB Notification: Performance of simCode: created event and clocks part: time 5.169e-06/0.3938, allocations: 0.8438 kB / 466.8 MB, free: 20.8 MB / 366.1 MB Notification: Performance of simCode: created simulation system equations: time 0.0006488/0.3944, allocations: 341.3 kB / 467.1 MB, free: 20.7 MB / 366.1 MB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.001403/0.3958, allocations: 316.1 kB / 467.4 MB, free: 20.57 MB / 366.1 MB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.0206/0.4164, allocations: 17.21 MB / 484.6 MB, free: 9.137 MB / 366.1 MB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.0007088/0.4172, allocations: 1.434 MB / 486.1 MB, free: 7.676 MB / 366.1 MB Notification: Performance of simCode: alias equations: time 0.0007573/0.4179, allocations: 292 kB / 486.4 MB, free: 7.395 MB / 366.1 MB Notification: Performance of simCode: all other stuff during SimCode phase: time 0.0007172/0.4186, allocations: 0.6945 MB / 487.1 MB, free: 6.699 MB / 366.1 MB Notification: Performance of SimCode: time 7.92e-07/0.4186, allocations: 0 / 487.1 MB, free: 6.699 MB / 366.1 MB Notification: Performance of buildModelFMU: Generate the FMI files: time 0.07766/0.4963, allocations: 39 MB / 0.5137 GB, free: 15.97 MB / 414.1 MB Notification: Performance of buildModelFMU: Generate platform static: time 11.2/11.69, allocations: 4.812 kB / 0.5137 GB, free: 15.97 MB / 414.1 MB " [Timeout remaining time 648] (rm -f Modelica_4.0.0_Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge.pipe ; mkfifo Modelica_4.0.0_Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge.pipe ; head -c 1048576 < Modelica_4.0.0_Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge.pipe >> ../files/Modelica_4.0.0_Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge.sim & python3 -m fmpy simulate --output-file Modelica_4.0.0_Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge_res.csv --start-time 0 --stop-time 3600 --timeout 50 --relative-tolerance 1e-06 --interface-type ModelExchange --solver CVode --output-interval 0.1 Modelica_4_0_0_Modelica_Electrical_Batteries_Examples_BatteryDischargeCharge.fmu > Modelica_4.0.0_Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge.pipe 2>&1) [Timeout 52.5] diffSimulationResults("Modelica_4.0.0_Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge_res.csv","/var/lib/jenkins1/ws/OpenModelicaLibraryTestingWork/Reference-modelica.org/ReferenceResults/MAP-LIB_ReferenceResults/v4.0.0/Modelica/Electrical/Batteries/Examples/BatteryDischargeCharge/BatteryDischargeCharge.csv","/var/lib/jenkins1/ws/OpenModelicaLibraryTestingWork/OpenModelicaLibraryTesting/files/Modelica_4.0.0_Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge.diff",relTol=0.003,relTolDiffMinMax=0.003,rangeDelta=0.001) [Timeout 660] "Error: Could not read variable energy2.y in file Modelica_4.0.0_Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge_res.csv. Warning: Get data of variable energy2.y from file Modelica_4.0.0_Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge_res.csv failed! " [Timeout remaining time 660] Reference file matches [Calling sys.exit(0), Time elapsed: 15.573492062743753]