In what civil libertarians are calling a "big win for transparency" in law enforcement, the California Supreme Court has decided the public is entitled to see at least some of the massive amounts of data collected by police and sheriff’s license plate capture program.

The decision was announced Thursday in the American Civil Liberties Union's lawsuit against the LAPD and L.A. Sheriff’s Department.

The two agencies use cameras mounted on police cars and light poles to photograph three million license plates weekly– noting the time of day and location of each car as it passes by or is parked on the street.

In its lawsuit, the ACLU said the public was entitled to the information the departments were collecting.

"Police use license plate readers to collect information on the location and movements of millions of Los Angeles drivers who’ve never been suspected of any crime," said ACLU attorney Peter Bibring. "That poses a serious threat to privacy and the public deserves to know how that program operates."

But police said the data is part of its investigations - one of several categories of information government agencies do not have to make public under 1968 California Public Records Act.

Police agencies use this broad category to keep from the public eye a wide range of information, including their investigations into officer involved shootings and major crimes like murders.

The state supreme court overturned a lower court ruling that agreed with police. Instead, the high court said such indiscriminate and broad data collection could not possible be categorized as part of an investigation.

"The scans are not conducted as part of a targeted inquiry into any particular crime or crimes," the court said in its unanimous opinion. "The scans are conducted with the expectation that the vast majority of the data collected will prove irrelevant for law enforcement purposes."

Police do use the information – to find stolen cars and in investigations involving tracking suspects by using their car. There may be other ways it uses the information – and that’s what the ACLU wanted to find out.

License plate readers make police more efficient, Darren Wyatt of the Anaheim Police Department explained to KPCC last year. "If you're driving around in a patrol car, you have one set of eyes," Wyatt said. "The cameras are around the entire vehicle."

"It's a technology that makes an officer's job much easier," he said.

But Bibring said police departments need watchdogging for possible racial profiling or even over use of license plate gathering in rich neighborhoods for one reason or another.

The court realized that technology makes a difference," Bibring said. "When the legislature created the public records act exemption for law enforcement investigation in 1968, they didn’t intend to keep from the public this kind of mass collection of data."

At the same time, citing privacy concerns, the court said the public does not have the right to the raw data.

It is voluminous: the LAPD and Sheriff’s Department said in court papers during the original trial that it had recorded 160 million license plate numbers, with time and GPS stamps, as of 2012, according to Bibring. That’s a record of every driver’s car every three or so weeks, he added. More recent data for the agencies was not available.

About 25 police agencies in Los Angeles County have license plate reader programs, said Bibring. Police in Long Beach have about 50 readers, which in 2015 read plates about 23 million times, LBPD's Brad Johnson told KPCC last year.

The court sent the case back to the trial judge to address how to keep drivers’ identities secret. The ACLU suggested eliminating the license numbers and replacing them with random numbers and letters.

"The sheriff’s department is comfortable with the ruling," said Dean Gialamas, director of the agencies technical services division. "Our primary concern is really privacy issues for the public."

A spokesman for the LAPD said the department is reviewing the ruling.

Police also raised concerns that releasing any data could reveal who is being investigated, patrol patterns, or investigation techniques. The state high court did not find merit in those arguments.

The ruling could have implications for access to data collected in other ways. For instance, the federal government is using its own mobile cell phone towers to listen in on phone calls. But those towers – some attached to planes in the air – collect information on other calls in the area, said Bibring. He knew of no federal court ruling similar to this one.