Abstract:To address the issues in existing electric vehicle charging path planning methods, namely the neglect of queuing randomness and the difficulty in balancing real-time performance with global optimality, this paper proposes a path optimization method based on Generalized Total Cost (TGC) and a hierarchical Deep Q-Network (DQN). First, an M/M/c queuing model is introduced to quantify the randomness of charging waiting time. The TGC framework assists the Deep Q-Network in unifying nonlinear queuing time, travel time, and time-of-use electricity price into a single scalar reward. Second, a Top-M pre-screening mechanism combined with an action validity mask is employed to resolve convergence difficulties caused by large action spaces, and experience replay is utilized to break data correlations. The method""s performance is evaluated in a constructed high-fidelity simulation environment. When the Top-M parameter is set to 10, the proposed strategy achieves a global optimal solution hit rate of 89.5%, an average relative regret value converging to 0.0122, and a single inference time reduced to 0.35 ms.