For code, please refer to my GitHub page.