
5 Cal.App.3d 55 (1970)
84 Cal. Rptr. 814
In re BYRON LEE BAKER on Habeas Corpus.
Docket No. 17404.
Court of Appeals of California, Second District, Division Four.
March 4, 1970.
*56 COUNSEL
Richard C. Warmer and Charles W. Bender for Petitioner.
Thomas C. Lynch, Attorney General, William E. James, Assistant Attorney General, and Howard J. Schwab, Deputy Attorney General, for Respondent.
OPINION
ALARCON, J. pro tem.[*]
The petitioner, Byron Lee Baker, seeks release from further confinement resulting from his commitment by the Superior Court for Los Angeles County to the Department of Mental Hygiene for an indeterminate period as a mentally disordered sex offender.
The petitioner sets forth a number of alleged procedural and constitutional errors relating to the commitment proceedings. Similar contentions were made by the petitioner in a petition for a writ of habeas corpus filed in the Superior Court for San Luis Obispo, the county in which the petitioner is now confined. On October 22, 1969, Judge Richard Harris of the Superior Court of San Luis Obispo County granted a writ of habeas corpus because of his determination that the procedure leading to the petitioner's commitment was invalid because of "the requirements for strict compliance with statutory procedure in this type of case."
*57 Judge Harris ordered that petitioner be returned to the custody of the Sheriff for Los Angeles County to be held pending determination by the Los Angeles Superior Court as to whether the "petitioner is subject to the `Mentally Disordered Sex Offender' provisions of the Welfare and Institutions Code and/or otherwise dispose of said petitioner as law and facts require."
On December 1, 1969, the Los Angeles Superior Court ordered the petitioner returned to the Superior Court for San Luis Obispo after finding that the petitioner had been "validly committed on the mentally disordered sex offender provisions of the Welfare and Institutions Code."
(1) The petitioner has applied to this court for relief from the action of the Superior Court in San Luis Obispo for its failure to order his complete release and from the determination of the Superior Court of Los Angeles that he was validly committed as a mentally disordered sex offender. We agree with Judge Harris that the commitment proceedings violated the petitioner's statutory rights and that he is entitled to some relief but not to his complete release.
On October 28, 1966, the petitioner was convicted of a violation of Penal Code section 647a, subdivision 1 in Municipal Court for the East Los Angeles Judicial District. On November 28, 1966, that court certified the petitioner to the superior court pursuant to section 5501 (now § 6302) of the Welfare and Institutions Code. The superior court trial judge failed to inform the petitioner of his right to make a reply and present witnesses at the hearing held to determine whether he was a mentally disordered sex offender as required by Welfare and Institutions Code section 5503 (now § 6305). This error makes invalid the order of November 29, 1966, temporarily placing the petitioner in Atascadero State Hospital for observation and diagnosis for 90 days. (People v. Hunter, 270 Cal. App.2d 683, 684-685 [76 Cal. Rptr. 101].)
On January 26, 1967, the Superintendent of the Atascadero State Hospital gave his opinion that the petitioner was a mentally disordered sex offender who could benefit by treatment at a state hospital. Pursuant to the superintendent's report and opinion, the Los Angeles Superior Court ordered the petitioner's commitment for an indeterminate period on February 6, 1967.
On May 31, 1967, the Superintendent of the Atascadero State Hospital reported to the Superior Court for Los Angeles that the petitioner had received the maximum benefit from hospital treatment and should be returned to the municipal court for the resumption of criminal proceedings. *58 On June 11, 1967, the petitioner was returned to the Municipal Court for the East Los Angeles Judicial District. On that date he was recertified to the Superior Court for Los Angeles for further proceedings pursuant to Welfare and Institutions Code sections 5512 and 5518. No hearing was held, nor was petitioner afforded the opportunity to be represented by counsel. Further, the municipal court failed to make a finding prior to recertification, that the petitioner was still a mentally disordered sex offender who would not benefit from care or treatment and was a danger to the health and safety of others.
Welfare and Institutions Code section 5512 (now § 6316) provides, in pertinent part, that when an untreatable mentally disordered sex offender is returned to the court in which the criminal charge was tried, the court "shall resume the proceedings and shall impose sentence or make such other suitable disposition of the case as the court deems necessary." The section also provides that if "such court is satisfied that the person is a mentally disordered sex offender but would not benefit by care or treatment in a state hospital and is a danger to the health and safety of others it may recertify the person to the superior court of the county." (Italics added.)
(2) Under the facts before us the municipal court failed to comply with section 5512 (now § 6316) by denying the petitioner an opportunity to appear with counsel at the time criminal proceedings were resumed, to be heard as to which of the available alternatives the court should choose. This denial of the opportunity to be heard through counsel prior to recertification invalidated all subsequent proceedings and orders. (In re Brown, 275 Cal. App.2d 537, 539-543 [79 Cal. Rptr. 897].)
The order of the Superior Court for Los Angeles County entered on November 29, 1966, temporarily placing the petitioner in Atascadero State Hospital for 90 days is annulled. In addition, the order of the superior court entered on August 4, 1967, recommitting the petitioner to the Department of Mental Hygiene for an indeterminate period is also vacated. The order of the municipal court of June 11, 1967, recertifying the petitioner to the superior court is annulled.
The effect of our decision is to wipe out all proceedings which have occurred since the petitioner's conviction. From a review of the record before us it would appear that the petitioner has not been previously convicted of a sex offense. Pursuant to Welfare and Institutions Code, section 6302, subdivision (a) the trial court may, in its discretion, if there is probable cause for believing that the petitioner is a mentally disordered sex offender, again adjourn criminal proceedings and certify the petitioner for *59 a hearing and examination by the superior court to determine if he is now a mentally disordered sex offender. If the municipal court, in its discretion, determines that it will not again certify the petitioner to the superior court, the petitioner must be released from any further incarceration relating to his conviction of a violation of Penal Code section 647a, subdivision 1. Welfare and Institutions Code section 6325 provides in pertinent part as follows: "... In any case, where the person is sentenced on a criminal charge, the time the person spent under indeterminate commitment as a mentally disordered sex offender shall be credited in fixing his term of sentence." The petitioner has been in custody over three years since his indeterminate commitment was ordered on February 6, 1967. The maximum punishment for a violation of Penal Code section 647a, subdivision 1 is six months in the county jail.
It is ordered that a writ of habeas corpus issue, requiring that the petitioner be remanded to the Municipal Court of the East Los Angeles Judicial District for resumption of criminal proceedings.
Kingsley, Acting P.J., and Dunn, J., concurred.
A petition for a rehearing was denied March 12, 1970, and petitioner's application for a hearing by the Supreme Court was denied April 29, 1970.
NOTES
[*]   Assigned by the Chairman of the Judicial Council.
