Updated

The University of Louisville apologized to the school's entire Hispanic community Thursday after a photo surfaced showing President James Ramsey among a group of staffers at a Halloween party dressed in matching stereotypical Mexican costumes.

They wore bushy mustaches and sombreros, and rattled maracas as they posed for the photo.

Ramsey's chief of staff, Kathleen Smith, issued a statement expressing "deep regret" over the incident.

"We made a mistake and are very sorry," she wrote, adding that the university pledges to train staff and engage with the campus over diversity and racial equality issues. "This event shows we have much more to learn about our community."

The photo was taken on Wednesday afternoon, at an annual Halloween luncheon for Ramsey and members of his staff at a mansion owned by the university, said spokesman John R. Karman. Ramsey is seen smiling and leaning on a porch railing, wearing a sombrero and a rainbow-striped poncho trimmed in fringe.

He is surrounded by people clad mostly in black clothing with fake mustaches and beards stuck to their faces. Most have sombreros on their heads and maracas in their hands.

The photo began making the rounds on social media Thursday, sparking outrage and bewilderment.

A friend showed it to Freshman Leonardo Salinas.

"I was appalled," he said. "It's not just offensive to Mexicans; it's offensive to the immigrant community as a whole. Someone thought, `Oh, this is a good idea.' How did it not click in anybody's mind that it was a very bad idea?"

Sarah Nunez, the university's director of the Office of Hispanic and Latino Initiatives, said she said heard from many of the university's 712 Hispanic undergraduates, and some of the 150 faculty and staff.

"Some students shared that they felt this was degrading to them, and disrespectful," she said. "They feel hurt. They feel like their trust was broken."

The University's student newspaper, The Louisville Cardinal, published a column Thursday afternoon criticizing the president for the stereotypical costume: "Don't dress like a culture. They aren't costumes, they're people," the column read.

Karman said Ramsey was unavailable for an interview.  He did not release a statement in addition to Smith's.

The photo emerged at an inopportune time for the university, which is already mired in a sex scandal.

A woman named Katina Powell released a book called "Breaking Cardinal Rules: Basketball and the Escort Queen" that alleged she was paid thousands of dollars by a former director in the university's men's basketball program to strip and have sex with recruits and players. Multiple investigations into her allegations are pending.

The Halloween photo was posted in a slideshow on the Courier-Journal newspaper's website. It accompanied a story about Amelia Place, a mansion owned by the university where past presidents have lived. Instead of moving in, Ramsey and his wife opted to use the giant home for events such as the Halloween costume luncheon.

Smith addressed her apology to the school's Hispanic students, faculty and staff. She wrote that the administration has since met with Nunez and will work on programs to build a diverse and inclusive campus.

Both Nunez and Salinas said they hope the incident will push the university to invest in its relationship with its Hispanic students.

"There could be a silver lining to this terrible situation," Salinas said. "The university realized it's a problem and they need to fix it. It has to be not only something they talk about, but something they act on."