WASHINGTON — Weeks of mounting tensions between the military and detainees at the wartime prison at Guantánamo Bay, Cuba, escalated into violence on Saturday during a raid in which guards forced prisoners living in communal housing to move to individual cells.

“Some detainees resisted with improvised weapons, and in response, four less-than-lethal rounds were fired,” the military said in a statement. “There were no serious injuries to guards or detainees.”

Capt. Robert Durand, a military spokesman at the base, said the improvised weapons included “batons and broomsticks.” Another military official said that at least one detainee had been hit by a rubber bullet, but that there were no further details about any minor injuries or how the prisoners had resisted.

The raid came shortly after a delegation from the International Committee of the Red Cross completed a three-week visit to examine the prisoners and study the circumstances of a hunger strike that has been roiling the camp for weeks. The Red Cross visit concluded on Friday, and most of the delegation left that same day, though a few flew out Saturday morning, said Simon Schorno, a Red Cross spokesman.