The Evaluator app, developed by the AIM (Artificial Intelligence for Musicians) group at Purdue University, uses computer vision to assist string instrument players in improving their posture and hand movements. Refer to "Evaluator_Vision_team_Installation_and_Code_Setup_Documentation.pdf" for more details.
- Install Git from Git's official website.
- Verify installation with:
git --version
- Ensure Python 3.9, 3.10, or 3.11 is installed. Download it from the official Python website.
- Verify installation with:
python --version
- Clone the repository:
git clone https://github.com/Purdue-Artificial-Intelligence-in-Music/Evaluator-code.git
- Navigate to the project directory:
cd Evaluator-code/src/computer_vision/hand_pose_detection
python -m venv env
- Windows:
.\env\Scripts\activate
- macOS/Linux:
source env/bin/activate
- Ensure
pip
is updated:pip install --upgrade pip
- Install the necessary dependencies:
pip install opencv-python mediapipe numpy supervision ultralytics ipython
- Activate the virtual environment (if not already activated).
- Run the script:
python test.py
The following paths in your script should be updated for portability and to avoid hardcoding absolute paths:
gesture_model = '/Users/Wpj11/Documents/GitHub/Evaluator-code/src/computer_vision/hand_pose_detection/3_category.task'
model = YOLO('/Users/Wpj11/Documents/GitHub/Evaluator-code/src/computer_vision/hand_pose_detection/bow_target.pt')
video_file_path = '/Users/Wpj11/Documents/GitHub/Evaluator-code/src/computer_vision/hand_pose_detection/Vertigo for Solo Cello - Cicely Parnas.mp4'
gesture_model = '3_category.task'
model = YOLO('bow_target.pt')
video_file_path = 'Vertigo for Solo Cello - Cicely Parnas.mp4'
Ensure that these files are placed in the same directory as your script or adjust the relative paths accordingly.
ModuleNotFoundError: No module named 'cv2'
:pip install opencv-python
ModuleNotFoundError: No module named 'mediapipe'
:pip install mediapipe
ModuleNotFoundError: No module named 'supervision'
:pip install supervision
ModuleNotFoundError: No module named 'ultralytics'
:pip install ultralytics
ModuleNotFoundError: No module named 'IPython'
:pip install ipython
- Model File (
best.pt
) Not Found: Ensure the path tobest.pt
is correct. Use relative paths to the project root or ensure the file exists in the specified location. - Video File Not Found: Verify the file exists at the specified path. Update the script to use the correct relative or absolute path.
- Always activate your virtual environment before running the script.
- Ensure all dependencies are installed and up to date.
- Double-check file paths for models and input files to avoid runtime errors.
For further assistance, consult the project documentation or reach out to the project team leads.