Cal. Welf. & Inst. Code § 7362
(a) The medical superintendent of a state hospital, on filing his or her written certificate with the Director of State Hospitals, may on his or her own motion, and shall on the order of the State Department of State Hospitals, discharge a patient who comes within any of the following descriptions: