The governor may remit in whole or in part any fine or penalty assessed or imposed by a court of record, court-martial, or other authority, only in the following instances:
(a) When judgment has been rendered against any person for a contempt of court, other than for nonperformance of, or disobedience to, some order, decree or judgment; or when any fine or penalty is imposed by the sentence of a court-martial, the governor may pardon the offense and remit the fine or penalty, either in whole or in part;(b) When any fine has been imposed, if the same or any part thereof, when collected, would be payable to the state, and has not been so paid, the governor may, on good cause shown by affidavit, or on the recommendation of the judge or a majority of the jury who tried the case, remit so much as is payable to the state and has not been so paid, or a less amount, either unconditionally, or upon such terms and conditions as may seem to him right and proper.