Washington, DC- U.S. President Barack Obama on Tuesday urged police departments nationwide to do some 'soul searching' with how they handle African American suspects after racially motivated riots erupted in Baltimore.

Obama stated that it was important that various police departments recognize that they have a problem with how they handle criminal suspects that are not white.

Obama said, "There are some police who aren't doing the right thing and rather than close ranks some police chiefs have recognized that they've got to get their arms around the problem."

In a joint press conference with Japanese Prime Minister Shinzo Abe, Obama made his first statement about Freddie Gray, the Maryland man who died April 19 from a spinal injury after being arrested by police in Baltimore.

Gray's funeral, held on Monday, prompted protests locally in Baltimore that resulted in violent riots and looting throughout the day and into the night. The violence resulted in the looting of several local businesses as well as the burning of a CVS pharmacy store.

After the violence erupted, Obama brought attention to the race issues by stating, "We can't just leave this to the police. I think there are police departments that have to do some soul searching. I think there's some communities that have to do some soul searching. But I think we as a country have to do some soul searching. This is not new. It's been going on for decades."

Obama stated that the violence in Baltimore distracted the peaceful protests by people that 'did it the right way' and he said it was perpetrated by criminals and thugs.

He also extended his sympathy to the family of Gray as well as to the police officers that were injured in Monday's violent rioting.

During the violent protests Monday, at least 20 police officers were injured and more than 230 people, mostly juveniles, were arrested. 15 structures burned and nearly 150 cars were set on fire. Baltimore has set a one week citywide curfew for all residents of 10 p.m. through 5 a.m. that begins today.