A video showing a dozen Turkish police officers beating protesters with clubs has sparked criticism, on the day Turkish PM Recep Tayyip Erdogan praised police for their "heroic" action during the recent unrest.

The CCTV footage, obtained by lawyers from the Progressive Lawyers' Association, depicts a group of police officers beating the three young demonstrators with batons and clubs in the southern province of Antalya.

The protesters, who were hiding in a parking lot when the officers began hitting them, were not detained after the incident.

Erdogan hailed police during a graduation ceremony at the Police Academy.

"We will not let circles who have been adversaries of Turkey or international and national media to wear down our police. I and my government congratulate our police wholeheartedly" he said.

"On behalf of my country and nation, I would like to thank all my police siblings for standing up against incidents that have been going on for weeks, with sacrifice and patriotism."

Meanwhile, a police officer who allegedly shot and killed a demonstrator during the anti-government protests that swept across Turkey for three weeks was released in Ankara, after a court ruled that the shooting was "an act of self-defence".

Ethem Sarısülük, 27, was shot by a police officer in the capital's Kizilay Square during anti-government protests.

A video on YouTube purportedly shows an officer kicking away a demonstrator who is surrounded by 20 people waving flags and banners. The policeman points a gun at the group and fires before running off to a group of officers. A man collapses on the pavement as demonstrators surround the body and scream for help.