School lunches have been getting a lot of attention, especially since President Obama signed a $4.5-billion bill last December to improve the quality of students’ meals. In Los Angeles, the schools superintendent announced this week he was considering a ban on sugary chocolate milk, while in San Antonio, health researchers installed cameras in lunch rooms to monitor what kids were eating.

The San Antonio program, made possible by a $2 million research grant from the U.S. Department of Agriculture, involves placing cameras in cafeteria lines and in the trash area in order to document what kids buy for lunch and how much of it they consume.

The idea is to help school officials create healthier lunches based on what kids actually like to eat. The data can also help parents plan better meals at home: if Junior’s eating nothing but French fries at lunchtime, parents can try to balance out his diet with a dinner of vegetable and lean proteins.

Epidemiologists who focus on childhood nutrition at the public-health level could also use the findings to determine where the most pressing changes need to be made — and to better understand how children’s diets factor into rates of obesity and weight-related diseases like Type 2 diabetes.

“We will be able to determine whether current programs that are aimed at preventing obesity work, and whether they are really changing students’ behavior,” Dr. Roberto Trevino of the Social & Health Research Center, which is leading the program, told Reuters.

For the pilot program, the researchers installed cameras in five public elementary schools in poor districts in San Antonio. They picked the schools because they had high rates of child obesity and poverty. (Indeed, within that county, Bexar County, 33% of children who live in poverty are obese.)

The cameras take snapshots of children’s trays before they sit down and again after they’ve eaten; using sophisticated food-recognition software, the computer program analyzes the color, shape, volume, density and texture of every single piece of food on a child’s tray and compares them to a database of 7,500 foods. That allows researchers to monitor the calories, fat, fiber, sugar and protein — a total of 128 nutrients — kids eat in each meal.

Although each child’s meals will be tracked by a bar code on his or her tray, the cameras will not capture images of the kids themselves. But the school will be able to send individual dining data to the parents who agreed to allow their kids to participate in the study. The researchers hope the information will help improve home food environments as well.