From 6605927b64175661bd1a341d3cb594342c8d3757 Mon Sep 17 00:00:00 2001 From: Olivier BICHLER <olivier.bichler@cea.fr> Date: Tue, 16 Apr 2024 12:08:57 +0200 Subject: [PATCH] Reverted erroneous change: please read the comment and CuDNN doc! --- src/operator/ConvImpl.cpp | 17 +++++------------ 1 file changed, 5 insertions(+), 12 deletions(-) diff --git a/src/operator/ConvImpl.cpp b/src/operator/ConvImpl.cpp index 096ee94..c0c32d3 100644 --- a/src/operator/ConvImpl.cpp +++ b/src/operator/ConvImpl.cpp @@ -102,18 +102,11 @@ void Aidge::ConvImpl_cuda<DIM>::forward() { // Do the actual forward computation // Template is only for scaling parameters, which are always in float // excepted when the convolution is performed in double precision. - switch(op.getOutput(0)->dataType()) { - case DataType::Float64: - forward_<double>(input0, input1, input2); - break; - case DataType::Float32: - forward_<float>(input0, input1, input2); - break; - case DataType::Float16: - forward_<half>(input0, input1, input2); - break; - default: - AIDGE_THROW_OR_ABORT(std::runtime_error, "Data type is not supported by Backend Cuda"); + if (op.getOutput(0)->dataType() == DataType::Float64) { + forward_<double>(input0, input1, input2); + } + else { + forward_<float>(input0, input1, input2); } } -- GitLab