Running: ./testmodel.py --libraries=/home/hudson/saved_omc/libraries/.openmodelica/libraries --ompython_omhome=/usr Buildings_10_Buildings.Fluid.Actuators.Valves.Examples.ThreeWayValves.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.1.1-maint.10.0.x/package.mo", uses=false) Using package Buildings with version 10.1.1 (/home/hudson/saved_omc/libraries/.openmodelica/libraries/Buildings 10.1.1-maint.10.0.x/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.Actuators.Valves.Examples.ThreeWayValves,fileNamePrefix="Buildings_10_Buildings_Fluid_Actuators_Valves_Examples_ThreeWayValves",fmuType="me",version="2.0",platforms={"static"}) "" <> buildModelFMU(Buildings.Fluid.Actuators.Valves.Examples.ThreeWayValves,fileNamePrefix="Buildings_10_Buildings_Fluid_Actuators_Valves_Examples_ThreeWayValves",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.004848/0.004848, allocations: 98.66 kB / 15.73 MB, free: 6.066 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.001322/0.001322, allocations: 196.1 kB / 16.68 MB, free: 5.973 MB / 14.72 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Modelica 4.0.0+maint.om/package.mo): time 1.288/1.288, allocations: 222.9 MB / 240.4 MB, free: 15.16 MB / 206.1 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Buildings 10.1.1-maint.10.0.x/package.mo): time 2.225/2.225, allocations: 437.1 MB / 0.7105 GB, free: 4.391 MB / 0.5762 GB Notification: Performance of FrontEnd - loaded program: time 0.00165/0.00165, allocations: 67.84 kB / 1.018 GB, free: 9.867 MB / 0.795 GB Notification: Performance of FrontEnd - Absyn->SCode: time 0.5904/0.5921, allocations: 151.6 MB / 1.166 GB, free: 3.777 MB / 0.8887 GB Notification: Performance of NFInst.instantiate(Buildings.Fluid.Actuators.Valves.Examples.ThreeWayValves): time 0.1006/0.6927, allocations: 112.7 MB / 1.276 GB, free: 2.73 MB / 0.9981 GB Notification: Performance of NFInst.instExpressions: time 0.02491/0.7176, allocations: 20.24 MB / 1.296 GB, free: 14.45 MB / 1.029 GB Notification: Performance of NFInst.updateImplicitVariability: time 0.001809/0.7195, allocations: 107.3 kB / 1.296 GB, free: 14.34 MB / 1.029 GB Notification: Performance of NFTyping.typeComponents: time 0.002432/0.7219, allocations: 1.277 MB / 1.297 GB, free: 13.05 MB / 1.029 GB Notification: Performance of NFTyping.typeBindings: time 0.006368/0.7283, allocations: 3.68 MB / 1.301 GB, free: 9.359 MB / 1.029 GB Notification: Performance of NFTyping.typeClassSections: time 0.00556/0.7339, allocations: 3.12 MB / 1.304 GB, free: 6.277 MB / 1.029 GB Notification: Performance of NFFlatten.flatten: time 0.0067/0.7406, allocations: 7.21 MB / 1.311 GB, free: 15.04 MB / 1.045 GB Notification: Performance of NFFlatten.resolveConnections: time 0.00262/0.7432, allocations: 2.582 MB / 1.314 GB, free: 12.4 MB / 1.045 GB Notification: Performance of NFEvalConstants.evaluate: time 0.004111/0.7473, allocations: 2.813 MB / 1.316 GB, free: 9.59 MB / 1.045 GB Notification: Performance of NFSimplifyModel.simplify: time 0.00227/0.7496, allocations: 2.131 MB / 1.318 GB, free: 7.449 MB / 1.045 GB Notification: Performance of NFPackage.collectConstants: time 0.0003352/0.75, allocations: 256 kB / 1.319 GB, free: 7.199 MB / 1.045 GB Notification: Performance of NFFlatten.collectFunctions: time 0.002652/0.7526, allocations: 1.65 MB / 1.32 GB, free: 5.547 MB / 1.045 GB Notification: Performance of NFScalarize.scalarize: time 0.0005643/0.7532, allocations: 0.6811 MB / 1.321 GB, free: 4.863 MB / 1.045 GB Notification: Performance of NFVerifyModel.verify: time 0.001277/0.7545, allocations: 1.512 MB / 1.322 GB, free: 3.344 MB / 1.045 GB Notification: Performance of NFConvertDAE.convert: time 0.004243/0.7587, allocations: 4.411 MB / 1.327 GB, free: 14.91 MB / 1.061 GB Notification: Performance of FrontEnd - DAE generated: time 3.026e-06/0.7587, allocations: 0 / 1.327 GB, free: 14.91 MB / 1.061 GB Notification: Performance of FrontEnd: time 3.025e-06/0.7588, allocations: 0 / 1.327 GB, free: 14.91 MB / 1.061 GB Notification: Performance of Transformations before backend: time 2.564e-05/0.7588, allocations: 3.938 kB / 1.327 GB, free: 14.91 MB / 1.061 GB Notification: Model statistics after passing the front-end and creating the data structures used by the back-end: * Number of equations: 379 * Number of variables: 379 Notification: Performance of Generate backend data structure: time 0.0042/0.763, allocations: 3.32 MB / 1.33 GB, free: 11.52 MB / 1.061 GB Notification: Performance of prepare preOptimizeDAE: time 3.092e-05/0.763, allocations: 12.92 kB / 1.33 GB, free: 11.51 MB / 1.061 GB Notification: Performance of preOpt introduceOutputAliases (simulation): time 0.000226/0.7633, allocations: 215.7 kB / 1.33 GB, free: 11.29 MB / 1.061 GB Notification: Performance of preOpt normalInlineFunction (simulation): time 0.0005967/0.7639, allocations: 350 kB / 1.33 GB, free: 10.94 MB / 1.061 GB Notification: Performance of preOpt evaluateParameters (simulation): time 0.003003/0.7669, allocations: 2.219 MB / 1.333 GB, free: 8.652 MB / 1.061 GB Notification: Performance of preOpt simplifyIfEquations (simulation): time 8.977e-05/0.767, allocations: 131 kB / 1.333 GB, free: 8.523 MB / 1.061 GB Notification: Performance of preOpt expandDerOperator (simulation): time 0.0002044/0.7672, allocations: 164 kB / 1.333 GB, free: 8.363 MB / 1.061 GB Notification: Performance of preOpt clockPartitioning (simulation): time 0.002314/0.7695, allocations: 1.623 MB / 1.335 GB, free: 6.676 MB / 1.061 GB Notification: Performance of preOpt findStateOrder (simulation): time 3.041e-05/0.7695, allocations: 0 / 1.335 GB, free: 6.676 MB / 1.061 GB Notification: Performance of preOpt replaceEdgeChange (simulation): time 0.0001178/0.7697, allocations: 64 kB / 1.335 GB, free: 6.613 MB / 1.061 GB Notification: Performance of preOpt inlineArrayEqn (simulation): time 4.391e-05/0.7697, allocations: 43.94 kB / 1.335 GB, free: 6.57 MB / 1.061 GB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.001838/0.7716, allocations: 1.147 MB / 1.336 GB, free: 5.418 MB / 1.061 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.008591/0.7802, allocations: 7.93 MB / 1.343 GB, free: 12.98 MB / 1.076 GB Notification: Performance of preOpt comSubExp (simulation): time 0.000705/0.7809, allocations: 477.9 kB / 1.344 GB, free: 12.5 MB / 1.076 GB Notification: Performance of preOpt resolveLoops (simulation): time 0.0004591/0.7813, allocations: 325.2 kB / 1.344 GB, free: 12.19 MB / 1.076 GB Notification: Performance of preOpt evalFunc (simulation): time 0.0005861/0.7819, allocations: 0.7524 MB / 1.345 GB, free: 11.27 MB / 1.076 GB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 3.722e-05/0.782, allocations: 47.06 kB / 1.345 GB, free: 11.21 MB / 1.076 GB Notification: Performance of pre-optimization done (n=60): time 1.523e-06/0.782, allocations: 4 kB / 1.345 GB, free: 11.21 MB / 1.076 GB Notification: Performance of matching and sorting (n=60): time 0.001645/0.7836, allocations: 0.9934 MB / 1.346 GB, free: 10.21 MB / 1.076 GB Notification: Performance of inlineWhenForInitialization (initialization): time 3.733e-05/0.7837, allocations: 55.97 kB / 1.346 GB, free: 10.14 MB / 1.076 GB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.002613/0.7863, allocations: 2.347 MB / 1.348 GB, free: 7.785 MB / 1.076 GB Notification: Performance of collectPreVariables (initialization): time 6.899e-05/0.7864, allocations: 45.7 kB / 1.348 GB, free: 7.734 MB / 1.076 GB Notification: Performance of collectInitialEqns (initialization): time 0.0009244/0.7873, allocations: 1.175 MB / 1.35 GB, free: 6.551 MB / 1.076 GB Notification: Performance of collectInitialBindings (initialization): time 0.000178/0.7875, allocations: 226.1 kB / 1.35 GB, free: 6.328 MB / 1.076 GB Notification: Performance of simplifyInitialFunctions (initialization): time 0.0003197/0.7878, allocations: 254.8 kB / 1.35 GB, free: 6.07 MB / 1.076 GB Notification: Performance of setup shared object (initialization): time 0.0001405/0.788, allocations: 345.9 kB / 1.35 GB, free: 5.727 MB / 1.076 GB Notification: Performance of preBalanceInitialSystem (initialization): time 0.0006065/0.7886, allocations: 357.9 kB / 1.351 GB, free: 5.375 MB / 1.076 GB Notification: Performance of partitionIndependentBlocks (initialization): time 0.0009176/0.7895, allocations: 0.7541 MB / 1.351 GB, free: 4.465 MB / 1.076 GB Notification: Performance of analyzeInitialSystem (initialization): time 0.00137/0.7909, allocations: 0.9824 MB / 1.352 GB, free: 3.367 MB / 1.076 GB Notification: Performance of solveInitialSystemEqSystem (initialization): time 9.117e-06/0.7909, allocations: 11.94 kB / 1.352 GB, free: 3.355 MB / 1.076 GB Notification: Performance of matching and sorting (n=141) (initialization): time 0.001971/0.7929, allocations: 1.293 MB / 1.354 GB, free: 2.055 MB / 1.076 GB Notification: Performance of prepare postOptimizeDAE: time 1.811e-05/0.7929, allocations: 11.98 kB / 1.354 GB, free: 2.043 MB / 1.076 GB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 1.217e-05/0.7929, allocations: 8 kB / 1.354 GB, free: 2.035 MB / 1.076 GB Notification: Performance of postOpt tearingSystem (initialization): time 2.07e-05/0.793, allocations: 16.03 kB / 1.354 GB, free: 2.02 MB / 1.076 GB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0008564/0.7938, allocations: 255.6 kB / 1.354 GB, free: 1.77 MB / 1.076 GB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 2.293e-05/0.7938, allocations: 19.92 kB / 1.354 GB, free: 1.75 MB / 1.076 GB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.001041/0.7949, allocations: 162.8 kB / 1.354 GB, free: 1.59 MB / 1.076 GB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 8.154e-05/0.795, allocations: 55.98 kB / 1.354 GB, free: 1.535 MB / 1.076 GB Notification: Performance of preBalanceInitialSystem (initialization_lambda0): time 0.001105/0.7961, allocations: 0.7602 MB / 1.355 GB, free: 0.7695 MB / 1.076 GB Notification: Performance of partitionIndependentBlocks (initialization_lambda0): time 0.000889/0.797, allocations: 0.7387 MB / 1.356 GB, free: 15.87 MB / 1.092 GB Notification: Performance of analyzeInitialSystem (initialization_lambda0): time 0.001273/0.7983, allocations: 0.9524 MB / 1.357 GB, free: 14.8 MB / 1.092 GB Notification: Performance of solveInitialSystemEqSystem (initialization_lambda0): time 7.184e-06/0.7983, allocations: 4 kB / 1.357 GB, free: 14.8 MB / 1.092 GB Notification: Performance of matching and sorting (n=141) (initialization_lambda0): time 0.001898/0.8002, allocations: 1.271 MB / 1.358 GB, free: 13.52 MB / 1.092 GB Notification: Performance of prepare postOptimizeDAE: time 1.094e-05/0.8002, allocations: 16.03 kB / 1.358 GB, free: 13.5 MB / 1.092 GB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 9.278e-06/0.8002, allocations: 11.94 kB / 1.358 GB, free: 13.49 MB / 1.092 GB Notification: Performance of postOpt tearingSystem (initialization): time 1.118e-05/0.8002, allocations: 12 kB / 1.358 GB, free: 13.48 MB / 1.092 GB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0008103/0.8011, allocations: 247.6 kB / 1.358 GB, free: 13.23 MB / 1.092 GB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 1.912e-05/0.8011, allocations: 19.94 kB / 1.358 GB, free: 13.21 MB / 1.092 GB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.001091/0.8022, allocations: 127.3 kB / 1.358 GB, free: 13.09 MB / 1.092 GB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 7.604e-05/0.8023, allocations: 55.98 kB / 1.358 GB, free: 13.04 MB / 1.092 GB Notification: Model statistics after passing the back-end for initialization: * Number of independent subsystems: 37 * Number of states: 0 () * Number of discrete variables: 0 () * Number of discrete states: 0 () * Number of clocked states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for initialization (141): * Single equations (assignments): 141 * 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.0001924/0.8025, allocations: 247.9 kB / 1.358 GB, free: 12.79 MB / 1.092 GB Notification: Performance of postOpt lateInlineFunction (simulation): time 0.000301/0.8028, allocations: 246.4 kB / 1.359 GB, free: 12.54 MB / 1.092 GB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 0.001463/0.8042, allocations: 0.8896 MB / 1.36 GB, free: 11.63 MB / 1.092 GB Notification: Performance of postOpt inlineArrayEqn (simulation): time 1.13e-05/0.8043, allocations: 7.984 kB / 1.36 GB, free: 11.62 MB / 1.092 GB Notification: Performance of postOpt constantLinearSystem (simulation): time 5.791e-06/0.8043, allocations: 4 kB / 1.36 GB, free: 11.62 MB / 1.092 GB Notification: Performance of postOpt simplifysemiLinear (simulation): time 0.0009608/0.8052, allocations: 0.6775 MB / 1.36 GB, free: 10.91 MB / 1.092 GB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.003179/0.8084, allocations: 2.593 MB / 1.363 GB, free: 8.246 MB / 1.092 GB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 2.765e-06/0.8084, allocations: 0 / 1.363 GB, free: 8.246 MB / 1.092 GB Notification: Performance of postOpt solveSimpleEquations (simulation): time 0.0004657/0.8089, allocations: 123.8 kB / 1.363 GB, free: 8.125 MB / 1.092 GB Notification: Performance of postOpt tearingSystem (simulation): time 4.89e-06/0.8089, allocations: 4 kB / 1.363 GB, free: 8.121 MB / 1.092 GB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 4.002e-05/0.809, allocations: 19.98 kB / 1.363 GB, free: 8.102 MB / 1.092 GB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 4.348e-06/0.809, allocations: 4 kB / 1.363 GB, free: 8.098 MB / 1.092 GB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 2.865e-06/0.809, allocations: 4 kB / 1.363 GB, free: 8.094 MB / 1.092 GB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.001806/0.8108, allocations: 1.323 MB / 1.364 GB, free: 6.738 MB / 1.092 GB Notification: Performance of postOpt removeConstants (simulation): time 0.0005245/0.8113, allocations: 431.3 kB / 1.365 GB, free: 6.297 MB / 1.092 GB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 0.0001986/0.8115, allocations: 16 kB / 1.365 GB, free: 6.281 MB / 1.092 GB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0007941/0.8123, allocations: 47.88 kB / 1.365 GB, free: 6.234 MB / 1.092 GB Notification: Performance of postOpt findZeroCrossings (simulation): time 9.091e-05/0.8124, allocations: 48.39 kB / 1.365 GB, free: 6.184 MB / 1.092 GB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 5.69e-05/0.8125, allocations: 31.97 kB / 1.365 GB, free: 6.152 MB / 1.092 GB Notification: Performance of sorting global known variables: time 0.001881/0.8144, allocations: 1.569 MB / 1.366 GB, free: 4.578 MB / 1.092 GB Notification: Performance of sort global known variables: time 1.5e-07/0.8144, allocations: 0 / 1.366 GB, free: 4.578 MB / 1.092 GB Notification: Performance of remove unused functions: time 0.00194/0.8163, allocations: 1.119 MB / 1.367 GB, free: 3.457 MB / 1.092 GB Notification: Model statistics after passing the back-end for simulation: * Number of independent subsystems: 4 * Number of states: 3 (valLin.vol.dynBal.U,valEquPerLin.vol.dynBal.U,valTab.vol.dynBal.U) * Number of discrete variables: 0 () * Number of discrete states: 0 () * Number of clocked states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for simulation (64): * Single equations (assignments): 61 * Array equations: 0 * Algorithm blocks: 0 * Record equations: 3 * 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.003791/0.8201, allocations: 2.536 MB / 1.37 GB, free: 0.9922 MB / 1.092 GB Notification: Performance of simCode: created initialization part: time 0.002033/0.8222, allocations: 1.351 MB / 1.371 GB, free: 15.65 MB / 1.107 GB Notification: Performance of simCode: created event and clocks part: time 4.087e-06/0.8222, allocations: 4 kB / 1.371 GB, free: 15.65 MB / 1.107 GB Notification: Performance of simCode: created simulation system equations: time 0.0004861/0.8227, allocations: 327.5 kB / 1.372 GB, free: 15.32 MB / 1.107 GB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.004766/0.8275, allocations: 1.377 MB / 1.373 GB, free: 13.98 MB / 1.107 GB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.01873/0.8462, allocations: 14.99 MB / 1.387 GB, free: 14.52 MB / 1.123 GB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.001143/0.8473, allocations: 1.593 MB / 1.389 GB, free: 12.9 MB / 1.123 GB Notification: Performance of simCode: alias equations: time 0.001278/0.8486, allocations: 498.7 kB / 1.39 GB, free: 12.41 MB / 1.123 GB Notification: Performance of simCode: all other stuff during SimCode phase: time 0.001086/0.8497, allocations: 0.9601 MB / 1.39 GB, free: 11.45 MB / 1.123 GB Notification: Performance of SimCode: time 3.3e-07/0.8497, allocations: 0 / 1.39 GB, free: 11.45 MB / 1.123 GB Notification: Performance of buildModelFMU: Generate the FMI files: time 17.59/18.44, allocations: 64.29 MB / 1.453 GB, free: 11.76 MB / 1.186 GB Notification: Performance of buildModelFMU: Generate platform static: time 12.77/31.21, allocations: 15.58 kB / 1.453 GB, free: 11.75 MB / 1.186 GB (rm -f Buildings_10_Buildings.Fluid.Actuators.Valves.Examples.ThreeWayValves.pipe ; mkfifo Buildings_10_Buildings.Fluid.Actuators.Valves.Examples.ThreeWayValves.pipe ; head -c 1048576 < Buildings_10_Buildings.Fluid.Actuators.Valves.Examples.ThreeWayValves.pipe >> ../files/Buildings_10_Buildings.Fluid.Actuators.Valves.Examples.ThreeWayValves.sim & /home/hudson/saved_omc/OMSimulator/install/bin/OMSimulator -r=Buildings_10_Buildings.Fluid.Actuators.Valves.Examples.ThreeWayValves_res.mat --tempDir=temp_Buildings_10_Buildings_Fluid_Actuators_Valves_Examples_ThreeWayValves_fmu --startTime=0 --stopTime=1 --timeout=400 --tolerance=1e-06 Buildings_10_Buildings_Fluid_Actuators_Valves_Examples_ThreeWayValves.fmu > Buildings_10_Buildings.Fluid.Actuators.Valves.Examples.ThreeWayValves.pipe 2>&1) diffSimulationResults("Buildings_10_Buildings.Fluid.Actuators.Valves.Examples.ThreeWayValves_res.mat","/mnt/ReferenceFiles/Buildings/csv/maint_10.0.x/Buildings_Fluid_Actuators_Valves_Examples_ThreeWayValves.csv","/var/lib/jenkins1/ws/OpenModelicaLibraryTestingWork/OpenModelicaLibraryTesting/files/Buildings_10_Buildings.Fluid.Actuators.Valves.Examples.ThreeWayValves.diff",relTol=0.003,relTolDiffMinMax=0.003,rangeDelta=0.001) Reference file matches