The attacker who carried out a deadly suicide bombing in Ankara was a 24-year-old woman who allegedly joined the Kurdish rebels in 2013 and trained in Syria, Turkey's interior ministry has said.

The government statement identifies the bomber blamed for killing 37 people, including herself, as Seher Cagla Demir.

The statement says Demir joined the PKK rebels, crossed into Syria and received what it called "terror training" from a PKK-linked Syrian Kurdish militia.

A possible male accomplice, who was also killed, has not yet been identified.

Turkey considers the Syrian Kurdish militia - known as the People's Protection Units, or YPG - as a terror organisation because of its affiliation with the PKK and has been pressing the United States to stop helping the group. Washington considers the PKK a terrorist organisation but has backed the YPG, which has been effective in fighting Islamic State.

Turkey had blamed the Syrian Kurdish militia force for a February 17 bombing in Ankara that killed 29 people, saying the group had acted in concert with the PKK. But a Turkey-based Kurdish militant group that is an off-shoot of the PKK later claimed that attack.

No group has yet claimed Sunday's attack in the capital.

The attack escalated tensions with the Kurds and further complicated Turkey's place in the region as it battles a host of enemies across its borders including the Syrian government, Kurdish rebels in both Iraq and Syria, and IS.

Turkey has also been forced to absorb 2.7 million refugees from the war in Syria, and Europe is pressing to return thousands more migrants back to Turkey.

Turkey's air force carried out retaliatory air strikes on Monday against suspected PKK targets in northern Iraq, including on the Qandil mountains where the group's leadership is based. On Tuesday, the military said those air strikes killed at least 45 Kurdish rebels - a claim that could not independently be verified.

Turkish authorities, meanwhile, imposed a round-the-clock curfew and entry ban in the low-income Baglar neighbourhood of Diyarbakir, the largest city in the country's mainly-Kurdish south east region. Kurdish militants there set cars on fire overnight, triggering clashes that left one police officer and three Kurdish militants dead.

Turkey this week also declared 24-hour curfews and launched large-scale operations against Kurdish militants in the south east towns of Nusaybin and Yuksekova and in the city of Sirnak.

At the same time, Turkish police pressed ahead with a security sweep across the country, detaining 55 people suspected of being members of a group that is considered the youth wing of the PKK in six provinces, the state-run Anadolu Agency reported.

President Recep Tayyip Erdogan said the aim of the Ankara attack was to sow fear among the public and "deter Turkey from its aims, its path and aspirations".

"They will not be successful," Mr Erdogan said. "They will not bring Turkey to its knees; on the contrary they will be the ones kneeling."

He spoke at a joint news conference with Azerbaijani president Ilham Aliyev, who arrived in Ankara in a show of solidarity.

The PKK is fighting Turkey for Kurdish autonomy in the south east. The fragile two-year peace process collapsed in July, reigniting the conflict.