Model-Resource Co-Optimization for Collaborative Inference in VEC-Enabled Autonomous Driving