Running: ./testmodel.py --libraries=/home/hudson/saved_omc/libraries/.openmodelica/libraries --ompython_omhome=/usr Modelica_4.1.0_Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge.conf.json loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 4.1.0+maint.om/package.mo", uses=false) [Timeout 180] "Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 4.1.0+maint.om/package.mo): time 0.001774/0.001774, allocations: 113.2 kB / 20.43 MB, free: 1.449 MB / 14.72 MB " [Timeout remaining time 180] loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 4.1.0+maint.om/package.mo", uses=false) [Timeout 180] "Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 4.1.0+maint.om/package.mo): time 0.002208/0.002208, allocations: 214.7 kB / 23.74 MB, free: 4.656 MB / 14.72 MB " [Timeout remaining time 180] loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 4.1.0+maint.om/package.mo", uses=false) [Timeout 180] "Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 4.1.0+maint.om/package.mo): time 1.459/1.459, allocations: 230.6 MB / 257.5 MB, free: 8.02 MB / 206.1 MB " [Timeout remaining time 178] Using package Modelica with version 4.1.0 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 4.1.0+maint.om/package.mo) Using package Complex with version 4.1.0 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 4.1.0+maint.om/package.mo) Using package ModelicaServices with version 4.1.0 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 4.1.0+maint.om/package.mo) Running command: "" <> buildModelFMU(Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge,fileNamePrefix="Modelica_4_1_0_Modelica_Electrical_Batteries_Examples_BatteryDischargeCharge",fmuType="me",version="2.0",platforms={"static"}) "" <> buildModelFMU(Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge,fileNamePrefix="Modelica_4_1_0_Modelica_Electrical_Batteries_Examples_BatteryDischargeCharge",fmuType="me",version="2.0",platforms={"static"}) [Timeout 660] "Notification: Performance of FrontEnd - loaded program: time 0.002035/0.002035, allocations: 47.92 kB / 377.8 MB, free: 3.141 MB / 302.1 MB Notification: Performance of FrontEnd - Absyn->SCode: time 0.2707/0.2727, allocations: 53.37 MB / 431.1 MB, free: 6.848 MB / 334.1 MB Notification: Performance of NFInst.instantiate(Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge): time 0.00821/0.281, allocations: 5.903 MB / 437 MB, free: 0.9297 MB / 334.1 MB Notification: Performance of NFInst.instExpressions: time 0.005005/0.286, allocations: 2.762 MB / 439.8 MB, free: 14.16 MB / 350.1 MB Notification: Performance of NFInst.updateImplicitVariability: time 0.0007421/0.2867, allocations: 27.81 kB / 439.8 MB, free: 14.13 MB / 350.1 MB Notification: Performance of NFTyping.typeComponents: time 0.001784/0.2885, allocations: 0.7695 MB / 440.6 MB, free: 13.36 MB / 350.1 MB Notification: Performance of NFTyping.typeBindings: time 0.001282/0.2898, allocations: 0.571 MB / 441.2 MB, free: 12.79 MB / 350.1 MB Notification: Performance of NFTyping.typeClassSections: time 0.001251/0.291, allocations: 0.5169 MB / 441.7 MB, free: 12.27 MB / 350.1 MB Notification: Performance of NFFlatten.flatten: time 0.002102/0.2931, allocations: 1.602 MB / 443.3 MB, free: 10.66 MB / 350.1 MB Notification: Performance of NFFlatten.resolveConnections: time 0.0006708/0.2938, allocations: 403.1 kB / 443.7 MB, free: 10.24 MB / 350.1 MB Notification: Performance of NFEvalConstants.evaluate: time 0.0008623/0.2946, allocations: 0.6306 MB / 444.3 MB, free: 9.609 MB / 350.1 MB Notification: Performance of NFSimplifyModel.simplify: time 0.0009814/0.2956, allocations: 0.7744 MB / 445.1 MB, free: 8.832 MB / 350.1 MB Notification: Performance of NFPackage.collectConstants: time 0.0001835/0.2958, allocations: 132 kB / 445.2 MB, free: 8.703 MB / 350.1 MB Notification: Performance of NFFlatten.collectFunctions: time 0.0004125/0.2962, allocations: 223.9 kB / 445.4 MB, free: 8.484 MB / 350.1 MB Notification: Performance of NFScalarize.scalarize: time 0.0005757/0.2968, allocations: 0.6465 MB / 446.1 MB, free: 7.836 MB / 350.1 MB Notification: Performance of NFVerifyModel.verify: time 0.0008771/0.2977, allocations: 0.9282 MB / 447 MB, free: 6.902 MB / 350.1 MB Notification: Performance of NFConvertDAE.convert: time 0.002854/0.3005, allocations: 2.502 MB / 449.5 MB, free: 4.391 MB / 350.1 MB Notification: Performance of FrontEnd - DAE generated: time 5.741e-06/0.3005, allocations: 0 / 449.5 MB, free: 4.391 MB / 350.1 MB Notification: Performance of FrontEnd: time 1.683e-06/0.3005, allocations: 0 / 449.5 MB, free: 4.391 MB / 350.1 MB Notification: Performance of Transformations before backend: time 4.118e-05/0.3006, allocations: 0 / 449.5 MB, free: 4.391 MB / 350.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.005255/0.3058, allocations: 2.577 MB / 452.1 MB, free: 1.77 MB / 350.1 MB Notification: Performance of prepare preOptimizeDAE: time 5.059e-05/0.3059, allocations: 8.031 kB / 452.1 MB, free: 1.762 MB / 350.1 MB Notification: Performance of preOpt introduceOutputAliases (simulation): time 0.0001845/0.3061, allocations: 143.4 kB / 452.2 MB, free: 1.613 MB / 350.1 MB Notification: Performance of preOpt normalInlineFunction (simulation): time 0.000433/0.3065, allocations: 231.5 kB / 452.5 MB, free: 1.387 MB / 350.1 MB Notification: Performance of preOpt evaluateParameters (simulation): time 0.002612/0.3091, allocations: 1.502 MB / 454 MB, free: 15.83 MB / 366.1 MB Notification: Performance of preOpt simplifyIfEquations (simulation): time 0.0001533/0.3093, allocations: 155.4 kB / 454.1 MB, free: 15.66 MB / 366.1 MB Notification: Performance of preOpt expandDerOperator (simulation): time 0.000126/0.3094, allocations: 83.98 kB / 454.2 MB, free: 15.58 MB / 366.1 MB Notification: Performance of preOpt clockPartitioning (simulation): time 0.001823/0.3112, allocations: 1.106 MB / 455.3 MB, free: 14.39 MB / 366.1 MB Notification: Performance of preOpt findStateOrder (simulation): time 2.222e-05/0.3112, allocations: 3.938 kB / 455.3 MB, free: 14.39 MB / 366.1 MB Notification: Performance of preOpt replaceEdgeChange (simulation): time 8.996e-05/0.3113, allocations: 40 kB / 455.3 MB, free: 14.35 MB / 366.1 MB Notification: Performance of preOpt inlineArrayEqn (simulation): time 2.165e-05/0.3114, allocations: 20 kB / 455.4 MB, free: 14.33 MB / 366.1 MB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.001339/0.3127, allocations: 0.7182 MB / 456.1 MB, free: 13.62 MB / 366.1 MB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.007797/0.3205, allocations: 4.538 MB / 460.6 MB, free: 8.906 MB / 366.1 MB Notification: Performance of preOpt comSubExp (simulation): time 0.001188/0.3217, allocations: 0.5169 MB / 461.1 MB, free: 8.379 MB / 366.1 MB Notification: Performance of preOpt resolveLoops (simulation): time 0.0007488/0.3224, allocations: 361.9 kB / 461.5 MB, free: 8.023 MB / 366.1 MB Notification: Performance of preOpt evalFunc (simulation): time 5.427e-05/0.3225, allocations: 4 kB / 461.5 MB, free: 8.02 MB / 366.1 MB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 5.166e-05/0.3225, allocations: 50.5 kB / 461.5 MB, free: 7.961 MB / 366.1 MB Notification: Performance of pre-optimization done (n=44): time 2.615e-06/0.3225, allocations: 0 / 461.5 MB, free: 7.961 MB / 366.1 MB Notification: Performance of matching and sorting (n=44): time 0.002015/0.3246, allocations: 0.8249 MB / 462.4 MB, free: 7.129 MB / 366.1 MB Notification: Performance of inlineWhenForInitialization (initialization): time 0.0002779/0.3248, allocations: 423.2 kB / 462.8 MB, free: 6.617 MB / 366.1 MB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.004096/0.3289, allocations: 2.767 MB / 465.5 MB, free: 3.809 MB / 366.1 MB Notification: Performance of collectPreVariables (initialization): time 0.0001151/0.329, allocations: 37.7 kB / 465.6 MB, free: 3.766 MB / 366.1 MB Notification: Performance of collectInitialEqns (initialization): time 0.0008299/0.3299, allocations: 0.8914 MB / 466.5 MB, free: 2.867 MB / 366.1 MB Notification: Performance of collectInitialBindings (initialization): time 0.0001683/0.33, allocations: 166.6 kB / 466.6 MB, free: 2.703 MB / 366.1 MB Notification: Performance of simplifyInitialFunctions (initialization): time 0.0002158/0.3303, allocations: 130.2 kB / 466.8 MB, free: 2.57 MB / 366.1 MB Notification: Performance of setup shared object (initialization): time 0.000151/0.3304, allocations: 330 kB / 467.1 MB, free: 2.242 MB / 366.1 MB Notification: Performance of preBalanceInitialSystem (initialization): time 0.0005584/0.331, allocations: 253.2 kB / 467.3 MB, free: 1.996 MB / 366.1 MB Notification: Performance of partitionIndependentBlocks (initialization): time 0.0007881/0.3318, allocations: 0.5363 MB / 467.9 MB, free: 1.34 MB / 366.1 MB Notification: Performance of analyzeInitialSystem (initialization): time 0.001062/0.3328, allocations: 0.621 MB / 468.5 MB, free: 0.6406 MB / 366.1 MB Notification: Performance of solveInitialSystemEqSystem (initialization): time 4.428e-06/0.3328, allocations: 0 / 468.5 MB, free: 0.6406 MB / 366.1 MB Notification: Performance of matching and sorting (n=76) (initialization): time 0.00187/0.3347, allocations: 0.8582 MB / 469.4 MB, free: 15.78 MB / 382.1 MB Notification: Performance of prepare postOptimizeDAE: time 2.132e-05/0.3347, allocations: 12.12 kB / 469.4 MB, free: 15.77 MB / 382.1 MB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 1.123e-05/0.3347, allocations: 4 kB / 469.4 MB, free: 15.76 MB / 382.1 MB Notification: Performance of postOpt tearingSystem (initialization): time 2.488e-05/0.3347, allocations: 8 kB / 469.4 MB, free: 15.75 MB / 382.1 MB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0006125/0.3354, allocations: 163.7 kB / 469.5 MB, free: 15.59 MB / 382.1 MB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 1.859e-05/0.3354, allocations: 15.97 kB / 469.6 MB, free: 15.58 MB / 382.1 MB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.00104/0.3364, allocations: 163.3 kB / 469.7 MB, free: 15.42 MB / 382.1 MB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 5.827e-05/0.3365, allocations: 32 kB / 469.7 MB, free: 15.39 MB / 382.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.0008984/0.3374, allocations: 0.5624 MB / 470.3 MB, free: 14.82 MB / 382.1 MB Notification: Performance of postOpt lateInlineFunction (simulation): time 0.0002868/0.3377, allocations: 186.8 kB / 470.5 MB, free: 14.63 MB / 382.1 MB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.001399/0.3391, allocations: 0.7001 MB / 471.2 MB, free: 13.93 MB / 382.1 MB Notification: Performance of postOpt inlineArrayEqn (simulation): time 8.476e-06/0.3391, allocations: 7.938 kB / 471.2 MB, free: 13.92 MB / 382.1 MB Notification: Performance of postOpt constantLinearSystem (simulation): time 5.2e-06/0.3391, allocations: 4 kB / 471.2 MB, free: 13.91 MB / 382.1 MB Notification: Performance of postOpt simplifysemiLinear (simulation): time 7.685e-06/0.3391, allocations: 3.984 kB / 471.2 MB, free: 13.91 MB / 382.1 MB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.003494/0.3426, allocations: 2.101 MB / 473.3 MB, free: 11.74 MB / 382.1 MB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 5.08e-06/0.3426, allocations: 0 / 473.3 MB, free: 11.74 MB / 382.1 MB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.0005038/0.3431, allocations: 116 kB / 473.4 MB, free: 11.63 MB / 382.1 MB Notification: Performance of postOpt tearingSystem (simulation): time 5.421e-06/0.3431, allocations: 0 / 473.4 MB, free: 11.63 MB / 382.1 MB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 4.386e-05/0.3431, allocations: 19.94 kB / 473.4 MB, free: 11.61 MB / 382.1 MB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 4.609e-06/0.3431, allocations: 0 / 473.4 MB, free: 11.61 MB / 382.1 MB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 2.184e-06/0.3431, allocations: 0 / 473.4 MB, free: 11.61 MB / 382.1 MB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.001895/0.345, allocations: 1.056 MB / 474.5 MB, free: 10.52 MB / 382.1 MB Notification: Performance of postOpt removeConstants (simulation): time 0.0008316/0.3459, allocations: 338.6 kB / 474.8 MB, free: 10.19 MB / 382.1 MB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 0.0001736/0.346, allocations: 16.11 kB / 474.8 MB, free: 10.17 MB / 382.1 MB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0009699/0.347, allocations: 139.8 kB / 475 MB, free: 10.04 MB / 382.1 MB Notification: Performance of postOpt findZeroCrossings (simulation): time 0.0003029/0.3473, allocations: 159.7 kB / 475.1 MB, free: 9.879 MB / 382.1 MB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 4.059e-05/0.3474, allocations: 16 kB / 475.1 MB, free: 9.863 MB / 382.1 MB Notification: Performance of sorting global known variables: time 0.002881/0.3502, allocations: 1.964 MB / 477.1 MB, free: 7.879 MB / 382.1 MB Notification: Performance of sort global known variables: time 2e-07/0.3502, allocations: 4 kB / 477.1 MB, free: 7.875 MB / 382.1 MB Notification: Performance of remove unused functions: time 0.00104/0.3513, allocations: 323.3 kB / 477.4 MB, free: 7.559 MB / 382.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.003868/0.3551, allocations: 1.958 MB / 479.4 MB, free: 5.75 MB / 382.1 MB Notification: Performance of simCode: created initialization part: time 0.001306/0.3564, allocations: 0.581 MB / 480 MB, free: 5.172 MB / 382.1 MB Notification: Performance of simCode: created event and clocks part: time 8.476e-06/0.3565, allocations: 7.938 kB / 480 MB, free: 5.164 MB / 382.1 MB Notification: Performance of simCode: created simulation system equations: time 0.0006413/0.3571, allocations: 332.4 kB / 480.3 MB, free: 4.84 MB / 382.1 MB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.001623/0.3587, allocations: 330 kB / 480.6 MB, free: 4.52 MB / 382.1 MB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.02678/0.3855, allocations: 17.26 MB / 497.9 MB, free: 2.879 MB / 398.1 MB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.001175/0.3867, allocations: 1.444 MB / 499.3 MB, free: 1.402 MB / 398.1 MB Notification: Performance of simCode: alias equations: time 0.0009172/0.3876, allocations: 291.1 kB / 499.6 MB, free: 1.113 MB / 398.1 MB Notification: Performance of simCode: all other stuff during SimCode phase: time 0.0009678/0.3886, allocations: 0.714 MB / 0.4886 GB, free: 408 kB / 398.1 MB Notification: Performance of SimCode: time 1.423e-06/0.3886, allocations: 0 / 0.4886 GB, free: 408 kB / 398.1 MB Notification: Performance of buildModelFMU: Generate the FMI files: time 0.08639/0.4749, allocations: 39.59 MB / 0.5273 GB, free: 9.082 MB / 446.1 MB Notification: Performance of buildModelFMU: Generate platform static: time 14.72/15.19, allocations: 6.406 kB / 0.5273 GB, free: 9.082 MB / 446.1 MB " [Timeout remaining time 645] (rm -f Modelica_4.1.0_Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge.pipe ; mkfifo Modelica_4.1.0_Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge.pipe ; head -c 1048576 < Modelica_4.1.0_Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge.pipe >> ../files/Modelica_4.1.0_Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge.sim & python3 -m fmpy simulate --output-file Modelica_4.1.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_1_0_Modelica_Electrical_Batteries_Examples_BatteryDischargeCharge.fmu > Modelica_4.1.0_Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge.pipe 2>&1) [Timeout 52.5] diffSimulationResults("Modelica_4.1.0_Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge_res.csv","/var/lib/jenkins1/ws/OpenModelicaLibraryTestingWork/Reference-modelica.org/ReferenceResults/MAP-LIB_ReferenceResults/v4.1.0/Modelica/Electrical/Batteries/Examples/BatteryDischargeCharge/BatteryDischargeCharge.csv","/var/lib/jenkins1/ws/OpenModelicaLibraryTestingWork/OpenModelicaLibraryTesting/files/Modelica_4.1.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.1.0_Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge_res.csv. Warning: Get data of variable energy2.y from file Modelica_4.1.0_Modelica.Electrical.Batteries.Examples.BatteryDischargeCharge_res.csv failed! " [Timeout remaining time 660] Reference file matches [Calling sys.exit(0), Time elapsed: 19.17485642399697]