The New York Police Department’s new policy on body cameras is flawed and should be reviewed by a federal judge, lawyers and community leaders said Thursday.

Attorneys for a class-action lawsuit said in court papers the new policy for the cameras, set to be rolled out later this month, should require that more encounters with police and the public be recorded. The body camera program was ordered as part of a civil rights judgment that found the NYPD wrongly targeted minorities with its stop and frisk policy. Community groups also wrote letters to the judge challenging the policy.

A court-ordered monitor approved the body camera policy last week, but the lawyers say the judge also should weigh in, especially given their objections.

“The purpose of the pilot will be substantially undermined by a failure to collect a large body of information on whether officers understand and are following the rules,” lawyers wrote.

They also objected to the decision to allow officers access to their video in some cases before making statements or writing reports in cases that aren’t criminal.

“Separating an officer’s personal recollection of an incident from the narrative on his or her body-worn camera video is of critical importance to the use of (body cameras) as an accountability tool,” they wrote.

Police are set to deploy the first of 5,000 cameras at the end of the month.

City officials defended the policy and said it would respond to the legal challenge.

“The NYPD’s body worn camera procedures — which were approved by the federal monitor — were shaped by the input of New Yorkers, police officers, civil rights advocates and law enforcement from around the country,” spokesman Austin Finan said. “The deployment of body cameras will usher in a new day of policing in New York City that will further bolster the atmosphere of transparency and accountability that has grown in recent years, helping us continue to keep New York City the safest big city in the country.”