A stampede on Wednesday among thousands of mourners at the funeral of a powerful southern Indian politician killed two people and injured 47, a doctor at a government hospital said.