There shall be allowed and paid by the state for transporting any person from a community correctional center to any state hospital, or returning any person from such a hospital to a community correctional center, twenty-five cents per mile, to be computed from the community correctional center to the hospital and return, and for any necessary assistants in such cases, five dollars, the necessity of such assistance to be proved by the oath of the officer.