State media say a court in China's western Xinjiang region has sentenced to death 12 people blamed for terrorist attacks that killed 37 people in July.

Xinhua News Agency said Monday that the court in Kashgar prefecture sentenced another 15 people to death with a two-year reprieve, and nine people received life sentences. Xinhua said another 20 defendants received terms of four to 20 years.

Xinhua reported in August that attackers armed with knives and axes had stormed a police station and government offices and that police had killed 59 of the attackers.

The U.S.-based Uyghur American Association, however, said police opened fire on people protesting a security crackdown on Muslims during Ramadan, killing more than 20.

The Associated Press was unable to independently confirm either report.