- Fixed PSO budget calculation bug in ml/src/hyperopt/optimizer.rs - Root cause: Division by n_particles in sequential execution - Now correctly calculates max_iters = remaining_trials (no division) - Result: 50 trials complete instead of 23 (100% vs 46%) - Added comprehensive DQN hyperopt results analysis - 39/50 trials analyzed across 2 RunPod deployments - Best hyperparameters identified: LR 4.89e-5 (ultra-low) - Created DQN_HYPEROPT_RESULTS_SUMMARY.md with expert validation - GitLab CI/CD pipeline operational (48 lines fixed) - Fixed YAML syntax errors (unquoted colons) - All 7 jobs validated and working - Warning cleanup complete (136 → 0 warnings) - Removed 143 lines dead code - Fixed visibility, unused imports, Debug traits - Archived Wave D reports to docs/archive/ - 8 early stopping reports moved - Root directory cleaned up 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
124 lines
4.9 KiB
Bash
Executable File
124 lines
4.9 KiB
Bash
Executable File
#!/bin/bash
|
|
# S3 Log Monitor Demo - Usage examples for foxhunt-deploy monitor command
|
|
|
|
set -e
|
|
|
|
echo "=== S3 Log Monitor Demo ==="
|
|
echo ""
|
|
|
|
# Check prerequisites
|
|
if [[ -z "$AWS_ACCESS_KEY_ID" ]]; then
|
|
echo "ERROR: AWS_ACCESS_KEY_ID not set"
|
|
echo "Please set RunPod S3 credentials:"
|
|
echo " export AWS_ACCESS_KEY_ID='your_key'"
|
|
echo " export AWS_SECRET_ACCESS_KEY='your_secret'"
|
|
exit 1
|
|
fi
|
|
|
|
# Example pod ID (replace with your actual pod ID)
|
|
POD_ID="${1:-dy2bn5ninzaxma}"
|
|
|
|
echo "Pod ID: $POD_ID"
|
|
echo ""
|
|
|
|
# Function to run example
|
|
run_example() {
|
|
local description="$1"
|
|
local command="$2"
|
|
|
|
echo "────────────────────────────────────────────────────────────────"
|
|
echo "Example: $description"
|
|
echo "Command: $command"
|
|
echo "────────────────────────────────────────────────────────────────"
|
|
echo ""
|
|
echo "Press Enter to run (or Ctrl+C to skip)..."
|
|
read -r
|
|
|
|
eval "$command"
|
|
echo ""
|
|
}
|
|
|
|
# Example 1: List available log files
|
|
run_example \
|
|
"List all log files for the pod" \
|
|
"foxhunt-deploy monitor $POD_ID --list"
|
|
|
|
# Example 2: Show last 20 lines
|
|
run_example \
|
|
"Show last 20 lines of logs" \
|
|
"foxhunt-deploy monitor $POD_ID --tail 20"
|
|
|
|
# Example 3: Show last 50 lines
|
|
run_example \
|
|
"Show last 50 lines of logs" \
|
|
"foxhunt-deploy monitor $POD_ID --tail 50"
|
|
|
|
# Example 4: Follow logs in real-time
|
|
echo "────────────────────────────────────────────────────────────────"
|
|
echo "Example: Follow logs in real-time (Ctrl+C to exit)"
|
|
echo "Command: foxhunt-deploy monitor $POD_ID --follow"
|
|
echo "────────────────────────────────────────────────────────────────"
|
|
echo ""
|
|
echo "This will stream logs continuously. Press Ctrl+C to stop."
|
|
echo "Press Enter to start..."
|
|
read -r
|
|
|
|
foxhunt-deploy monitor "$POD_ID" --follow
|
|
|
|
# Example 5: Follow with initial tail
|
|
echo ""
|
|
echo "────────────────────────────────────────────────────────────────"
|
|
echo "Example: Follow logs with initial 10 lines"
|
|
echo "Command: foxhunt-deploy monitor $POD_ID --follow --tail 10"
|
|
echo "────────────────────────────────────────────────────────────────"
|
|
echo ""
|
|
echo "Press Enter to start (Ctrl+C to stop)..."
|
|
read -r
|
|
|
|
foxhunt-deploy monitor "$POD_ID" --follow --tail 10
|
|
|
|
# Example 6: Filter by pattern
|
|
echo ""
|
|
echo "────────────────────────────────────────────────────────────────"
|
|
echo "Example: Filter logs for 'epoch' or 'loss'"
|
|
echo "Command: foxhunt-deploy monitor $POD_ID --follow --filter 'epoch|loss'"
|
|
echo "────────────────────────────────────────────────────────────────"
|
|
echo ""
|
|
echo "Press Enter to start (Ctrl+C to stop)..."
|
|
read -r
|
|
|
|
foxhunt-deploy monitor "$POD_ID" --follow --filter "epoch|loss"
|
|
|
|
# Example 7: Filter for errors only
|
|
echo ""
|
|
echo "────────────────────────────────────────────────────────────────"
|
|
echo "Example: Show only errors and warnings"
|
|
echo "Command: foxhunt-deploy monitor $POD_ID --follow --filter 'ERROR|WARN'"
|
|
echo "────────────────────────────────────────────────────────────────"
|
|
echo ""
|
|
echo "Press Enter to start (Ctrl+C to stop)..."
|
|
read -r
|
|
|
|
foxhunt-deploy monitor "$POD_ID" --follow --filter "ERROR|WARN"
|
|
|
|
echo ""
|
|
echo "=== Demo Complete ==="
|
|
echo ""
|
|
echo "Common usage patterns:"
|
|
echo ""
|
|
echo "1. Quick check: Show last 20 lines"
|
|
echo " foxhunt-deploy monitor $POD_ID --tail 20"
|
|
echo ""
|
|
echo "2. Monitor training: Follow in real-time"
|
|
echo " foxhunt-deploy monitor $POD_ID --follow"
|
|
echo ""
|
|
echo "3. Debug errors: Filter for problems"
|
|
echo " foxhunt-deploy monitor $POD_ID --follow --filter 'ERROR|WARN|CRITICAL'"
|
|
echo ""
|
|
echo "4. Track metrics: Filter for training stats"
|
|
echo " foxhunt-deploy monitor $POD_ID --follow --filter 'epoch.*loss|accuracy'"
|
|
echo ""
|
|
echo "5. List logs: See all available log files"
|
|
echo " foxhunt-deploy monitor $POD_ID --list"
|
|
echo ""
|