Running: ./testmodel.py --libraries=/home/hudson/saved_omc/libraries/.openmodelica/libraries/ --ompython_omhome=/usr Buildings_latest_Buildings.Fluid.HeatPumps.Validation.ReciprocatingWaterToWater_ScalingFactor.conf.json loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 4.0.0+maint.om/package.mo", uses=false) loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 4.0.0+maint.om/package.mo", uses=false) loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 4.0.0+maint.om/package.mo", uses=false) loadFile("/home/hudson/saved_omc/libraries/.openmodelica/libraries/Buildings 10.0.0-master/package.mo", uses=false) Using package Buildings with version 10.0.0 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/Buildings 10.0.0-master/package.mo) 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(Buildings.Fluid.HeatPumps.Validation.ReciprocatingWaterToWater_ScalingFactor,fileNamePrefix="Buildings_latest_Buildings_Fluid_HeatPumps_Validation_ReciprocatingWaterToWater_ScalingFactor",fmuType="me",version="2.0",platforms={"static"}) "" <> buildModelFMU(Buildings.Fluid.HeatPumps.Validation.ReciprocatingWaterToWater_ScalingFactor,fileNamePrefix="Buildings_latest_Buildings_Fluid_HeatPumps_Validation_ReciprocatingWaterToWater_ScalingFactor",fmuType="me",version="2.0",platforms={"static"}) Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/ModelicaServices 4.0.0+maint.om/package.mo): time 0.001085/0.001085, allocations: 100 kB / 15.05 MB, free: 1.105 MB / 14.72 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 4.0.0+maint.om/package.mo): time 0.00135/0.00135, allocations: 177.3 kB / 15.95 MB, free: 216 kB / 14.72 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 4.0.0+maint.om/package.mo): time 1.332/1.332, allocations: 223.2 MB / 239.9 MB, free: 5.457 MB / 190.1 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Buildings 10.0.0-master/package.mo): time 2.297/2.297, allocations: 409.2 MB / 0.6838 GB, free: 0.9961 MB / 0.5294 GB Notification: Performance of FrontEnd - loaded program: time 0.0003231/0.0003231, allocations: 8 kB / 0.8375 GB, free: 6.582 MB / 0.6856 GB Notification: Performance of FrontEnd - Absyn->SCode: time 0.7403/0.7406, allocations: 146.8 MB / 0.9809 GB, free: 6.293 MB / 0.7325 GB Notification: Performance of NFInst.instantiate(Buildings.Fluid.HeatPumps.Validation.ReciprocatingWaterToWater_ScalingFactor): time 0.1057/0.8464, allocations: 109.4 MB / 1.088 GB, free: 8.652 MB / 0.8419 GB Notification: Performance of NFInst.instExpressions: time 0.03403/0.8805, allocations: 21.44 MB / 1.109 GB, free: 3.184 MB / 0.8575 GB Notification: Performance of NFInst.updateImplicitVariability: time 0.004867/0.8854, allocations: 111.2 kB / 1.109 GB, free: 3.074 MB / 0.8575 GB Notification: Performance of NFTyping.typeComponents: time 0.005263/0.8907, allocations: 1.461 MB / 1.11 GB, free: 1.605 MB / 0.8575 GB Notification: Performance of NFTyping.typeBindings: time 0.0153/0.906, allocations: 4.194 MB / 1.114 GB, free: 13.4 MB / 0.8731 GB Notification: Performance of NFTyping.typeClassSections: time 0.01081/0.9169, allocations: 3.121 MB / 1.117 GB, free: 10.33 MB / 0.8731 GB Notification: Performance of NFFlatten.flatten: time 0.01046/0.9273, allocations: 5.103 MB / 1.122 GB, free: 5.219 MB / 0.8731 GB Notification: Performance of NFFlatten.resolveConnections: time 0.003952/0.9313, allocations: 2.28 MB / 1.125 GB, free: 2.902 MB / 0.8731 GB Notification: Performance of NFEvalConstants.evaluate: time 0.005988/0.9373, allocations: 2.413 MB / 1.127 GB, free: 492 kB / 0.8731 GB Notification: Performance of NFSimplifyModel.simplify: time 0.003299/0.9407, allocations: 1.571 MB / 1.128 GB, free: 14.9 MB / 0.8887 GB Notification: Performance of NFPackage.collectConstants: time 0.0006817/0.9414, allocations: 136 kB / 1.129 GB, free: 14.77 MB / 0.8887 GB Notification: Performance of NFFlatten.collectFunctions: time 0.005712/0.9471, allocations: 1.74 MB / 1.13 GB, free: 13.03 MB / 0.8887 GB Notification: Performance of NFScalarize.scalarize: time 0.0009279/0.9481, allocations: 0.568 MB / 1.131 GB, free: 12.46 MB / 0.8887 GB Notification: Performance of NFVerifyModel.verify: time 0.001497/0.9496, allocations: 0.7305 MB / 1.131 GB, free: 11.72 MB / 0.8887 GB Notification: Performance of NFConvertDAE.convert: time 0.006452/0.956, allocations: 4.559 MB / 1.136 GB, free: 7.148 MB / 0.8887 GB Notification: Performance of FrontEnd - DAE generated: time 3.297e-06/0.9561, allocations: 0 / 1.136 GB, free: 7.148 MB / 0.8887 GB Notification: Performance of FrontEnd: time 2.535e-06/0.9561, allocations: 0 / 1.136 GB, free: 7.148 MB / 0.8887 GB Notification: Performance of Transformations before backend: time 0.0001202/0.9562, allocations: 0 / 1.136 GB, free: 7.148 MB / 0.8887 GB Notification: Model statistics after passing the front-end and creating the data structures used by the back-end: * Number of equations: 577 * Number of variables: 577 Notification: Performance of Generate backend data structure: time 0.006673/0.9629, allocations: 3.343 MB / 1.139 GB, free: 3.703 MB / 0.8887 GB Notification: Performance of prepare preOptimizeDAE: time 4.77e-05/0.963, allocations: 8.031 kB / 1.139 GB, free: 3.695 MB / 0.8887 GB Notification: Performance of preOpt introduceOutputAliases (simulation): time 0.0007611/0.9637, allocations: 336.6 kB / 1.14 GB, free: 3.355 MB / 0.8887 GB Notification: Performance of preOpt normalInlineFunction (simulation): time 0.009534/0.9733, allocations: 1.362 MB / 1.141 GB, free: 1.988 MB / 0.8887 GB Notification: Performance of preOpt evaluateParameters (simulation): time 0.006313/0.9796, allocations: 2.717 MB / 1.144 GB, free: 15.19 MB / 0.9044 GB Notification: Performance of preOpt simplifyIfEquations (simulation): time 0.0003003/0.98, allocations: 255.9 kB / 1.144 GB, free: 14.93 MB / 0.9044 GB Notification: Performance of preOpt expandDerOperator (simulation): time 0.0006346/0.9806, allocations: 240 kB / 1.144 GB, free: 14.69 MB / 0.9044 GB Notification: Performance of preOpt clockPartitioning (simulation): time 0.008074/0.9887, allocations: 3.137 MB / 1.147 GB, free: 11.37 MB / 0.9044 GB Notification: Performance of preOpt findStateOrder (simulation): time 5.655e-05/0.9888, allocations: 7.938 kB / 1.147 GB, free: 11.36 MB / 0.9044 GB Notification: Performance of preOpt replaceEdgeChange (simulation): time 0.0003128/0.9891, allocations: 100 kB / 1.147 GB, free: 11.27 MB / 0.9044 GB Notification: Performance of preOpt inlineArrayEqn (simulation): time 8.144e-05/0.9892, allocations: 67.98 kB / 1.147 GB, free: 11.2 MB / 0.9044 GB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.008974/0.9982, allocations: 2.772 MB / 1.15 GB, free: 8.41 MB / 0.9044 GB Warning: The model contains alias variables with redundant start and/or conflicting nominal values. It is recommended to resolve the conflicts, because otherwise the system could be hard to solve. To print the conflicting alias sets and the chosen candidates please use -d=aliasConflicts. Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.02267/1.021, allocations: 13.37 MB / 1.163 GB, free: 10.41 MB / 0.92 GB Notification: Performance of preOpt comSubExp (simulation): time 0.004393/1.025, allocations: 1.419 MB / 1.164 GB, free: 8.992 MB / 0.92 GB Notification: Performance of preOpt evalFunc (simulation): time 0.001975/1.027, allocations: 1.777 MB / 1.166 GB, free: 6.828 MB / 0.92 GB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 0.003582/1.031, allocations: 1.161 MB / 1.167 GB, free: 5.605 MB / 0.92 GB Notification: Performance of pre-optimization done (n=126): time 4.037e-06/1.031, allocations: 0 / 1.167 GB, free: 5.605 MB / 0.92 GB Notification: Performance of matching and sorting (n=126): time 0.02156/1.053, allocations: 4.248 MB / 1.171 GB, free: 1.305 MB / 0.92 GB Notification: Performance of inlineWhenForInitialization (initialization): time 0.0003452/1.053, allocations: 0.5766 MB / 1.172 GB, free: 0.5938 MB / 0.92 GB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.004984/1.058, allocations: 2.587 MB / 1.174 GB, free: 13.99 MB / 0.9356 GB Notification: Performance of collectPreVariables (initialization): time 0.0004815/1.059, allocations: 65.7 kB / 1.175 GB, free: 13.92 MB / 0.9356 GB Notification: Performance of collectInitialEqns (initialization): time 0.001387/1.06, allocations: 1.328 MB / 1.176 GB, free: 12.57 MB / 0.9356 GB Notification: Performance of collectInitialBindings (initialization): time 0.0007653/1.061, allocations: 457.6 kB / 1.176 GB, free: 12.12 MB / 0.9356 GB Notification: Performance of simplifyInitialFunctions (initialization): time 0.00016/1.061, allocations: 36 kB / 1.176 GB, free: 12.09 MB / 0.9356 GB Notification: Performance of setup shared object (initialization): time 0.0002085/1.061, allocations: 365.9 kB / 1.177 GB, free: 11.72 MB / 0.9356 GB Notification: Performance of preBalanceInitialSystem (initialization): time 0.003654/1.065, allocations: 0.9603 MB / 1.178 GB, free: 10.76 MB / 0.9356 GB Notification: Performance of partitionIndependentBlocks (initialization): time 0.004254/1.069, allocations: 1.544 MB / 1.179 GB, free: 8.98 MB / 0.9356 GB Notification: Performance of analyzeInitialSystem (initialization): time 0.003941/1.073, allocations: 1.105 MB / 1.18 GB, free: 7.867 MB / 0.9356 GB Notification: Performance of solveInitialSystemEqSystem (initialization): time 1.619e-05/1.073, allocations: 4 kB / 1.18 GB, free: 7.863 MB / 0.9356 GB Notification: Performance of matching and sorting (n=223) (initialization): time 0.01243/1.086, allocations: 3.112 MB / 1.183 GB, free: 4.727 MB / 0.9356 GB Notification: Performance of prepare postOptimizeDAE: time 0.002344/1.088, allocations: 5.013 MB / 1.188 GB, free: 15.29 MB / 0.9512 GB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 3.058e-05/1.088, allocations: 12 kB / 1.188 GB, free: 15.28 MB / 0.9512 GB Notification: Performance of postOpt tearingSystem (initialization): time 0.002769/1.091, allocations: 0.7306 MB / 1.189 GB, free: 14.55 MB / 0.9512 GB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.002931/1.094, allocations: 0.507 MB / 1.189 GB, free: 14.04 MB / 0.9512 GB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 0.002465/1.096, allocations: 1.799 MB / 1.191 GB, free: 12.2 MB / 0.9512 GB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.004981/1.101, allocations: 0.5051 MB / 1.192 GB, free: 11.69 MB / 0.9512 GB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 0.0004171/1.102, allocations: 111.9 kB / 1.192 GB, free: 11.58 MB / 0.9512 GB Notification: Performance of prepare postOptimizeDAE: time 1.715e-05/1.102, allocations: 7.938 kB / 1.192 GB, free: 11.57 MB / 0.9512 GB Notification: Performance of postOpt replaceHomotopyWithSimplified (initialization): time 0.01113/1.113, allocations: 2.837 MB / 1.194 GB, free: 8.719 MB / 0.9512 GB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 3.295e-05/1.113, allocations: 12 kB / 1.194 GB, free: 8.707 MB / 0.9512 GB Notification: Performance of postOpt tearingSystem (initialization): time 0.002396/1.115, allocations: 0.7232 MB / 1.195 GB, free: 7.988 MB / 0.9512 GB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.002751/1.118, allocations: 0.5031 MB / 1.196 GB, free: 7.484 MB / 0.9512 GB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 0.002315/1.12, allocations: 1.792 MB / 1.197 GB, free: 5.645 MB / 0.9512 GB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.004323/1.125, allocations: 462 kB / 1.198 GB, free: 5.191 MB / 0.9512 GB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 0.0002817/1.125, allocations: 99.91 kB / 1.198 GB, free: 5.094 MB / 0.9512 GB Notification: Model statistics after passing the back-end for initialization: * Number of independent subsystems: 53 * Number of states: 0 () * Number of discrete variables: 10 ($whenCondition1,$PRE.heaPum.com.isOn,heaPum.com.isOn,$PRE.heaPum1.com.isOn,heaPum1.com.isOn,$PRE.N.T_start,N.T_start,$PRE.N.count,N.count,realToInteger.y) * Number of discrete states: 0 () * Number of clocked states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for initialization (186): * Single equations (assignments): 183 * Array equations: 0 * Algorithm blocks: 1 * Record equations: 0 * When equations: 0 * If-equations: 0 * Equation systems (linear and non-linear blocks): 0 * Torn equation systems: 2 * Mixed (continuous/discrete) equation systems: 0 Notification: Torn system details for strict tearing set: * Linear torn systems: 0 * Non-linear torn systems: 2 {2 17,2 17} Notification: Performance of prepare postOptimizeDAE: time 0.001668/1.127, allocations: 0.7016 MB / 1.199 GB, free: 4.383 MB / 0.9512 GB Notification: Performance of postOpt lateInlineFunction (simulation): time 0.0006807/1.127, allocations: 276.7 kB / 1.199 GB, free: 4.109 MB / 0.9512 GB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.0108/1.138, allocations: 2.597 MB / 1.201 GB, free: 1.5 MB / 0.9512 GB Notification: Performance of postOpt inlineArrayEqn (simulation): time 3.29e-05/1.138, allocations: 12 kB / 1.201 GB, free: 1.488 MB / 0.9512 GB Notification: Performance of postOpt constantLinearSystem (simulation): time 1.468e-05/1.138, allocations: 4 kB / 1.201 GB, free: 1.484 MB / 0.9512 GB Notification: Performance of postOpt simplifysemiLinear (simulation): time 0.00968/1.148, allocations: 2.216 MB / 1.204 GB, free: 15.21 MB / 0.9669 GB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.01568/1.164, allocations: 6.545 MB / 1.21 GB, free: 8.496 MB / 0.9669 GB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 1.733e-05/1.164, allocations: 8.062 kB / 1.21 GB, free: 8.488 MB / 0.9669 GB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.001722/1.166, allocations: 299.5 kB / 1.21 GB, free: 8.195 MB / 0.9669 GB Notification: Performance of postOpt tearingSystem (simulation): time 0.002264/1.168, allocations: 0.7048 MB / 1.211 GB, free: 7.496 MB / 0.9669 GB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 0.0001428/1.168, allocations: 51.94 kB / 1.211 GB, free: 7.445 MB / 0.9669 GB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 0.002104/1.17, allocations: 1.797 MB / 1.213 GB, free: 5.598 MB / 0.9669 GB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 1.065e-05/1.17, allocations: 11.94 kB / 1.213 GB, free: 5.586 MB / 0.9669 GB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.01173/1.182, allocations: 4.281 MB / 1.217 GB, free: 0.832 MB / 0.9669 GB Notification: Performance of postOpt removeConstants (simulation): time 0.001959/1.184, allocations: 0.6885 MB / 1.218 GB, free: 124 kB / 0.9669 GB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 0.0005002/1.184, allocations: 39.98 kB / 1.218 GB, free: 84 kB / 0.9669 GB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.003156/1.187, allocations: 275.5 kB / 1.218 GB, free: 15.81 MB / 0.9825 GB Notification: Performance of postOpt findZeroCrossings (simulation): time 0.0001917/1.188, allocations: 116.7 kB / 1.218 GB, free: 15.7 MB / 0.9825 GB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 0.0001464/1.188, allocations: 76.02 kB / 1.218 GB, free: 15.62 MB / 0.9825 GB Notification: Performance of sorting global known variables: time 0.002896/1.191, allocations: 1.817 MB / 1.22 GB, free: 13.8 MB / 0.9825 GB Notification: Performance of sort global known variables: time 1.8e-07/1.191, allocations: 0 / 1.22 GB, free: 13.8 MB / 0.9825 GB Notification: Performance of remove unused functions: time 0.004668/1.195, allocations: 1.692 MB / 1.222 GB, free: 12.11 MB / 0.9825 GB Notification: Model statistics after passing the back-end for simulation: * Number of independent subsystems: 33 * Number of states: 4 (heaPum.con.vol.dynBal.U,heaPum.eva.vol.dynBal.U,heaPum1.con.vol.dynBal.U,heaPum1.eva.vol.dynBal.U) * Number of discrete variables: 6 ($whenCondition1,heaPum.com.isOn,heaPum1.com.isOn,N.T_start,N.count,realToInteger.y) * Number of discrete states: 3 (N.count,heaPum1.com.isOn,heaPum.com.isOn) * Number of clocked states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for simulation (88): * Single equations (assignments): 82 * Array equations: 0 * Algorithm blocks: 0 * Record equations: 2 * When equations: 2 * If-equations: 0 * Equation systems (linear and non-linear blocks): 0 * Torn equation systems: 2 * Mixed (continuous/discrete) equation systems: 0 Notification: Torn system details for strict tearing set: * Linear torn systems: 0 * Non-linear torn systems: 2 {2 17,2 17} Notification: Performance of Backend phase and start with SimCode phase: time 0.01333/1.209, allocations: 7.403 MB / 1.229 GB, free: 4.469 MB / 0.9825 GB Notification: Performance of simCode: created initialization part: time 0.01145/1.22, allocations: 3.593 MB / 1.232 GB, free: 0.8555 MB / 0.9825 GB Notification: Performance of simCode: created event and clocks part: time 1.449e-05/1.22, allocations: 1.562 kB / 1.232 GB, free: 0.8555 MB / 0.9825 GB Notification: Performance of simCode: created simulation system equations: time 0.003391/1.224, allocations: 1.054 MB / 1.233 GB, free: 15.8 MB / 0.9981 GB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.006845/1.231, allocations: 1.368 MB / 1.235 GB, free: 14.46 MB / 0.9981 GB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.4174/1.648, allocations: 15.78 MB / 1.25 GB, free: 252.1 MB / 0.9981 GB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.001415/1.649, allocations: 1.764 MB / 1.252 GB, free: 251.3 MB / 0.9981 GB Notification: Performance of simCode: alias equations: time 0.003306/1.653, allocations: 0.7048 MB / 1.253 GB, free: 251.3 MB / 0.9981 GB Notification: Performance of simCode: all other stuff during SimCode phase: time 0.001448/1.654, allocations: 1.162 MB / 1.254 GB, free: 251.3 MB / 0.9981 GB Notification: Performance of SimCode: time 9.62e-07/1.654, allocations: 0 / 1.254 GB, free: 251.3 MB / 0.9981 GB Notification: Performance of buildModelFMU: Generate the FMI files: time 0.8624/2.517, allocations: 88.99 MB / 1.341 GB, free: 181.1 MB / 0.9981 GB Notification: Performance of buildModelFMU: configured platform static using cached values: time 0.0001892/2.517, allocations: 284.7 kB / 1.341 GB, free: 180.7 MB / 0.9981 GB Notification: Performance of buildModelFMU: Generate platform static: time 5.674/8.191, allocations: 4 kB / 1.341 GB, free: 180.7 MB / 0.9981 GB (rm -f Buildings_latest_Buildings.Fluid.HeatPumps.Validation.ReciprocatingWaterToWater_ScalingFactor.pipe ; mkfifo Buildings_latest_Buildings.Fluid.HeatPumps.Validation.ReciprocatingWaterToWater_ScalingFactor.pipe ; head -c 1048576 < Buildings_latest_Buildings.Fluid.HeatPumps.Validation.ReciprocatingWaterToWater_ScalingFactor.pipe >> ../files/Buildings_latest_Buildings.Fluid.HeatPumps.Validation.ReciprocatingWaterToWater_ScalingFactor.sim & /home/hudson/saved_omc/OMSimulator/install/linux/bin/OMSimulator -r=Buildings_latest_Buildings.Fluid.HeatPumps.Validation.ReciprocatingWaterToWater_ScalingFactor_res.mat --tempDir=temp_Buildings_latest_Buildings_Fluid_HeatPumps_Validation_ReciprocatingWaterToWater_ScalingFactor_fmu --startTime=0 --stopTime=1000 --timeout=50 --tolerance=1e-06 Buildings_latest_Buildings_Fluid_HeatPumps_Validation_ReciprocatingWaterToWater_ScalingFactor.fmu > Buildings_latest_Buildings.Fluid.HeatPumps.Validation.ReciprocatingWaterToWater_ScalingFactor.pipe 2>&1) Environment - environmentSimulation: TODO: How the !@#!# did the simulation report success but simulation result Buildings_latest_Buildings.Fluid.HeatPumps.Validation.ReciprocatingWaterToWater_ScalingFactor_res.mat does not exist to compare? outputFormat=mat