Upgrade to Pro — share decks privately, control downloads, hide ads and more …

決定木のpredict_proba()の話

Aipa
January 19, 2019

 決定木のpredict_proba()の話

決定木のpredict_proba()の話

Aipa

January 19, 2019
Tweet

More Decks by Aipa

Other Decks in Technology

Transcript

  1. ᶉ෼ׂ৚݅ͷળ͠ѱ͠Λ ൑அ͢ΔͨΊʹɺ ෼ׂલޙͷෆ७౓ͷมԽΛ ٻΊ·͢ ͭ·Βͳ͍ or ϫχ͸13 => 0.497 ෼ׂ͞Εׂͨ߹

    => 13/18 => 0.72 αϝ͸5 => 0.48 ෼ׂ͞Εׂͨ߹ => 5/18 => 0.27 ܾఆ໦ͷॲཧϑϩʔ
  2. ᶉ෼ׂ৚݅ͷળ͠ѱ͠Λ ൑அ͢ΔͨΊʹɺ ෼ׂલޙͷෆ७౓ͷมԽΛ ٻΊ·͢ ͭ·Βͳ͍ or ෼ׂલͷgini܎਺ - ((ϫχ෼ׂޙͷgini܎਺ *

    ϫχ෼ׂ͞Εׂͨ߹) + (αϝ෼ׂޙͷgini܎਺ * αϝ෼ׂ͞Εׂͨ߹)) => 0.5 - ((0.497 * 0.72) + (0.48 * 0.27)) => 0.00769 ܾఆ໦ͷॲཧϑϩʔ
  3. ᶊධՁޙͷ஋(੺จࣈ)Λอ͓࣋ͯ͘͠ => ᶆʙᶉΛ܁Γฦ͠ൺֱͯ͠ Ұ൪େ͖͍஋Λ => ෼ׂʹϕετͳಛ௃ྔ͕ܾ·Δ ͭ·Βͳ͍ or ෼ׂલͷgini܎਺ -

    ((ϫχ෼ׂޙͷgini܎਺ * ϫχ෼ׂ͞Εׂͨ߹) + (αϝ෼ׂޙͷgini܎਺ * αϝ෼ׂ͞Εׂͨ߹)) => 0.5 - ((0.497 * 0.72) + (0.48 * 0.27)) => 0.00769 ܾఆ໦ͷॲཧϑϩʔ
  4. QSFEJDU@QSPCBͷ࣮૷ ϫχ͸ ͭ·Βͳ͍ 7 ͓΋͠Ζ͍ 6 αϝ͸ ͭ·Βͳ͍ 2 ͓΋͠Ζ͍

    3 ιʔεΛಡΜͰΈΔͱ ܇࿅࣌ʹ෼ྨ͞Ε͍ͯΔ
 σʔλ਺Λ࢖ͬͯࢉग़ͯ͠
 ͍Δ͜ͱ͕Θ͔ͬͨ
  5. QSFEJDU@QSPCBͷ࣮૷ ϫχ͸ ͭ·Βͳ͍ 7 ͓΋͠Ζ͍ 6 ᶅ෼ྨ͞ΕͨNodeʹ͋Δ ܇࿅࣌ͷ෼ྨσʔλ਺Λ࢖ͬͯ ֬཰ΛٻΊΔ ςετσʔλ

    -> [[ͭ·Βͳ͍,͓΋͠Ζ͍]] -> [[7, 6]] σʔλຖʹ߹ܭ͢Δ [[7 ,6]].sum(axis=1) -> [13] ׂΔ [[7, 6]] / [13] -> [[0.538, 0.461]]