728x90
๋ฐ˜์‘ํ˜•

๋จธ์‹ ๋Ÿฌ๋‹ 5

[๋จธ์‹ ๋Ÿฌ๋‹] Likelihood "์šฐ๋„" ๋ž€?

์šฐ๋ฆฌ๊ฐ€ ๋จธ์‹ ๋Ÿฌ๋‹์„ ๊ณต๋ถ€ํ•˜๋‹ค๋ณด๋ฉด MLE(Maximum LIkelihood Estimation)์„ ๋งŽ์ด ์ ‘ํ•œ๋‹ค. ์—ฌ๊ธฐ์„œ ์˜๋ฏธํ•˜๋Š” Likelihood๊ฐ€ ๋ฌด์—‡์ธ๊ฐ€? ์ตœ๋Œ€์šฐ๋„๋ฒ•(MLE)๋ž€ - ๋ชจ์ˆ˜์ ์ธ ๋ฐ์ดํ„ฐ ๋ฐ€๋„ ์ถ”์ • ๋ฐฉ๋ฒ• - ํŒŒ๋ผ๋ฏธํ„ฐ ๐œƒ = (๐œƒ1,๐œƒ2,..๐œƒn)์œผ๋กœ ๊ตฌ์„ฑ๋œ ์–ด๋–ค ํ™•๋ฅ ๋ฐ€๋„ํ•จ์ˆ˜ P์—์„œ ๊ด€์ธก๋œ ํ‘œ๋ณธ ๋ฐ์ดํ„ฐ ์ง‘ํ•ฉ์„ x = (x1,x2,..,xn)๋ผ ํ•  ๋•Œ, ์ด ํ‘œ๋ณธ๋“ค์—์„œ ํŒŒ๋ผ๋ฏธํ„ฐ ๐œƒ = (๐œƒ1,๐œƒ2,..๐œƒn)์„ ์ถ”์ •ํ•˜๋Š” ๋ฐฉ๋ฒ•์ด๋‹ค. ์ข€ ๋” ์‰ฌ์šด ์ดํ•ด๋ฅผ ์œ„ํ•ด ๊ทธ๋ฆผ๊ณผ ์—์‹œ๋ฅผ ๋ณด๋ฉด์„œ MLE๋ฅผ ๋” ์ž˜ ์ดํ•ดํ•ด๋ณด์ž ์˜ˆ์‹œ ) ์˜ˆ๋ฅผ ๋“ค์–ด ๋‹ค์Œ๊ณผ ๊ฐ™์ด ๋ฐ์ดํ„ฐ๊ฐ€ ์žˆ๋‹ค๊ณ  ํ•˜์ž x = { 1, 4, 5, 6, 9 } ์ด๋•Œ ๋ฐ์ดํ„ฐ x๋Š” ์•„๋ž˜ ๊ทธ๋ฆผ์˜ ์ฃผํ™ฉ์ƒ‰ ๊ณก์„ ๊ณผ ํŒŒ๋ž€์ƒ‰ ๊ณก์„  ์ค‘ ์–ด๋–ค ๊ณก์„ ์œผ๋กœ๋ถ€ํ„ฐ ์ถ”์ถœ๋˜์—ˆ์„ ํ™•๋ฅ ์ด ๋” ๋†’์€๊ฐ€?..

[Machine Learning] ๋จธ์‹ ๋Ÿฌ๋‹, ๋ชจ๋ธ์˜ ํŽธํ–ฅ(bias)๊ณผ ๋ถ„์‚ฐ(variance) : trade-off ๊ด€๊ณ„

๋จธ์‹ ๋Ÿฌ๋‹์—์„œ ํŽธํ–ฅ๊ณผ ๋ถ„์‚ฐ์€ ์–ธ์ œ ์“ฐ์ด๋Š” ์šฉ์–ด์ธ๊ฐ€? Supervised Learning(์ง€๋„ํ•™์Šต)์— ๋Œ€ํ•ด์„œ ๊ฐ„๋‹จํžˆ ์„ค๋ช…ํ•ด๋ณด์ž๋ฉด ์‚ฌ๋žŒ์ด ์ •ํ•ด์ค€ ์ •๋‹ต์ด ์žˆ๊ณ , ์šฐ๋ฆฌ์˜ ๋ชจ๋ธ์€ ๊ทธ ์ •๋‹ต์„ ์ž˜ ๋งž์ถ”๋Š” ๋ฐฉํ–ฅ์œผ๋กœ ํ•™์Šต(training)์„ ํ•œ๋‹ค. ์ด๋•Œ, ํ•™์Šต์„ ํ•˜๋ฉด์„œ ๋ชจ๋ธ์ด ๋‚ด๋†“๋Š” ์˜ˆ์ธก๊ฐ’๋“ค์˜ ๊ฒฝํ–ฅ์„ ํ‘œํ˜„ํ•˜๊ธฐ์œ„ํ•ด ํŽธํ–ฅ๊ณผ ๋ถ„์‚ฐ์ด๋ผ๋Š” ์šฉ์–ด๋ฅผ ์‚ฌ์šฉํ•œ๋‹ค. ์‰ฝ๊ฒŒ ๋งํ•˜์ž๋ฉด, ๋‹ค์Œ๊ณผ ๊ฐ™๋‹ค A. ์˜ˆ์ธก๊ฐ’๊ณผ ์ •๋‹ต ๊ฐ„์˜ ๊ด€๊ณ„๋ฅผ "ํŽธํ–ฅ"์œผ๋กœ ํ‘œํ˜„ (bias : model์˜ output๊ณผ ์‹ค์ œ๊ฐ’ ์‚ฌ์ด์˜ ์ œ๊ณฑ error, ์ •ํ™•๋„์™€ ๋น„์Šทํ•œ ๊ฐœ๋…) B. ์˜ˆ์ธก๊ฐ’๋ผ๋ฆฌ์˜ ๊ด€๊ณ„๋ฅผ "๋ถ„์‚ฐ"์œผ๋กœ ํ‘œํ˜„ (variance : model์ด ๊ฐ๊ธฐ ๋‹ค๋ฅธ train set์— ๋Œ€ํ•˜์—ฌ ์„ฑ๋Šฅ์˜ ๋ณ€ํ™”์ •๋„๊ฐ€ ๊ธ‰ํ•˜๊ฒŒ ๋ณ€ํ•˜๋Š”์ง€, ์•ˆ์ •์ ์œผ๋กœ ๋ณ€ํ•˜๋Š”์ง€๋ฅผ ๋‚˜ํƒ€๋‚ด๋Š” ์ฒ™๋„) [๋”ฅ๋Ÿฌ๋‹] Bia..

Decision Tree ๊ฐ„.๋‹จ.๋ช….๋ฃŒ

Decision tree : ์˜์‚ฌ๊ฒฐ์ •๋‚˜๋ฌด ๋ถ„๋ฅ˜(classification)๊ณผ ํšŒ๊ท€๋ถ„์„(regression)์— ๋ชจ๋‘ ์‚ฌ์šฉ๋  ์ˆ˜ ์žˆ๊ธฐ ๋–„๋ฌธ์— CART(Classification And Regression Tree)๋ผ๊ณ  ๋ถˆ๋ฆผ node tree์˜ node : ์งˆ๋ฌธ/๋‹ต์„ ๋‹ด๊ณ  ์žˆ์Œ root node : ์ตœ์ƒ์œ„ node ์ตœ์ƒ์œ„ node์˜ ์†์„ฑ feature๊ฐ€ ๊ฐ€์žฅ ์ค‘์š”ํ•œ ํŠน์„ฑ leaf node : ๋งˆ์ง€๋ง‰ node (๋ง๋‹จ๋…ธ๋“œ) ๋งŒ์•ฝ tree์˜ ๋ชจ๋“  leaf node๊ฐ€ pure node๊ฐ€ ๋  ๋•Œ๊นŒ์ง€ ์ง„ํ–‰ํ•˜๋ฉด model์˜ ๋ณต์žก๋„๋Š” ๋งค์šฐ ๋†’์•„์ง€๊ณ  overfitting๋จ overfitting ๋ฐฉ์ง€ tree์˜ ์ƒ์„ฑ์„ ์‚ฌ์ „์— ์ค‘์ง€ : pre-prunning (=๊นŠ์ด์˜ ์ตœ๋Œ€๋ฅผ ์„ค์ •, max_depth) ๋ฐ์ดํ„ฐ๊ฐ€ ์ ์€ node ์‚ญ..

Random Forest ๊ฐ„.๋‹จ.๋ช….๋ฃŒ

Ensemble ์•™์ƒ๋ธ” ์—ฌ๋Ÿฌ ๊ฐœ์˜ ๋จธ์‹ ๋Ÿฌ๋‹ model์„ ์—ฐ๊ฒฐํ•˜์—ฌ ๊ฐ•๋ ฅํ•œ model์„ ๋งŒ๋“œ๋Š” ๊ธฐ๋ฒ• classifier/regression์— ์ „๋ถ€ ํšจ๊ณผ์  random forest์™€ gradient boosting์€ ๋‘˜๋‹ค model์„ ๊ตฌ์„ฑํ•˜๋Š” ๊ธฐ๋ณธ ์š”์†Œ๋กœ decision tree๋ฅผ ์‚ฌ์šฉํ•œ๋‹ค random forest ์กฐ๊ธˆ์”ฉ ๋‹ค ๋‹ค๋ฅธ ์—ฌ๋Ÿฌ decision tree์˜ ๋ฌถ์Œ ๋žœ๋ค ํฌ๋ ˆ์ŠคํŠธ์˜ ๋“ฑ์žฅ ๋ฐฐ๊ฒฝ : ๊ฐ๊ฐ์˜ tree๋Š” ๋น„๊ต์  ์˜ˆ์ธก์„ ์ž˜ ํ•  ์ˆ˜ ์žˆ์ง€๋งŒ, ๋ฐ์ดํ„ฐ์˜ ์ผ๋ถ€์— overfittingํ•˜๋Š” ๊ฒฝํ–ฅ์„ ๊ฐ€์ง ๋”ฐ๋ผ์„œ, ์ž˜ ์ž‘๋™ํ•˜์ง€๋งŒ ์„œ๋กœ ๋‹ค๋ฅธ ๋ฐฉํ–ฅ์œผ๋กœ overfitting๋œ tree๋ฅผ ๋งŽ์ด ๋งŒ๋“ค๊ณ  ๊ทธ ๊ฒฐ๊ณผ๋ฅผ ํ‰๊ท ๋‚ด๋ฉด overfitting์„ ์ค„์ผ ์ˆ˜ ์žˆ๋‹ค ์ด๋ ‡๊ฒŒ ํ•˜๋ฉด tree model์˜ ์˜ˆ์ธก ์„ฑ๋Šฅ์€ ์œ ์ง€ํ•˜๋˜ overf..

๋จธ์‹ ๋Ÿฌ๋‹/AI์—์„œ ์‚ฌ์šฉ๋˜๋Š” "Ground Truth" ๋œป

๋จธ์‹ ๋Ÿฌ๋‹์— ๊ด€๋ จํ•œ ๊ธ€์„ ์ฝ๋‹ค๋ณด๋ฉด "ground-truth"๋ผ๋Š” ์šฉ์–ด๋ฅผ ๋งŽ์ด ์ ‘ํ•˜๊ฒŒ ๋œ๋‹ค. "ground-truth"๋Š” ๊ธฐ์ƒํ•™์—์„œ ์œ ๋ž˜ํ•˜์˜€์œผ๋ฉฐ, ์–ด๋Š ํ•œ ์žฅ์†Œ์—์„œ ์ˆ˜์ง‘๋œ ์ •๋ณด๋ฅผ ์˜๋ฏธํ•˜๋Š” ์šฉ์–ด๋กœ ์‚ฌ์šฉ๋˜์—ˆ๋‹ค๊ณ  ํ•œ๋‹ค. ๊ทธ๋ ‡๋‹ค๋ฉด machine learning/AI์˜ ๋ฌธ๋งฅ์—์„œ ์‚ฌ์šฉ๋˜๋Š” "ground-truth"์˜ ๋œป์€ ๋ฌด์—‡์ธ๊ฐ€. What is ground truth? Ground truth isn't true. It's an ideal expected result. It might involve hand-labeling example datapoints to collect desirable answer data for training your system. For example, a set of images mig..

728x90
๋ฐ˜์‘ํ˜•