Running: ./testmodel.py --libraries=/home/hudson/saved_omc/libraries/.openmodelica/libraries --ompython_omhome=/usr Buildings_10_Buildings.Controls.OBC.CDL.Logical.Sources.Validation.TimeTableNegativeStartTime.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.Controls.OBC.CDL.Logical.Sources.Validation.TimeTableNegativeStartTime,fileNamePrefix="Buildings_10_Buildings_Controls_OBC_CDL_Logical_Sources_Validation_TimeTableNegativeStartTime",fmuType="me",version="2.0",platforms={"static"}) "" <> buildModelFMU(Buildings.Controls.OBC.CDL.Logical.Sources.Validation.TimeTableNegativeStartTime,fileNamePrefix="Buildings_10_Buildings_Controls_OBC_CDL_Logical_Sources_Validation_TimeTableNegativeStartTime",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.001079/0.001079, allocations: 108 kB / 15.6 MB, free: 132 kB / 14.72 MB Notification: Performance of loadFile(/home/hudson/saved_omc/libraries/.openmodelica/libraries/Complex 4.0.0+maint.om/package.mo): time 0.001103/0.001103, allocations: 194.7 kB / 16.53 MB, free: 6.391 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.349/1.349, allocations: 222.9 MB / 240.2 MB, free: 4.398 MB / 190.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.556/2.556, allocations: 437.1 MB / 0.7104 GB, free: 5.055 MB / 0.5606 GB Notification: Performance of FrontEnd - loaded program: time 0.001526/0.001527, allocations: 67.91 kB / 0.8694 GB, free: 4.516 MB / 0.7169 GB Notification: Performance of FrontEnd - Absyn->SCode: time 0.6283/0.6298, allocations: 151.6 MB / 1.017 GB, free: 2.461 MB / 0.7637 GB Notification: Performance of NFInst.instantiate(Buildings.Controls.OBC.CDL.Logical.Sources.Validation.TimeTableNegativeStartTime): time 0.001989/0.6318, allocations: 0.8672 MB / 1.018 GB, free: 1.59 MB / 0.7637 GB Notification: Performance of NFInst.instExpressions: time 0.001656/0.6335, allocations: 1.459 MB / 1.02 GB, free: 116 kB / 0.7637 GB Notification: Performance of NFInst.updateImplicitVariability: time 7.286e-05/0.6336, allocations: 7.938 kB / 1.02 GB, free: 108 kB / 0.7637 GB Notification: Performance of NFTyping.typeComponents: time 0.0004299/0.634, allocations: 191.5 kB / 1.02 GB, free: 15.92 MB / 0.7794 GB Notification: Performance of NFTyping.typeBindings: time 0.0001315/0.6342, allocations: 115.6 kB / 1.02 GB, free: 15.8 MB / 0.7794 GB Notification: Performance of NFTyping.typeClassSections: time 0.0008606/0.635, allocations: 357.6 kB / 1.02 GB, free: 15.46 MB / 0.7794 GB Notification: Performance of NFFlatten.flatten: time 0.000744/0.6358, allocations: 0.8543 MB / 1.021 GB, free: 14.61 MB / 0.7794 GB Notification: Performance of NFFlatten.resolveConnections: time 0.0001751/0.636, allocations: 96.22 kB / 1.021 GB, free: 14.51 MB / 0.7794 GB Notification: Performance of NFEvalConstants.evaluate: time 0.0002841/0.6363, allocations: 347.5 kB / 1.022 GB, free: 14.17 MB / 0.7794 GB Notification: Performance of NFSimplifyModel.simplify: time 0.0003214/0.6366, allocations: 263.2 kB / 1.022 GB, free: 13.91 MB / 0.7794 GB Notification: Performance of NFPackage.collectConstants: time 0.0001439/0.6367, allocations: 48 kB / 1.022 GB, free: 13.86 MB / 0.7794 GB Notification: Performance of NFFlatten.collectFunctions: time 0.0002531/0.637, allocations: 107.9 kB / 1.022 GB, free: 13.76 MB / 0.7794 GB Notification: Performance of NFScalarize.scalarize: time 0.0003891/0.6374, allocations: 343.3 kB / 1.022 GB, free: 13.42 MB / 0.7794 GB Notification: Performance of NFVerifyModel.verify: time 0.0002876/0.6377, allocations: 270.8 kB / 1.023 GB, free: 13.16 MB / 0.7794 GB Notification: Performance of NFConvertDAE.convert: time 0.0007464/0.6384, allocations: 0.9021 MB / 1.023 GB, free: 12.25 MB / 0.7794 GB Notification: Performance of FrontEnd - DAE generated: time 3.607e-06/0.6385, allocations: 4 kB / 1.023 GB, free: 12.25 MB / 0.7794 GB Notification: Performance of FrontEnd: time 1.052e-06/0.6385, allocations: 4 kB / 1.023 GB, free: 12.25 MB / 0.7794 GB Notification: Performance of Transformations before backend: time 1.086e-05/0.6385, allocations: 0 / 1.023 GB, free: 12.25 MB / 0.7794 GB Notification: Model statistics after passing the front-end and creating the data structures used by the back-end: * Number of equations: 27 * Number of variables: 27 Notification: Performance of Generate backend data structure: time 0.001304/0.6398, allocations: 0.884 MB / 1.024 GB, free: 11.31 MB / 0.7794 GB Notification: Performance of prepare preOptimizeDAE: time 3.671e-05/0.6399, allocations: 12.03 kB / 1.024 GB, free: 11.3 MB / 0.7794 GB Notification: Performance of preOpt introduceOutputAliases (simulation): time 5.278e-05/0.6399, allocations: 46.73 kB / 1.024 GB, free: 11.24 MB / 0.7794 GB Notification: Performance of preOpt normalInlineFunction (simulation): time 0.0001811/0.6401, allocations: 48.47 kB / 1.024 GB, free: 11.2 MB / 0.7794 GB Notification: Performance of preOpt evaluateParameters (simulation): time 0.0008088/0.6409, allocations: 0.5487 MB / 1.025 GB, free: 10.61 MB / 0.7794 GB Notification: Performance of preOpt simplifyIfEquations (simulation): time 3.294e-05/0.641, allocations: 24.61 kB / 1.025 GB, free: 10.58 MB / 0.7794 GB Notification: Performance of preOpt expandDerOperator (simulation): time 0.0001075/0.6411, allocations: 36.38 kB / 1.025 GB, free: 10.55 MB / 0.7794 GB Notification: Performance of preOpt clockPartitioning (simulation): time 0.0004781/0.6416, allocations: 304.4 kB / 1.025 GB, free: 10.24 MB / 0.7794 GB Notification: Performance of preOpt findStateOrder (simulation): time 1.422e-05/0.6416, allocations: 7.875 kB / 1.025 GB, free: 10.23 MB / 0.7794 GB Notification: Performance of preOpt replaceEdgeChange (simulation): time 2.729e-05/0.6416, allocations: 11.98 kB / 1.025 GB, free: 10.22 MB / 0.7794 GB Notification: Performance of preOpt inlineArrayEqn (simulation): time 8.987e-06/0.6416, allocations: 4 kB / 1.025 GB, free: 10.21 MB / 0.7794 GB Notification: Performance of preOpt removeEqualRHS (simulation): time 0.0003202/0.6419, allocations: 219.8 kB / 1.026 GB, free: 10 MB / 0.7794 GB Notification: Performance of preOpt removeSimpleEquations (simulation): time 0.001845/0.6438, allocations: 1.191 MB / 1.027 GB, free: 8.75 MB / 0.7794 GB Notification: Performance of preOpt comSubExp (simulation): time 0.0005624/0.6444, allocations: 467.7 kB / 1.027 GB, free: 8.266 MB / 0.7794 GB Notification: Performance of preOpt resolveLoops (simulation): time 0.0002134/0.6446, allocations: 182.6 kB / 1.027 GB, free: 8.078 MB / 0.7794 GB Notification: Performance of preOpt evalFunc (simulation): time 1.125e-05/0.6446, allocations: 0 / 1.027 GB, free: 8.078 MB / 0.7794 GB Notification: Performance of preOpt encapsulateWhenConditions (simulation): time 0.0003912/0.645, allocations: 334.6 kB / 1.028 GB, free: 7.734 MB / 0.7794 GB Notification: Performance of pre-optimization done (n=24): time 1.493e-06/0.645, allocations: 0 / 1.028 GB, free: 7.734 MB / 0.7794 GB Notification: Performance of matching and sorting (n=24): time 0.0009165/0.646, allocations: 0.6334 MB / 1.028 GB, free: 7.094 MB / 0.7794 GB Notification: Performance of inlineWhenForInitialization (initialization): time 6.811e-05/0.646, allocations: 114.8 kB / 1.028 GB, free: 6.957 MB / 0.7794 GB Notification: Performance of selectInitializationVariablesDAE (initialization): time 0.0005976/0.6466, allocations: 0.5955 MB / 1.029 GB, free: 6.359 MB / 0.7794 GB Notification: Performance of collectPreVariables (initialization): time 7.566e-05/0.6467, allocations: 45.69 kB / 1.029 GB, free: 6.309 MB / 0.7794 GB Notification: Performance of collectInitialEqns (initialization): time 0.0002047/0.6469, allocations: 218.5 kB / 1.029 GB, free: 6.09 MB / 0.7794 GB Notification: Performance of collectInitialBindings (initialization): time 4.728e-05/0.647, allocations: 51.44 kB / 1.029 GB, free: 6.039 MB / 0.7794 GB Notification: Performance of simplifyInitialFunctions (initialization): time 0.0002208/0.6472, allocations: 181.5 kB / 1.029 GB, free: 5.855 MB / 0.7794 GB Notification: Performance of setup shared object (initialization): time 0.0001199/0.6473, allocations: 358.8 kB / 1.03 GB, free: 5.496 MB / 0.7794 GB Notification: Performance of preBalanceInitialSystem (initialization): time 0.00016/0.6475, allocations: 127.9 kB / 1.03 GB, free: 5.371 MB / 0.7794 GB Notification: Performance of partitionIndependentBlocks (initialization): time 0.0007183/0.6482, allocations: 0.7265 MB / 1.031 GB, free: 4.473 MB / 0.7794 GB Notification: Performance of analyzeInitialSystem (initialization): time 0.0003062/0.6485, allocations: 296.6 kB / 1.031 GB, free: 4.137 MB / 0.7794 GB Notification: Performance of solveInitialSystemEqSystem (initialization): time 2.545e-06/0.6486, allocations: 0 / 1.031 GB, free: 4.137 MB / 0.7794 GB Notification: Performance of matching and sorting (n=36) (initialization): time 0.0005797/0.6491, allocations: 421.2 kB / 1.031 GB, free: 3.719 MB / 0.7794 GB Notification: Performance of prepare postOptimizeDAE: time 1.534e-05/0.6492, allocations: 8.031 kB / 1.031 GB, free: 3.711 MB / 0.7794 GB Notification: Performance of postOpt simplifyComplexFunction (initialization): time 7.484e-06/0.6492, allocations: 7.938 kB / 1.031 GB, free: 3.703 MB / 0.7794 GB Notification: Performance of postOpt tearingSystem (initialization): time 1.752e-05/0.6492, allocations: 8 kB / 1.031 GB, free: 3.695 MB / 0.7794 GB Notification: Performance of postOpt solveSimpleEquations (initialization): time 0.0001374/0.6493, allocations: 27.92 kB / 1.031 GB, free: 3.668 MB / 0.7794 GB Notification: Performance of postOpt calculateStrongComponentJacobians (initialization): time 1.296e-05/0.6494, allocations: 12.75 kB / 1.031 GB, free: 3.656 MB / 0.7794 GB Notification: Performance of postOpt simplifyAllExpressions (initialization): time 0.001218/0.6506, allocations: 135.3 kB / 1.031 GB, free: 3.523 MB / 0.7794 GB Notification: Performance of postOpt collapseArrayExpressions (initialization): time 2.113e-05/0.6506, allocations: 12 kB / 1.032 GB, free: 3.512 MB / 0.7794 GB Notification: Model statistics after passing the back-end for initialization: * Number of independent subsystems: 15 * Number of states: 0 () * Number of discrete variables: 33 ($whenCondition9,$whenCondition8,$whenCondition7,$whenCondition6,booTimTab.intTimTab.idx,$PRE.booTimTab.intTimTab.idx,booTimTab.intTimTab.y[2],$PRE.booTimTab.intTimTab.y[2],booTimTab.intTimTab.y[1],$PRE.booTimTab.intTimTab.y[1],booTimTab.y[2],booTimTab.y[1],$whenCondition5,booTimTabOneRow.intTimTab.idx,$PRE.booTimTabOneRow.intTimTab.idx,booTimTabOneRow.intTimTab.y[2],$PRE.booTimTabOneRow.intTimTab.y[2],booTimTabOneRow.intTimTab.y[1],$PRE.booTimTabOneRow.intTimTab.y[1],booTimTabOneRow.y[2],booTimTabOneRow.y[1],$whenCondition4,$whenCondition3,$whenCondition2,$whenCondition1,booTimTabTwi.intTimTab.idx,$PRE.booTimTabTwi.intTimTab.idx,booTimTabTwi.intTimTab.y[2],$PRE.booTimTabTwi.intTimTab.y[2],booTimTabTwi.intTimTab.y[1],$PRE.booTimTabTwi.intTimTab.y[1],booTimTabTwi.y[2],booTimTabTwi.y[1]) * Number of discrete states: 0 () * Number of clocked states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for initialization (36): * Single equations (assignments): 36 * 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.0002487/0.6509, allocations: 257.7 kB / 1.032 GB, free: 3.254 MB / 0.7794 GB Notification: Performance of postOpt lateInlineFunction (simulation): time 6.127e-05/0.6509, allocations: 47.42 kB / 1.032 GB, free: 3.207 MB / 0.7794 GB Notification: Performance of postOpt wrapFunctionCalls (simulation): time 7.576e-05/0.651, allocations: 51.31 kB / 1.032 GB, free: 3.156 MB / 0.7794 GB Notification: Performance of postOpt inlineArrayEqn (simulation): time 4.609e-06/0.651, allocations: 4 kB / 1.032 GB, free: 3.152 MB / 0.7794 GB Notification: Performance of postOpt constantLinearSystem (simulation): time 5.36e-06/0.651, allocations: 4 kB / 1.032 GB, free: 3.148 MB / 0.7794 GB Notification: Performance of postOpt simplifysemiLinear (simulation): time 4.208e-06/0.651, allocations: 0 / 1.032 GB, free: 3.148 MB / 0.7794 GB Notification: Performance of postOpt removeSimpleEquations (simulation): time 0.0003367/0.6514, allocations: 413.2 kB / 1.032 GB, free: 2.695 MB / 0.7794 GB Notification: Performance of postOpt simplifyComplexFunction (simulation): time 2.064e-06/0.6514, allocations: 0 / 1.032 GB, free: 2.695 MB / 0.7794 GB Notification: Performance of postOpt solveSimpleEquations (simulation): time 1.923e-05/0.6514, allocations: 7.938 kB / 1.032 GB, free: 2.688 MB / 0.7794 GB Notification: Performance of postOpt tearingSystem (simulation): time 2.004e-06/0.6514, allocations: 3.938 kB / 1.032 GB, free: 2.684 MB / 0.7794 GB Notification: Performance of postOpt inputDerivativesUsed (simulation): time 2.156e-05/0.6515, allocations: 15.92 kB / 1.032 GB, free: 2.668 MB / 0.7794 GB Notification: Performance of postOpt calculateStrongComponentJacobians (simulation): time 3.787e-06/0.6515, allocations: 4.25 kB / 1.032 GB, free: 2.664 MB / 0.7794 GB Notification: Performance of postOpt calculateStateSetsJacobians (simulation): time 2.254e-06/0.6515, allocations: 4 kB / 1.032 GB, free: 2.66 MB / 0.7794 GB Notification: Performance of postOpt symbolicJacobian (simulation): time 0.0005935/0.6521, allocations: 0.5108 MB / 1.033 GB, free: 2.125 MB / 0.7794 GB Notification: Performance of postOpt removeConstants (simulation): time 8.871e-05/0.6522, allocations: 128.6 kB / 1.033 GB, free: 1.98 MB / 0.7794 GB Notification: Performance of postOpt simplifyTimeIndepFuncCalls (simulation): time 4.637e-05/0.6522, allocations: 7.938 kB / 1.033 GB, free: 1.973 MB / 0.7794 GB Notification: Performance of postOpt simplifyAllExpressions (simulation): time 0.0001618/0.6524, allocations: 23.97 kB / 1.033 GB, free: 1.949 MB / 0.7794 GB Notification: Performance of postOpt findZeroCrossings (simulation): time 6.918e-05/0.6525, allocations: 23.97 kB / 1.033 GB, free: 1.926 MB / 0.7794 GB Notification: Performance of postOpt collapseArrayExpressions (simulation): time 3.04e-05/0.6525, allocations: 16 kB / 1.033 GB, free: 1.91 MB / 0.7794 GB Notification: Performance of sorting global known variables: time 0.0004226/0.6529, allocations: 435.1 kB / 1.033 GB, free: 1.488 MB / 0.7794 GB Notification: Performance of sort global known variables: time 1.4e-07/0.6529, allocations: 0 / 1.033 GB, free: 1.488 MB / 0.7794 GB Notification: Performance of remove unused functions: time 0.0004103/0.6533, allocations: 111.9 kB / 1.033 GB, free: 1.379 MB / 0.7794 GB Notification: Model statistics after passing the back-end for simulation: * Number of independent subsystems: 3 * Number of states: 0 () * Number of discrete variables: 24 ($whenCondition9,$whenCondition8,$whenCondition7,$whenCondition6,booTimTab.y[1],booTimTab.y[2],booTimTab.intTimTab.y[1],booTimTab.intTimTab.y[2],booTimTab.intTimTab.idx,$whenCondition5,booTimTabOneRow.y[1],booTimTabOneRow.y[2],booTimTabOneRow.intTimTab.y[1],booTimTabOneRow.intTimTab.y[2],booTimTabOneRow.intTimTab.idx,$whenCondition4,$whenCondition3,$whenCondition2,$whenCondition1,booTimTabTwi.y[1],booTimTabTwi.y[2],booTimTabTwi.intTimTab.y[1],booTimTabTwi.intTimTab.y[2],booTimTabTwi.intTimTab.idx) * Number of discrete states: 0 () * Number of clocked states: 0 () * Top-level inputs: 0 Notification: Strong component statistics for simulation (24): * Single equations (assignments): 15 * Array equations: 0 * Algorithm blocks: 0 * Record equations: 0 * When equations: 9 * 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.0009437/0.6543, allocations: 1.11 MB / 1.035 GB, free: 240 kB / 0.7794 GB Notification: Performance of simCode: created initialization part: time 0.0005596/0.6549, allocations: 371.4 kB / 1.035 GB, free: 15.87 MB / 0.795 GB Notification: Performance of simCode: created event and clocks part: time 2.034e-06/0.6549, allocations: 0 / 1.035 GB, free: 15.87 MB / 0.795 GB Notification: Performance of simCode: created simulation system equations: time 0.000224/0.6551, allocations: 187.8 kB / 1.035 GB, free: 15.69 MB / 0.795 GB Notification: Performance of simCode: created of all other equations (e.g. parameter, nominal, assert, etc): time 0.0002823/0.6554, allocations: 42.64 kB / 1.035 GB, free: 15.65 MB / 0.795 GB Notification: Performance of simCode: created linear, non-linear and system jacobian parts: time 0.004689/0.6601, allocations: 4.444 MB / 1.039 GB, free: 11.02 MB / 0.795 GB Notification: Performance of simCode: some other stuff during SimCode phase: time 0.000368/0.6605, allocations: 0.8316 MB / 1.04 GB, free: 10.16 MB / 0.795 GB Notification: Performance of simCode: alias equations: time 0.0002139/0.6607, allocations: 98.91 kB / 1.04 GB, free: 10.06 MB / 0.795 GB Notification: Performance of simCode: all other stuff during SimCode phase: time 0.0001689/0.6609, allocations: 127.4 kB / 1.041 GB, free: 9.938 MB / 0.795 GB Notification: Performance of SimCode: time 2.61e-07/0.6609, allocations: 0 / 1.041 GB, free: 9.938 MB / 0.795 GB Notification: Performance of buildModelFMU: Generate the FMI files: time 0.0309/0.6918, allocations: 11.5 MB / 1.052 GB, free: 14.71 MB / 0.8106 GB Notification: Performance of buildModelFMU: Generate platform static: time 7.251/7.942, allocations: 17.09 kB / 1.052 GB, free: 14.71 MB / 0.8106 GB (rm -f Buildings_10_Buildings.Controls.OBC.CDL.Logical.Sources.Validation.TimeTableNegativeStartTime.pipe ; mkfifo Buildings_10_Buildings.Controls.OBC.CDL.Logical.Sources.Validation.TimeTableNegativeStartTime.pipe ; head -c 1048576 < Buildings_10_Buildings.Controls.OBC.CDL.Logical.Sources.Validation.TimeTableNegativeStartTime.pipe >> ../files/Buildings_10_Buildings.Controls.OBC.CDL.Logical.Sources.Validation.TimeTableNegativeStartTime.sim & python3 -m fmpy simulate --output-file Buildings_10_Buildings.Controls.OBC.CDL.Logical.Sources.Validation.TimeTableNegativeStartTime_res.csv --start-time -5 --stop-time 10 --timeout 50 --relative-tolerance 1e-06 --interface-type ModelExchange --solver CVode --output-interval 0.006 Buildings_10_Buildings_Controls_OBC_CDL_Logical_Sources_Validation_TimeTableNegativeStartTime.fmu > Buildings_10_Buildings.Controls.OBC.CDL.Logical.Sources.Validation.TimeTableNegativeStartTime.pipe 2>&1) diffSimulationResults("Buildings_10_Buildings.Controls.OBC.CDL.Logical.Sources.Validation.TimeTableNegativeStartTime_res.csv","/mnt/ReferenceFiles/Buildings/csv/maint_10.0.x/Buildings_Controls_OBC_CDL_Logical_Sources_Validation_TimeTableNegativeStartTime.csv","/var/lib/jenkins1/ws/OpenModelicaLibraryTestingWork/OpenModelicaLibraryTesting/files/Buildings_10_Buildings.Controls.OBC.CDL.Logical.Sources.Validation.TimeTableNegativeStartTime.diff",relTol=0.003,relTolDiffMinMax=0.003,rangeDelta=0.001) Reference file matches