Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
Hydraを使った設定ファイル管理とoptunaプラグインでのパラメータ探索
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
Ringa_hyj
December 31, 2024
Technology
250
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Hydraを使った設定ファイル管理とoptunaプラグインでのパラメータ探索
Ringa_hyj
December 31, 2024
More Decks by Ringa_hyj
See All by Ringa_hyj
DVCによるデータバージョン管理
ringa_hyj
0
450
deeplakeによる大規模データのバージョン管理と深層学習フレームワークとの接続
ringa_hyj
0
120
ClearMLで行うAIプロジェクトの管理(レポート,最適化,再現,デプロイ,オーケストレーション)
ringa_hyj
0
290
Catching up with the tidymodels.[Japan.R 2021 LT]
ringa_hyj
3
890
多次元尺度法MDS
ringa_hyj
0
470
因子分析(仮)
ringa_hyj
0
220
階層、非階層クラスタリング
ringa_hyj
0
170
tidymodels紹介「モデリング過程料理で表現できる説」
ringa_hyj
0
700
深層学習をつかった画像スタイル変換の話と今までの歴史
ringa_hyj
0
510
Other Decks in Technology
See All in Technology
Oracle Cloud Infrastructure IaaS 新機能アップデート 2026/6 - 2026/8
oracle4engineer
PRO
0
160
AIエージェントの自己改善をどう設計するか / How to Design Self-Improvement for AI Agents
22mi
3
1.3k
enechainの内製セルフサービスプラットフォーム
hiyosi
0
160
Screen Lens - 今見てる画面を翻訳する
komagata
0
250
あるけみー式LTスライド作成術
alchemy1115
1
180
AI-DLCって実際どう? 〜聞きたいこと全部聞いてみる〜
news_it_enj
0
260
ASTを使って影響範囲を特定する
nealle
0
170
Microsoft 365 Copilot chat -tekoälypalvelun tietosuojaongelmat
hponka
0
730
なぜSRE・セキュリティは評価されないのか?守りの組織を事業成長エンジンに変えた実践
cscengineer
PRO
3
2.5k
Omarchy Quattro の日本語設定周り
simosako
2
150
[2026-09-11]SREは誰のもの?運用エンジニアが始める 「SRE領域への越境」とチームの進化の軌跡 〜Road to NEXT CRE
tosite
0
160
SQL文一行も書けない人事がCortexもろもろを使って人事業務を楽にしてみる
ponponmikankan
1
220
Featured
See All Featured
VelocityConf: Rendering Performance Case Studies
addyosmani
331
25k
Public Speaking Without Barfing On Your Shoes - THAT 2023
reverentgeek
1
560
[RailsConf 2023] Rails as a piece of cake
palkan
59
7k
A Modern Web Designer's Workflow
chriscoyier
699
190k
Templates, Plugins, & Blocks: Oh My! Creating the theme that thinks of everything
marktimemedia
31
2.9k
DBのスキルで生き残る技術 - AI時代におけるテーブル設計の勘所
soudai
PRO
68
57k
So, you think you're a good person
axbom
PRO
2
2.1k
Sam Torres - BigQuery for SEOs
techseoconnect
PRO
0
540
How Software Deployment tools have changed in the past 20 years
geshan
1
34k
Self-Hosted WebAssembly Runtime for Runtime-Neutral Checkpoint/Restore in Edge–Cloud Continuum
chikuwait
0
780
The Curious Case for Waylosing
cassininazir
1
500
Leadership Guide Workshop - DevTernity 2021
reverentgeek
1
370
Transcript
紹介 1/3 HYDRAの目的は・・・ 複数ジョブの実行や複雑なアプリケーション開発の 設定管理の効率化のためのフレームワーク こんな経験はありませんか? • 複数の実験設定を試す際に、パラメータの管理が煩雑になってしまう • 設定ファイルの変更履歴が追えず、どの設定で良い結果が出たのか分からなくなる
• 本番環境と開発環境で異なる設定を使いたいが、切り替えが面倒 はじめに
紹介 2/3 from omegaconf import DictConfig, OmegaConf import hydra @hydra.main(version_base=None,
config_path=".",config_name="config") def my_app(cfg): print(OmegaConf.to_yaml(cfg)) if __name__ == "__main__": my_app() # config.yaml db: driver: mysql user: omry password: secret $ python my_app.py db: driver: mysql user: omry password: secret $ python my_app.py db.user=root db.password=1234 db: driver: mysql user: root password: 1234 • @hydra.main()のデコレータで関数を装飾 • パラメタはyamlファイルで指定 • コマンドライン上から上書きが可能 • 実行ログやパラメタが記録され参照が可能 実行結果 上書き実行の結果 パラメタの読込/追跡
紹介 3/3 • 定義した複数の値を切り替えながら実行することも可能(マルチラン) • hydra-optuna-sweeper等プラグインと組み合わせパラメタ探索も可能 # @package hydra.sweeper sampler:
_target_: optuna.samplers.TPESampler seed: 123 consider_prior: true prior_weight: 1.0 consider_magic_clip: true consider_endpoints: false n_startup_trials: 10 n_ei_candidates: 24 multivariate: false warn_independent_sampling: true _target_: hydra_plugins.hydra_optuna_sweeper.optuna_sweeper.OptunaSweeper direction: minimize storage: null study_name: sphere n_trials: 20 n_jobs: 1 max_failure_rate: 0.0 params: x: range(-5.5,5.5,step=0.5) y: choice(0,1,2,3) パラメタ探索/最適化 Hydraとoptunaによる最適パラメタの探索 x -5 5 y 0 1 2 3 0