Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Python ではじめる辞書学習 #1
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
Hacarus Inc.
February 16, 2018
Technology
0
670
Python ではじめる辞書学習 #1
Presentation slides at Hannnari Python #3
https://hannari-python.connpass.com/event/77366/
Hacarus Inc.
February 16, 2018
Tweet
Share
More Decks by Hacarus Inc.
See All by Hacarus Inc.
GitLab CI/CD で C#/WPFアプリケーションのテストとインストーラーのビルド・デプロイを自動化する
hacarus
0
1.3k
QA4AIに則ったMLOpsツールの活用
hacarus
0
710
0から協働ロボット外観検査システムを3ヵ月で具現化した軌跡
hacarus
0
260
ワンちゃんの健康を願う皆様に送る 犬心電図AI解析プロダクト紹介_AWS DevDay2022
hacarus
0
200
犬の心電AI解析プロダクト開発奮闘記 _クラウドからハード開発までてんこ盛り
hacarus
0
1.8k
ExplainableAIの概要とAmazon SageMaker Clarifyでの実装例
hacarus
0
1.1k
AWS Step Functions を用いた非同期学習処理の例
hacarus
0
1.4k
Dashでmyダッシュボードを作ろう ーpytrendsで見るコロナの感染拡大時期ー
hacarus
0
1.5k
Interpretable Machine Learning: モデル非依存な解釈手法の紹介
hacarus
0
1.1k
Other Decks in Technology
See All in Technology
20260204_Midosuji_Tech
takuyay0ne
1
160
Introduction to Sansan, inc / Sansan Global Development Center, Inc.
sansan33
PRO
0
3k
レガシー共有バッチ基盤への挑戦 - SREドリブンなリアーキテクチャリングの取り組み
tatsukoni
0
220
OWASP Top 10:2025 リリースと 少しの日本語化にまつわる裏話
okdt
PRO
3
820
FinTech SREのAWSサービス活用/Leveraging AWS Services in FinTech SRE
maaaato
0
130
usermode linux without MMU - fosdem2026 kernel devroom
thehajime
0
240
Tebiki Engineering Team Deck
tebiki
0
24k
コスト削減から「セキュリティと利便性」を担うプラットフォームへ
sansantech
PRO
3
1.5k
こんなところでも(地味に)活躍するImage Modeさんを知ってるかい?- Image Mode for OpenShift -
tsukaman
0
160
Context Engineeringの取り組み
nutslove
0
360
Introduction to Bill One Development Engineer
sansan33
PRO
0
360
SREチームをどう作り、どう育てるか ― Findy横断SREのマネジメント
rvirus0817
0
310
Featured
See All Featured
Thoughts on Productivity
jonyablonski
74
5k
Speed Design
sergeychernyshev
33
1.5k
Leading Effective Engineering Teams in the AI Era
addyosmani
9
1.6k
Designing for Performance
lara
610
70k
Avoiding the “Bad Training, Faster” Trap in the Age of AI
tmiket
0
77
Building the Perfect Custom Keyboard
takai
2
690
Designing Dashboards & Data Visualisations in Web Apps
destraynor
231
54k
Public Speaking Without Barfing On Your Shoes - THAT 2023
reverentgeek
1
310
ラッコキーワード サービス紹介資料
rakko
1
2.3M
Paper Plane
katiecoart
PRO
0
46k
Practical Orchestrator
shlominoach
191
11k
Templates, Plugins, & Blocks: Oh My! Creating the theme that thinks of everything
marktimemedia
31
2.7k
Transcript
Python ではじめる辞書学習 #1 2018年2月16日 はんなり Python #3 @ウィングス京都
છాوࢤ ͦΊ͔ͩͨ͠ • גࣜձࣾϋΧϧε औక$50 • 1ZUIPOྺ • ؔ+BWBɾ+"846(ɾ%FW-07&ؔ
ք۾
εύʔεϞσϦϯά • σʔλͷεύʔεੑʹணͨ͠ϞσϦϯάख๏ • ೖྗಛྔͷதͷॏཁͳͷ͕Θ͔Δ • গͳ͍ใ͔Βݩͷใͷ෮ݩ͕Ͱ͖Δ
໌ޙ౦ژͰొஃ͠·͢
ຊͷΰʔϧ ߦྻղ XJUIը૾ʹ৮ΕΔ
ߦྻղ • ͋ΔߦྻΛผͷߦྻͷੵͰද͢ ۙࣅ͢Δ ! = #$ ઢܕํఔࣜΛղ͖ͨ͘͢͠Γ σʔλͷ࣍ݩѹॖಛͷநग़ʹΘΕͨΓ
ߦྻղͷ࣮ • /VN1Z • OVNQZMJOBMH ʹ 23ղಛҟղͳͲ • TDJLJUMFBSO •
TLMFBSOEFDPNQPTJUJPO ʹ 1$" *$"ɺ/.'ɺ ࣙॻֶशͳͲ
ը૾ʹద༻ͯ͠ΈΔ • ը૾ΛҰͭͷྻϕΫτϧͱݟཱͯΔ • ෳͷը૾σʔλΛҰͭͷߦྻͱݟཱͯΔ !"" ⋯ !$" ⋮ ⋱
⋮ !"' ⋯ !$' ཁૉ Qͷ Oݸͷը૾αϯϓϧ
σʔληοτ 0MJWFUUJ'BDFTYຕ IUUQTDTOZVFEVdSPXFJTEBUBIUNM
1$" • ࢄΛ࠷େԽ͢ΔํʹओΛநग़ • ֤ओަ • ࣍ݩݮͰ͓ೃછΈ
1$"ͷओ جఈʹݮɺد༩ͷ߹ܭ
1$"Ͱ࠶ߏ
1$" # run PCA from sklearn.decomposition import PCA pca =
PCA(n_components=n_components, svd_solver='randomized’, whiten=True) pca.fit(X_train) # reconstruct original space code = pca.transform(sample.reshape(1, -1)) reconstructed = pca.inverse_transform(code)
1$" • ݩͷσʔληοτ 9ΑΓ͍࣍ݩʹམͱ͢ !" = $%" ݸͷإը૾Λͬ͘͟Γ ύλʔϯʹׂͨ͠Πϝʔδ
*$" • ͷಠཱੑʹண • ࠞ߹৴߸ͷ߹ʹΑ͍ੑೳ
*$" ͷಠཱ
*$"Ͱ࠶ߏ
*$" # run ICA from sklearn.decomposition import FastPCA ica =
FastICA(n_components=n_components, whiten=True) ica.fit(X_train) # reconstruct original space code = ica.transform(sample.reshape(1, -1)) reconstructed = ica.inverse_transform(code)
/.' • ཁૉ͕ඇෛͱ͍͏੍Λିͨ͠ߦྻղ • جఈͷ͠߹ΘͤͰݩͷσʔλΛදݱ • ಛநग़ͱͯ͠ΈΔ͜ͱՄ
/.'ͷಛߦྻ ࣍ݩɺ࠶ߏΤϥʔ ϑϩϏϊεϊϧϜ
/.'Ͱ࠶ߏ
/.' # run NMF from sklearn.decomposition import NMF nmf =
NMF(n_components=n_components) W = nmf.fit_transform(X_train) H = nmf.components_ # reconstruct original image code = nmf.transform(sample.reshape(1, -1)) reconstructed = nmf.inverse_transform(code)
/.' • εύʔεͳղ ਓͷը૾Λ ͷإͷύλʔϯͷ͠߹ΘͤͰදݱ
·ͱΊ • 1$"ɺ*$"ͱ /.'Λෳͷը૾σʔλʹର͠ ࣮ͯࢪ • ࣍ʑճࣙॻֶश • αϯϓϧίʔυ IUUQTHJUJPW"D47
উखʹ ࣍ճ༧ࠂ • 1Z$PO 1)Ϩϙʔτ • དྷि ɺ
ϚχϥͰ։࠵ • ฐࣾϑΟϦϐϯͷΤϯδχΞ͕ొஃ • IUUQTQZDPOQZUIPOQI • ࣍ճΜͳΓ 1ZUIPOʹࢀՃͰ͖Δ ͔