Get breaking news alerts and special reports. The news and stories that matter, delivered weekday mornings.

A federal operation to arrest undocumented immigrants this week netted nearly 500 people in cities and states that have openly opposed the Trump administration's deportation initiatives.

Immigration and Customs Enforcement officials said Thursday that its four-day "Operation Safe City" targeted people in New York, Los Angeles, Philadelphia, Denver, Washington and Baltimore as well as Cook County, Illinois; Santa Clara County in California's Bay Area; Portland, Oregon; and Massachusetts.

ICE arrests over 450 on federal immigration charges during Operation ‘Safe City’ https://t.co/SxsnVlQ4X5 pic.twitter.com/YgOLHcdLEp — ICE (@ICEgov) September 28, 2017

Officials in those places — some referring to themselves as "sanctuary" communities — have been vocal about not fully cooperating with federal immigration authorities, at times clashing with state leaders who support President Donald Trump's agenda. Sanctuary communities have passed ordinances limiting compliance with federal immigration laws and seek to shield undocumented immigrants who may be deported simply over their immigration statuses or low-level criminal offenses.

"Sanctuary jurisdictions that do not honor detainers or allow us access to jails and prisons are shielding criminal aliens from immigration enforcement and creating a magnet for illegal immigration," Tom Homan, ICE's acting director, said in a statement. "As a result, ICE is forced to dedicate more resources to conduct at-large arrests in these communities."

It is not unusual for ICE to round up immigrants by the hundreds or even low thousands, although the latest raid comes on the heels of a planned operation that would have targeted about 8,400 undocumented immigrants this month.

The Morning Rundown Get a head start on the morning's top stories. This site is protected by recaptcha

Related: ICE Cancels Huge Nationwide Immigration Raid

But the Department of Homeland Security scrapped the operation after the agency said it was halting nationwide enforcement actions in the wake of hurricanes Irma and Harvey.

This latest effort indicates the administration is ready to renew its efforts.

"ICE's goal is to build cooperative, respectful relationships with our law enforcement partners to help prevent dangerous criminal aliens from being released back onto the streets," Homan said.

According to ICE, of the 498 people arrested this week, 317 had criminal convictions. Some were also categorized as "immigration fugitives," "previously deported criminal aliens," and/or associated with a gang.

Most of the criminal convictions were for driving under the influence as well as assault- and drug-related offenses, ICE said. Others were arrested for marijuana possession, traffic offenses and even charges of being a "peeping tom."

Those arrested were originally from countries such as El Salvador, India, Guatemala, Mexico and the Dominican Republic, ICE added.

Attorney General Jeff Sessions has warned cities that supporting sanctuary policies could cause them to lose millions in federal grants — particularly if they don't help the federal government deport suspected undocumented immigrants already being held in jails.

During a visit to Portland this month, Sessions told officials that "to win this multifront war against rising crime, we need to use every lawful tool we have."

Related: Spurred by Trump, States Battle Their Sanctuary Cities

City officials declared Portland a sanctuary city in March, and its mayor, Ted Wheeler, has criticized the Trump administration's push to end the Obama-era program that has allowed undocumented immigrants who came to the United States as children to remain in the country.

The administration, meanwhile, has faced setbacks as it seeks to overhaul immigration — an issue that has failed repeatedly to gain traction in Congress.

Two weeks ago, a U.S. district judge in northern Illinois gave sanctuary cities a temporary victory, saying the Justice Department can't withhold public safety grants to Chicago because officials there don't want to impose certain immigration policies.