A court in Bahrain sentenced one person to death and 22 others to life in prison over two deadly bomb attacks last year, reports say.