Skip to Content
밑바닥부터 시작하는 딥러닝
book

밑바닥부터 시작하는 딥러닝

by 사이토 고키, 개앞맵시(이복연)
January 2017
Beginner to intermediate
312 pages
7h 3m
Korean
Hanbit Media, Inc.
Content preview from 밑바닥부터 시작하는 딥러닝
165
5
장
-
오차역전파법
5.5
활성화 함수 계층 구현하기
드디어 계산 그래프를 신경망에 적용할 때가 왔습니다. 여기에서는 신경망을 구성하는 층(계
층) 각각을 클래스 하나로 구현합니다. 우선은 활성화 함수인
ReLU
와
Sigmoid
계층을 구현
하겠습니다.
5.5.1
ReLU
계층
활성화 함수로 사용되는
ReLU
는 다음 식으로 나타납니다.
y
xx
x
()
()
0
00
2
#
=
)
[식 5.7 ]
[식
5
.
7
]에서
x
에 대한
y
의 미분은 [식
5
.
8
]처럼 구합니다.
x
y
x
x
1( )
()
0
00
2
2
2
#
=
)
[식 5.8 ]
[식
5
.
8
]에서와 같이 순전파 때의 입력인
x
가
0
보다 크면 역전파는 상류의 값을 그대로 하류로
흘립니다. 반면, 순전파 때
x
가
0
이하면 역전파 때는 하류로 신호를 보내지 않습니다(
0
을 보
냅니다 ). 계산 그래프로는 [그림
5
-
18
]처럼 그릴 수 있습니다.
그림
5-18
ReLU
계층의 계산 그래프
x
>
0
x
≤
0
이제 이
ReLU
계층을 구현해볼까요? 신경망 계층의
forward
( )와
backward
( ) 함수는 넘파
이 배열을 인수로 받는다고 가정합니다.
ReLU
계층을 구현한 코드는
common
/
layers
.
py
에
있습니다.
166
밑바닥부터 시작하는 딥러닝
class Relu
:
def
__
init
__(
self
):
self
.
mask
=
None ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.

Read now

Unlock full access

More than 5,000 organizations count on O’Reilly

AirBnbBlueOriginElectronic ArtsHomeDepotNasdaqRakutenTata Consultancy Services

QuotationMarkO’Reilly covers everything we've got, with content to help us build a world-class technology community, upgrade the capabilities and competencies of our teams, and improve overall team performance as well as their engagement.
Julian F.
Head of Cybersecurity
QuotationMarkI wanted to learn C and C++, but it didn't click for me until I picked up an O'Reilly book. When I went on the O’Reilly platform, I was astonished to find all the books there, plus live events and sandboxes so you could play around with the technology.
Addison B.
Field Engineer
QuotationMarkI’ve been on the O’Reilly platform for more than eight years. I use a couple of learning platforms, but I'm on O'Reilly more than anybody else. When you're there, you start learning. I'm never disappointed.
Amir M.
Data Platform Tech Lead
QuotationMarkI'm always learning. So when I got on to O'Reilly, I was like a kid in a candy store. There are playlists. There are answers. There's on-demand training. It's worth its weight in gold, in terms of what it allows me to do.
Mark W.
Embedded Software Engineer

You might also like

밑바닥부터 시작하는 비트코인

밑바닥부터 시작하는 비트코인

류정필, 송재준
엑셀이 편해지는 파이썬

엑셀이 편해지는 파이썬

펠릭스 춤슈타인

Publisher Resources

ISBN: 9788968484636