ALTON KUPRI, Iraq — The Islamic State group released about 200 Yazidis held for five months in Iraq, mostly elderly, infirm captives who likely slowed the extremists down, Kurdish military officials said Sunday.

Almost all of the freed prisoners are in poor health and bore signs of abuse and neglect. Three were young children. The former captives were being questioned and receiving medical treatment Sunday in the town of Alton Kupri.

Gen. Shirko Fatih, commander of Kurdish peshmerga forces in the northern Iraqi city of Kirkuk, said it appears the militants released the prisoners because they were too much of a burden. “It probably became too expensive to feed them and care for them,” he said.

Tens of thousands of Yazidis fled in August when the Islamic State group captured the northern Iraqi town of Sinjar, near the Syrian border. But hundreds were taken captive by the group, with some Yazidi women forced into slavery, according to international rights groups and Iraqi officials.