KYIV -- Thousands of activists have marched in Ukraine's capital, marking an annual celebration of gay and lesbian rights that has been marred by violence in the past.

The June 17 March of Equality in Kyiv, which took place amid an increased police presence, was one of the largest such events staged in Ukraine in years.

Clashes broke out early in the morning when riot police dispersed more than 150 far-right protesters seeking to block off the route of the march, police said in a statement.

But no serious incidents occurred during the march, and Kyiv police chief Andriy Krischenko said 57 members of radical groups were detained.

Police said about 3,5000 people attended the march, which started near Taras Shevchenko Park and lasted less than one hour. Organizers said there were at least 5,000 participants.

Roads were closed for cars in the city center, and 5,000 police and soldiers from the National Guard were deployed to protect the marchers.

During the early morning clash, the ultranationalist group C14 said police officers surrounded its protesters attacking them with batons and tear gas.

Police said they detained more protesters in an altercation near the Opera House.

The organizers of the march, who received threats from far-right groups, had advised the participants not to hold posters, banners, or symbols of the LGBT (lesbian, gay, bisexual, and transgender) community until they arrived at the event area.

“We want to feel free in our country,” said Tymur Levchuk of Kyiv Pride, a nine-day series of events in Kyiv, including conferences, movie screenings, and artistic performances that ended with the march.

“Kyiv is a city where there should be no discrimination, violence, or alienation,” he said. “This is a city where everyone can be themselves.”

Kyiv held its first major pride march in 2016 after a pro-Western government that came to power in 2014 sanctioned such events.

In 2015, the march was called off when right-wing activists pelted participants with smoke grenades.

At last year's march, thousands also participated, but a counterdemonstration by a few hundred ultranationalists degenerated into scuffles with police.

With reporting by Reuters, Interfax, and the Kyiv Post