Baghdad (CNN) -- U.S. Vice President Joe Biden paid tribute Thursday to the sacrifices of U.S. and Iraqi troops at a ceremony for service members from both nations.
He and Iraqi Prime Minister Nuri al-Maliki addressed about 120 U.S. service members and 100 Iraqi troops gathered at al-Faw Palace, the Baghdad edifice that once belonged to dictator Saddam Hussein.
The trip came amid a U.S. military withdrawal from the Middle Eastern country. Virtually all American troops are scheduled to be out by the end of the year.
As part of the process, control of Camp Victory in Baghdad will transfer from the United States to Iraq on Friday, after which it will cease to be known by that name, White House officials said.
While security has improved, at least 20 people were killed and dozens were wounded in attacks and shootings on Thursday, Iraqi government officials told CNN.
Speaking at the main event marking the departure of U.S. troops, Biden thanked the service members and recognized their achievements during the past 8-1/2 years.
"This palace, a grotesque monument to a dictator's greed, is totally filled with American and Iraqi warriors who were bound together by shared sacrifice in the service of both their countries," Biden said. "An appropriate use of this palace today. Here in Iraq you warriors became partners and friends and now, undeniably, brothers-in-arms.
"All of you standing before me today have laid the foundation for a long-term, strategic partnership between our nations, and also for an Iraq that -- against all odds -- can serve as a source of stability not only for its people but here in the region and for years to come."
He added, "I think it's fair to say, almost no one thought that was possible a few years ago. So, on behalf of President Obama and the American people, let me say to both our armed forces today: Thank you. Thank you for your heroic work that each one of you has done to bring about this moment.
"Because of you, and there's no exaggeration to say that, because of you and the work of those of you in uniform have done, we are now able to end this war."
Biden said the United States is keeping promises made to Iraq to withdraw its forces, and he dismissed skeptics who argue the Iraqi security forces are not equipped to take over, saying they are "more than ready."
Al-Maliki said Iraq was becoming a more stable place, and all Iraqis should be proud of what has been achieved, adding that it was not a success for any particular party, sect or ethnicity.
But he noted that the country's people have paid a huge price in lives and property.
Iraqi President Jalal Talabani and U.S. Ambassador to Iraq James Jeffrey were also present at the ceremony.
After the event, Biden traveled on to the Kurdish city of Irbil in northern Iraq, where he met Massoud Barzani, head of the Kurdistan regional government.
After the transfer of Camp Victory on Friday, U.S. troops will have only five bases across the country, down from 505 at the height of the surge there, the U.S. military spokesman in Iraq, Maj. Gen. Jeffrey Buchanan, told CNN Wednesday.
Some 13,000 U.S. soldiers are deployed in Iraq, down from 170,000, with that number dropping daily, Buchanan said.
Iraqi security forces, including army and police officers, are to assume full responsibility for the country's security by the end of the year, under the deal agreed to by Iraq and the United States.
Qassim Abdul Kareem Jafar, an Iraqi government employee, told CNN it is a positive move.
"I believe the decision of the U.S. military to withdraw is a correct one. I believe we are ready, and all the good people will help the Iraqi government to succeed and push the occupiers out of Iraq," he said.
But his confidence was not shared by all. Iraqi college student Ali Abbas said: "I don't want to dismiss the efforts made by the people working to secure this country, but the Iraqi army needs to be more ready, they are about 55%-60% ready. I wish they can be developed more."
Violence in Iraq is at its lowest level since 2003, according to the White House. But a number of incidents shattered the peace Thursday morning.
In Khalis, a predominantly Shiite town in Diyala province, about 75 kilometers (47 miles) north of Baghdad, at least 13 people were killed and 31 others wounded when a car bomb exploded in an outdoor market, Mayor Odai al-Khadran told CNN.
In al-Jeel, a predominantly Sunni town that was controlled by al Qaeda in Iraq at the peak of the country's sectarian violence, gunmen stormed three houses and killed seven people, including two women and a child, police in Baquba told CNN. Five other people were wounded, including three women.
In Baghdad, two roadside bombs exploded in two locations, wounding nine people, including four police officers, Baghdad police told CNN.
Negotiations over a possible extension of the U.S. military presence collapsed this year after Iraq's political leaders refused to grant U.S. troops legal immunity, opening the prospect of soldiers being tried in Iraqi courts and being subjected to Iraqi punishment.
About 150 U.S. troops are expected to remain after the December 31 deadline, a U.S. official told CNN.
After he finished his speech, Biden flew to Ankara, Turkey, the first stop on a four-day visit to Turkey and Greece, where he is to meet with leaders to discuss what his office called "the full range of bilateral, regional, and international issues."