1 // Copyright (c) 2016 Intel Corporation
3 // Licensed under the Apache License, Version 2.0 (the "License");
4 // you may not use this file except in compliance with the License.
5 // You may obtain a copy of the License at
7 // http://www.apache.org/licenses/LICENSE-2.0
9 // Unless required by applicable law or agreed to in writing, software
10 // distributed under the License is distributed on an "AS IS" BASIS,
11 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 // See the License for the specific language governing permissions and
13 // limitations under the License.
18 #include "activation_kernel_base.h"
22 // 1. choose a tutorial mode
23 // 2. modify activation_tutorial.cl as well
25 #define ADVANCED_TUTORIAL // simple runnable example with explanations
27 namespace kernel_selector {
29 class ActivationKernel_Tutorial : public ActivationKernelBase {
31 using Parent = ActivationKernelBase;
32 ActivationKernel_Tutorial() : Parent("activation_tutorial") {}
33 virtual ~ActivationKernel_Tutorial() {}
35 KernelsData GetKernelsData(const Params& params, const optional_params& options) const override;
36 ParamsKey GetSupportedKey() const override;
39 #ifdef ADVANCED_TUTORIAL
40 DispatchData SetDefault(const activation_params& arg) const override;
41 bool Validate(const Params& p, const optional_params& o) const override;
42 JitConstants GetJitConstants(const activation_params& params, DispatchData) const override;
45 } // namespace kernel_selector