1 // This file is part of OpenCV project.
2 // It is subject to the license terms in the LICENSE file found in the top-level directory
3 // of this distribution and at http://opencv.org/license.html.
5 #ifndef OPENCV_DNN_SRC_CUDA4DNN_KERNELS_ACTIVATIONS_HPP
6 #define OPENCV_DNN_SRC_CUDA4DNN_KERNELS_ACTIVATIONS_HPP
8 #include "../csl/stream.hpp"
9 #include "../csl/span.hpp"
13 namespace cv { namespace dnn { namespace cuda4dnn { namespace kernels {
16 void abs(const csl::Stream& stream, csl::Span<T> output, csl::View<T> input);
19 void tanh(const csl::Stream& stream, csl::Span<T> output, csl::View<T> input);
22 void sigmoid(const csl::Stream& stream, csl::Span<T> output, csl::View<T> input);
25 void bnll(const csl::Stream& stream, csl::Span<T> output, csl::View<T> input);
28 void elu(const csl::Stream& stream, csl::Span<T> output, csl::View<T> input);
31 void relu(const csl::Stream& stream, csl::Span<T> output, csl::View<T> input, T slope);
34 void clipped_relu(const csl::Stream& stream, csl::Span<T> output, csl::View<T> input, T floor, T ceiling);
37 void axiswise_relu(const csl::Stream& stream, csl::Span<T> output, csl::View<T> input, std::size_t inner_size, csl::View<T> slope);
40 void power(const csl::Stream& stream, csl::Span<T> output, csl::View<T> input, T exp, T scale, T shift);
42 }}}} /* namespace cv::dnn::cuda4dnn::kernels */
44 #endif /* OPENCV_DNN_SRC_CUDA4DNN_KERNELS_ACTIVATIONS_HPP */