Two Los Angeles police officers have been charged with repeatedly sexually assaulting four women, including while they were on duty, prosecutors announced Wednesday.

James Nichols and Luis Valenzuela, who worked as partners, were charged with multiple counts of sexual assault, including forcible rape, rape under color of authority, oral copulation under color of authority, and oral copulation by force. Valenzuela is also charged with one count of assault with a firearm for allegedly pointing a gun at one of the victims, Los Angeles County prosecutors said.

The charges stem from a Los Angeles Police Department investigation into complaints that Nichols and Valenzuela sexually assaulted women years ago. Investigators inside the LAPD's internal investigations unit first looked into the allegations before handing it over to the robbery homicide division which presented the evidence to the Los Angeles County District Attorney’s Office.

At the time of the alleged assaults, which began in 2008, the women were 19, 24, 25, and 34 years of age. Most, but not all, of the alleged sexual assaults occurred while the officers were on duty.

Beck said Nichols and Valenzuela "preyed on folks that are sometimes reluctant" witnesses or victims that "sometimes are hard to locate." When asked about the length of time it took from the start of the investigation until Wednesday's arrests, Beck said such cases "take a lot of time," according to the Times.

Beck said the officers had not worked city streets since 2013 when they were relieved of duty without pay. The administrative hearings needed to fire them haven't yet been completed, Beck said.

The pair were expected to be arraigned Thursday in Downtown L.A. The Los Angeles County District Attorney’s Office said they would be seeking about $3.8 million bail for both men.

Nichols had been with the LAPD for 15 years and Valenzuela was an 18-year veteran of the department.

Adolfo Flores is a national security correspondent for BuzzFeed News and is based in Los Angeles. He focuses on immigration.