BRENTWOOD (CBSLA)  —  A former Brentwood School teacher pleaded no contest Thursday for having unlawful sex with a student in 2017.

Dr. Aimee Palmitessa, 47, entered her plea to three felony counts of unlawful sexual intercourse. She was immediately sentenced to three years in state prison to be served in local custody.

READ MORE: Davis' 28 Lead Kings To 2nd Straight Win Over Clippers

Deputy D.A. Adrian Roxas of the Sex Crimes Division prosecuted the case.

Palmitessa worked at the prestigious private school for about nine years and the victim was a student in one of her classes. Over the course of the summer in 2017, Palmitessa had sex with the teenage boy, the D.A. said.

READ MORE: Family Of 18-Year-Old Garret Hayward, Killed By Suspected DUI Driver, Hold Emotional Vigil

RELATED: Brentwood Teacher, 45, Accused Of Having Sex On School Campus With Teen

The victim told authorities about the incidents and Palmitessa — a chemistry teacher — was arrested shortly thereafter.

MORE NEWS: In Wake Of Recent Crime Uptick, Beverly Hills Hires More Officers And Increases Patrols

The case was investigated by the LAPD.