Skip to Content
파이토치로 배우는 LLM & AI
book

파이토치로 배우는 LLM & AI

by 로런스 모로니, 박해선
March 2026
Intermediate
504 pages
11h 26m
Korean
Hanbit Media, Inc.
Content preview from 파이토치로 배우는 LLM & AI
115
3
장
고급 컴퓨터 비전: 이미지에서 특징 감지하기
3.8
다중 분류
지금까지 본 모든 예제는 두 옵션 중 하나를 선택하는
이진 분류
binary
classification
모델을 만들었습
니다. 다중 분류
multiclass
classification
모델도 거의 비슷하지만 몇 가지 차이점이 있습니다. 출력 층
에 시그모이드 활성화 함수를 사용하는 하나의 뉴런을 사용하는 것이 아니라, 분류하려는 클
래스 개수에 해당하는
n
개의 뉴런을 사용합니다. 또한 여러 개의 클래스에 적합한 손실 함수로
바꾸어야 합니다.
파이토치의
nn
.
CrossEntropyLoss
손실 함수는 여러 개의 클래스를 다룰 수 있습니다. 따라
서 이 장에서 만든 ‘강아지-고양이’와 ‘말-사람’ 전이 학습 분류기는 수정 없이 이 손실 함수를
사용할 수 있습니다. 하지만 단일 뉴런으로 만든 ‘말-사람’ 분류기는 두 개 이상의 클래스에 대
한 확률을 출력하지 않으므로 이 함수를 사용할 수 없습니다. 이 점을 항상 주의해야 하며 분류
모델을 만들 때 발생하는 흔한 버그 중 하나입니다.
이진 분류 다음으로 가위, 바위, 보 게임을 다루어 보죠. 손 모양을 인식하는 모델을 훈련하려면
세 가지 종류의 이미지를 다루어야 합니다. 다행히 이를 위해 간단한 데이터셋(
https
://
bit
.
ly
/
4aAeFv7 ...
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

AI 에이전트 엔지니어링

AI 에이전트 엔지니어링

마이클 알바다
핸즈온 LLM

핸즈온 LLM

제이 알아마르, 마르턴 흐루턴도르스트
만들면서 배우는 생성 AI

만들면서 배우는 생성 AI

데이비드 포스터

Publisher Resources

ISBN: 9791175790223