Bias Detection and Generalization in AI Algorithms on Edge for Autonomous Driving