DG-SLAM: Robust Dynamic Gaussian Splatting SLAM with Hybrid Pose Optimization