I think the most important thing is here's an army that had to go in a fight like that

US Defence Secretary James Mattis on Wednesday praised the Philippine military for upholding human rights in a five-month battle against pro-Islamic State group militants in a southern city.

Philippine defence chiefs on Monday declared the end of the nation's longest urban war in Marawi, where troops have been battling to flush out militants who attacked the city in what authorities said was a bid to establish a Southeast Asian caliphate.

Mattis, who was in the Philippines to attend a regional security meeting, heaped praise on the military of America's longtime ally and mutual defence partner.

"I think the most important thing is here's an army that had to go in a fight like that, and they had not one human rights allegation against them with any credibility, not one," Mattis told reporters.

"That's really a statement about the Philippine military that they could set a human rights condition in the midst of that awful fight in the way they did," he said on the sidelines of meetings in Clark, a northern Philippine city.

Hundreds of local and foreign gunmen who had pledged allegiance to IS rampaged through Marawi, the principal Islamic city in the mainly Catholic Philippines, on May 23.

An ensuing US-backed military campaign claimed the lives of more than 1,100 people, displaced 400,000 residents and left large parts of the city in ruins.

President Rodrigo Duterte imposed martial law across the southern third of the Philippines immediately after the fighting erupted, saying it was needed to contain IS's influence spreading throughout the region.

Mattis' comments came a day after he met with Duterte in what the Pentagon chief said was a "very warm" meeting.

"We talked about the way ahead and we're on the same team," Mattis said.

Despite Mattis' remarks, the Philippine Commission on Human Rights told AFP it was investigating allegations of abuse in Marawi after receiving complaints from local lawyers and a rights group.

Rights group Karapatan said it had documented cases of alleged civilian deaths due to the military's aerial bombings as well as illegal arrests and torture.

"That is a very sweeping statement by a US official," Karapatan secretary general Cristina Palabay told AFP in response to Mattis' comments.

Mattis on Monday hailed Philippine troops for "liberating" Marawi.

He is on an Asian trip that will also bring him to Thailand and South Korea.

Source:AFP