  Traffic simulation is an essential tool for transportation infrastructure
planning, intelligent traffic control policy learning, and traffic flow
analysis. Its effectiveness relies heavily on the realism of the simulators
used. Traditional traffic simulators, such as SUMO and CityFlow, are often
limited by their reliance on rule-based models with hyperparameters that
oversimplify driving behaviors, resulting in unrealistic simulations. To
enhance realism, some simulators have provided Application Programming
Interfaces (APIs) to interact with Machine Learning (ML) models, which learn
from observed data and offer more sophisticated driving behavior models.
However, this approach faces challenges in scalability and time efficiency as
vehicle numbers increase. Addressing these limitations, we introduce
CityFlowER, an advancement over the existing CityFlow simulator, designed for
efficient and realistic city-wide traffic simulation. CityFlowER innovatively
pre-embeds ML models within the simulator, eliminating the need for external
API interactions and enabling faster data computation. This approach allows for
a blend of rule-based and ML behavior models for individual vehicles, offering
unparalleled flexibility and efficiency, particularly in large-scale
simulations. We provide detailed comparisons with existing simulators,
implementation insights, and comprehensive experiments to demonstrate
CityFlowER's superiority in terms of realism, efficiency, and adaptability.
