# DQN Hyperparameter Tuning - Quick Reference ## Status Check (One-Liner) ```bash ps aux | grep tune_hyperparameters | grep -v grep && tail -5 /tmp/tuning_run.log ``` ## Monitor Progress ```bash # Real-time logs tail -f /tmp/tuning_run.log # Dashboard (refresh every 30s) watch -n 30 /tmp/monitor_tuning.sh # Check if still running pgrep -f "tune_hyperparameters.*50" || echo "Process finished!" ``` ## Stop/Kill ```bash # Graceful stop kill $(pgrep -f "tune_hyperparameters.*50") # Force kill kill -9 $(pgrep -f "tune_hyperparameters.*50") ``` ## View Results ```bash # Best hyperparameters cat results/dqn_tuning_50trials.json | jq '.best_trial' # Summary statistics cat results/dqn_tuning_50trials.json | jq '{ total_trials, successful_trials, failed_trials, best_sharpe: .best_trial.sharpe_ratio, best_loss: .best_trial.final_loss }' # Top 5 trials by Sharpe ratio cat results/dqn_tuning_50trials.json | jq '.all_results | sort_by(-.sharpe_ratio) | .[0:5]' ``` ## Re-run if Needed ```bash # Same 50-trial study target/release/examples/tune_hyperparameters \ --num-trials 50 \ --epochs-per-trial 50 \ --data-dir test_data/real/databento/ml_training \ --output results/dqn_tuning_50trials_v2.json \ > /tmp/tuning_run_v2.log 2>&1 & # Quick 10-trial study target/release/examples/tune_hyperparameters \ --num-trials 10 \ --epochs-per-trial 30 \ --data-dir test_data/real/databento/ml_training \ --output results/dqn_tuning_quick.json ``` ## Process Info | Item | Value | |------|-------| | PID | 3911478 | | Status | Running Trial 0/50 | | Progress | Epoch 46/50 (92% of first trial) | | ETA | ~4 hours (21:00 CEST) | | Output | results/dqn_tuning_50trials.json | ## Expected Best Config (Pilot Study) Based on pilot study (Agent 49): ```yaml Learning Rate: 0.001 Batch Size: 230 Gamma: 0.99 Epsilon Decay: 0.999 ``` This study will validate and potentially improve upon this baseline.