(a) At any time after commitment and not more often than once every six months, the patient or any friend or relative having reason to believe that the patient no longer has active tuberculosis or that the patient's discharge will not endanger the public health may institute proceedings by petition in the superior court of the county wherein the confinement exists, whereupon the judge shall set the matter for a hearing to occur within 15 days requiring the person or persons to whose care the patient was committed, or their duly authorized agents, to show cause on a day certain why the patient should not be discharged. The judge shall also require that the patient be allowed the right to be examined prior to the hearing by a licensed physician of the patient's own choice and at the patient's own personal expense. Thereafter all proceedings shall be conducted in the same manner as are proceedings for commitment.
(b) In addition to the above procedure for securing discharge, the patient or a friend or relative on behalf of such person may petition, as provided by law, for a writ of habeas corpus to question the cause and legality of detention and to request a court of competent jurisdiction to issue a writ for release, provided that a copy of the petition along with the proper certificate of service shall also be served upon the presiding judge of the court ordering such detention and upon the county board of health or the Department of Public Health which initiated the petition for commitment pursuant to Code Section 31-14-2, which service shall be made by certified mail or statutory overnight delivery.