MOSUL, Iraq (AP) — Hundreds of suspected Islamic State members swept up by Iraqi forces in Mosul are being held in a cramped and stifling prison just outside the city.

Associated Press reporters visiting the facility saw more than 100 prisoners packed into a dark room, lined up shoulder to shoulder on the floor. There was no electricity or ventilation, despite daytime temperatures well over 110 degrees F (45 C).

The Iraqi officer who oversees the facility said it currently holds some 370 prisoners. He says authorities were overwhelmed with detainees as Iraqi forces cleared the last neighborhoods of the city earlier this month at the end of a grueling nine-month campaign.

"Prisoners are infected with diseases, lots of health and skin problems, because they're not exposed to the sun," he said. "The majority can't walk. Their legs are swollen because they can't move." He said a provincial health team checks on the prisoners "occasionally."

More than 1,150 detainees have passed through the prison over the past three months, with 540 sent to Baghdad for further investigation, the officer said. Another 2,800 prisoners are being held in the Qayara air base south of Mosul, and hundreds more in a few smaller facilities. The officer spoke on condition of anonymity because he was not authorized to brief reporters.

The Islamic State group seized Mosul when it swept across northern and central Iraq in the summer of 2014.

As U.S.-backed Iraqi forces battled block by block to retake the city, the militants rounded up civilians and used them as human shields. Many fighters also fled the city by hiding among fleeing residents, complicating efforts by Iraqi forces to separate the militants from civilians.

Prisoners who were discreetly interviewed by the AP insisted they were innocent. They spoke on condition of anonymity, fearing reprisals.

"You won't find 10 real (IS members) among these guys. And all of them have spent more than six months here," one prisoner said out of earshot of the guards. "Since I got here eight months ago, I've only seen the sun once."

He said he was a civil servant and had traveled between Baghdad and Mosul on several previous occasions before being detained.

"They said my name was in their database. I haven't seen any court or judge. I don't even know what I'm accused of. A lot of names are the same," he said.

He said two prisoners had died in the packed holding cell. Some prisoners "have pus coming out of their wounds. Once they go to the hospital, they come back with amputated legs or arms."

"We really want to die," another prisoner said. "None of us have received any visitors, relatives, family members. They don't even know where we are."