ELU

1 개요

이미지 채널 값의 ELU(Exponential Linear Unit) 함숫값 또는 미분값을 반환하는 알고리즘입니다.

ELU
Graph
Fig. Plot of ELU function.

2 알고리즘 상세 설명

Forward 모드

Source 이미지 픽셀 각 채널 값의 ELU 함숫값을 계산하여 출력합니다.
아래의 Figure 는 [-1, 1] 범위의 float 이미지에 α=1.0\alpha = 1.0 를 적용한 예시를 보여줍니다.

Source Image Destination Image
Source Image Destination Image
Fig. Source and destination images. (forward mode)

yn=ELUα(xn)y_{n} = \text{ELU}_{\alpha}(x_{n})

ELUα(x)={xx>0α(ex1)otherwise\text{ELU}_{\alpha}(x) = \begin{cases} x & x>0 \\ \alpha (e^{x}-1) & \text{otherwise} \end{cases}

Backward 모드

Source 이미지 픽셀 각 채널 값의 ELU 미분값을 계산하여 출력합니다.
아래의 Figure 는 [-1, 1] 범위의 float 이미지에 α=1.0\alpha = 1.0 를 적용한 예시를 보여줍니다.

Source Image Destination Image
Source Image Destination Image
Fig. Source and destination images. (backward mode)

yn=ELUα(xn)y_{n} = \textnormal{ELU}'_{\alpha}(x_{n})

ELUα(x)={1x>0αexotherwise\text{ELU}'_{\alpha}(x) = \begin{cases} 1 & x>0 \\ \alpha e^{x} & \text{otherwise} \end{cases}

3 파라미터 설정 및 사용 방법

Operation Mode 설정

Alpha 설정

4 예제 코드

COperationELU elu;

CFLImage fliSourceImage;
CFLImage fliDestinationImage;

elu.SetSourceImage(fliSourceImage);
elu.SetDestinationImage(fliDestinationImage);
elu.SetOperationMode(COperationELU::EOperationMode_Forward);
elu.SetAlpha(0.2);

elu.Execute();
COperationELU elu = new COperationELU();

CFLImage fliSourceImage = new CFLImage();
CFLImage fliDestinationImage = new CFLImage();

elu.SetSourceImage(ref fliSourceImage);
elu.SetDestinationImage(ref fliDestinationImage);
elu.SetOperationMode(COperationELU.EOperationMode.Forward);
elu.SetAlpha(0.2);

elu.Execute();

5 기타 사항

Supported Feature

Supported Format

Overflow Method

Overflow 가 발생하는 경우 Clamping 처리 됩니다.

6 관련 알고리즘

ReLU PReLU Softplus Sigmoid Swish Mish Soft Shrinkage Hard Shrinkage