Harvey Weinstein will spend 23 years in a New York State prison after being sentenced by Supreme Court judge James Burke on Wednesday morning.

Weinstein was convicted on Feb. 24 of committing a Criminal Sexual Act in the first degree and third-degree rape.

The sentencing ends Weinstein’s New York trial, which began on Jan. 6. His team has said they will appeal the jury’s decision to convict him on two of the five charges he faced.

Judge James Burke, before issuing his sentence, told Weinstein that he will be formally registered as a sex offender.

For his conviction on the first-degree count of criminal sexual act, Weinstein was given 20 years in prison plus five years of supervised release. On the other convicted charge, third-degree rape, he was given three years in prison.

Prior to his sentencing, his attorney Donna Rotunno told the judge that Weinstein should get a shorter sentence because he has a “long list of illnesses.”