Kumar, Y.; Gordon, Z.; Alabi, O.; Li, J.; Leonard, K.; Ness, L.; Morreale, P. ChatGPT Translation of Program Code for Image Sketch Abstraction. Appl. Sci.2024, 14, 992.
Kumar, Y.; Gordon, Z.; Alabi, O.; Li, J.; Leonard, K.; Ness, L.; Morreale, P. ChatGPT Translation of Program Code for Image Sketch Abstraction. Appl. Sci. 2024, 14, 992.
Kumar, Y.; Gordon, Z.; Alabi, O.; Li, J.; Leonard, K.; Ness, L.; Morreale, P. ChatGPT Translation of Program Code for Image Sketch Abstraction. Appl. Sci.2024, 14, 992.
Kumar, Y.; Gordon, Z.; Alabi, O.; Li, J.; Leonard, K.; Ness, L.; Morreale, P. ChatGPT Translation of Program Code for Image Sketch Abstraction. Appl. Sci. 2024, 14, 992.
Abstract
The migration from MATLAB to Python (M-to-PY) has gained significant traction in recent computational research. While MATLAB has long served as a linchpin in myriad scientific endeavors, there's an emerging trend to rejuvenate these projects using Python's extensive AI tools and libraries. This study presents a semi-automated process for M-to-PY conversion, using a detailed case study of an image skeletonization project comprising fifteen MATLAB files and a 1404-image dataset. Skeletonization is foundational for ongoing 3D motion detection research using AI transformers, predominantly developed in Python. The utilization of ChatGPT-4, acting as an AI co-programmer, is pivotal in this conversion. By leveraging the public OpenAI API, we developed an M-to-PY converter prototype, evaluated its efficacy using test cases from the Bard bot, and subsequently employed the converted code in an AI application. The dual contributions encompass a well-tested M-to-PY converter and a Skeleton App capable of sketching and skeletonizing any given image, enriching the AI toolset. This study accentuates how AI resources, like ChatGPT-4, can simplify code transitions, opening doors for innovative AI implementations using primarily MATLAB-coded scientific research.
Keywords
MATLAB to Python (M-to-PY) converter; skeletonization; skeleton App; ChatGPT; generative AI; LLMs; machine learning; AI pair programming
Subject
Computer Science and Mathematics, Computational Mathematics
Copyright:
This is an open access article distributed under the Creative Commons Attribution License which permits unrestricted use, distribution, and reproduction in any medium, provided the original work is properly cited.