Robotics Programming Language

I am planning on creating a robot on my own. For the robot I want to implement some object recognition and ai. I was wondering what the best programming language would be for that. As of now I am considering java and python, but I am not sure which would be better. Thanks