1/**
2 * Copyright (c) Glow Contributors. See CONTRIBUTORS file.
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16#ifdef GLOW_WITH_CPU
17
18#include "glow/Graph/VerifierHelper.h"
19
20bool CPUMaxSplatNode::verify() const {
21 return checkSameType(getInput(), getResult(), this);
22}
23
24bool CPUConvDKKC8Node::verify() const {
25 ShapeNHWC idim(getInput().getType()->dims());
26 ShapeNHWC odim(getResult().getType()->dims());
27 auto outSz = calculateConvPoolOutputDims(idim.h, idim.w, getKernels(),
28 getStrides(), getPads());
29 ShapeNHWC exp(idim.n, outSz.first, outSz.second, getBias().dims()[0]);
30 return expectCompareTrue("Invalid output dimensions", exp, odim, this);
31}
32
33#endif // GLOW_WITH_CPU
34