Dinesh Joshi, who was the first non-white constable in Scotland's police force in the 1970s amidst considerable racial tension, is preparing to retire after having witnessed Edinburgh's transformation as a "truly multicultural city".
Joshi, 59, hails from India, His family moved to Kenya and then to the UK in 1975.
During his career over 30 years in the police force, Joshi was responsible for improving race relations at various levels between the police and the public.
Over the years, Joshi has seen the number of ethnic minority officers climb to 42 among a force of 2721.
He said: "Ethnic communities feel much more comfortable with reporting racist incidents. The police have changed in many ways over 30 years.
"I like to think I was a pioneer. But we need even more young people from ethnic groups to join the force and become part of a thriving Scottish society. That is how you make a difference."
Joshi, who also served as chairman of the Edinburgh and Lothian Racial Equality Council, says that when he decided to join the police, his family was shocked, particularly because of their experiences in Kenya.
"At that time there were no black officers in Lothian and Borders so I knew I would be the first. But I always said if you want to make change, you need to do it from the inside rather than stand on the outside and point fingers," he said.
Joshi spent the eight years working as a constable in Dalkeith, Midlothian where he said he would overhear officers in the canteen laughing while making racist comments.
But while the comments were not directed at him, he said that racism was part of the force's culture at that time, but this had changed for the better over the years.
He said: "When I joined I was seen as different because of the pigmentation of my skin. Those kinds of divides don't exist any more. But I've never believed that my race affected my prospects in the police. The person with the experience and the credentials gets the job.
"I would not agree that there is institutional racism in the force," he told the Evening Standard.
Joshi later spent seven years as a detective constable in Musselburgh before his promotion to sergeant where he was put in charge of eight constables based in Wester Hailes.
He added: "I was treated like any other officer during my time in Wester Hailes. Any abuse would be the same as my white colleagues received.
"There is a much more accepting attitude in Edinburgh now and we are a truly multi-cultural society.
"Black and ethnic communities enjoy respect although you will still find isolated pockets of racism.
That is down to a lack of education. There is a much better mixing of communities in the city nowadays and a better understanding of different cultures."
Joshi is married to Rohiri, 47, and the two have two children Aarti, 27, a PR consultant, and Sapna, 24, an architecture graduate.