Thanks for considering contributing to GPUGT! Your contributions are greatly appreciated, and help make GPUGT a better tool for everyone in the AI and research communities.
- Fork the GPUGT repository on GitHub.
- Clone your fork locally:
git clone [email protected]:uoftcprg/gpugt.git
- Setup virtual environment:
python -m venv venv
- Activate the virtual environment:
source venv/bin/activate
- Install requirements:
pip install -r requirements.txt
- Create a branch for your changes:
git checkout -b branch-name
When making changes, please follow these guidelines:
- Always write your code in compliance with PEP8.
- Write unit tests for your changes, and make sure all tests pass before submitting a pull request.
- Document your changes in the code and update the README file if necessary.
- After making changes, please validate your changes.
- Run style checking:
flake8 gpugt
- Run static type checking with
--strict
flag:mypy --strict gpugt
- Run checks for missing docstrings:
interrogate -f 100 -i -m -n -p -s -r '^\w+TestCase' gpugt
- Run unit tests:
python -m unittest
- Run doctests:
python -m doctest gpugt/*.py
- Commit your changes:
git commit -am 'Add some feature'
- Push to the branch:
git push origin branch-name
- Submit a pull request to the
main
branch in the GPUGT repository.
Before submitting your pull request, please make sure the mypy static type checking with --strict
flag, flake8, doctests, unit tests pass, and your code adheres to PEP8.
After your pull request is merged, you can safely delete your branch and pull the changes from the main repository:
- Delete the remote branch on GitHub:
git push origin --delete branch-name
- Check out the main branch:
git checkout main
- Delete the local branch:
git branch -d branch-name
- Update your main with the latest upstream version:
git pull upstream main