Skip to content

Commit

Permalink
Merge branch 'release/v0.1.4'
Browse files Browse the repository at this point in the history
  • Loading branch information
KelSolaar committed Dec 4, 2022
2 parents 9dcbdfd + 07b9a7b commit 16ee05e
Show file tree
Hide file tree
Showing 17 changed files with 315 additions and 279 deletions.
9 changes: 4 additions & 5 deletions .github/workflows/continuous-integration-documentation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,16 +7,16 @@ jobs:
name: ${{ matrix.os }} - Python ${{ matrix.python-version }}
strategy:
matrix:
os: [ubuntu-20.04]
python-version: [3.8]
os: [ubuntu-22.04]
python-version: [3.11]
fail-fast: false
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v1
- name: Environment Variables
run: |
echo "CI_PYTHON_VERSION=${{ matrix.python-version }}" >> $GITHUB_ENV
echo "CI_PACKAGE=colour" >> $GITHUB_ENV
echo "CI_PACKAGE=colour_checker_detection" >> $GITHUB_ENV
echo "CI_SHA=${{ github.sha }}" >> $GITHUB_ENV
echo "MPLBACKEND=AGG" >> $GITHUB_ENV
echo "COLOUR_SCIENCE__DOCUMENTATION_BUILD=True" >> $GITHUB_ENV
Expand All @@ -31,8 +31,7 @@ jobs:
sudo apt-get --yes install latexmk texlive-full
- name: Install Poetry
run: |
curl -L https://raw.githubusercontent.com/sdispater/poetry/master/get-poetry.py -o get-poetry.py
python get-poetry.py
curl -sSL https://install.python-poetry.org | POETRY_HOME=$HOME/.poetry python3 -
echo "$HOME/.poetry/bin" >> $GITHUB_PATH
shell: bash
- name: Install Package Dependencies
Expand Down
15 changes: 9 additions & 6 deletions .github/workflows/continuous-integration-quality-unit-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,12 @@ name: Continuous Integration - Quality & Unit Tests
on: [push, pull_request]

jobs:
continuous-integration-package:
continuous-integration-quality-unit-tests:
name: ${{ matrix.os }} - Python ${{ matrix.python-version }}
strategy:
matrix:
os: [macOS-latest, ubuntu-20.04, windows-2019]
python-version: [3.8, 3.9, '3.10']
os: [macOS-latest, ubuntu-22.04, windows-2019]
python-version: [3.9, '3.10', 3.11]
fail-fast: false
runs-on: ${{ matrix.os }}
steps:
Expand All @@ -22,14 +22,17 @@ jobs:
echo "CI_SHA=${{ github.sha }}" >> $GITHUB_ENV
echo "COVERALLS_REPO_TOKEN=${{ secrets.COVERALLS_REPO_TOKEN }}" >> $GITHUB_ENV
shell: bash
- name: Set up Python 3.9 for Pre-Commit
uses: actions/setup-python@v1
with:
python-version: 3.9
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v1
with:
python-version: ${{ matrix.python-version }}
- name: Install Poetry
run: |
curl -L https://raw.githubusercontent.com/sdispater/poetry/master/get-poetry.py -o get-poetry.py
python get-poetry.py --version 1.1.12
curl -sSL https://install.python-poetry.org | POETRY_HOME=$HOME/.poetry python3 -
echo "$HOME/.poetry/bin" >> $GITHUB_PATH
shell: bash
- name: Install Package Dependencies
Expand All @@ -48,7 +51,7 @@ jobs:
shell: bash
- name: Test with Pytest
run: |
poetry run python -W ignore -m py.test --disable-warnings --doctest-modules --ignore=$CI_PACKAGE/examples --cov=$CI_PACKAGE $CI_PACKAGE
poetry run python -W ignore -m pytest --disable-warnings --doctest-modules --ignore=$CI_PACKAGE/examples --cov=$CI_PACKAGE $CI_PACKAGE
shell: bash
- name: Upload Coverage to coveralls.io
run: |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,30 +3,27 @@ name: Continuous Integration - Static Type Checking
on: [push, pull_request]

jobs:
continuous-integration-package:
continuous-integration-static-type-checking:
name: ${{ matrix.os }} - Python ${{ matrix.python-version }}
strategy:
matrix:
os: [macOS-latest]
python-version: [3.9]
python-version: [3.11]
fail-fast: false
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v1
- name: Environment Variables
run: |
echo "CI_PACKAGE=colour" >> $GITHUB_ENV
echo "CI_PACKAGE=colour_checker_detection" >> $GITHUB_ENV
shell: bash
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v1
with:
python-version: ${{ matrix.python-version }}
- name: Install Dependencies (macOS)
- name: Install Package Dependencies
run: |
brew install gnu-sed graphviz
ln -s /usr/local/bin/gsed /usr/local/bin/sed
shell: bash
pip install -r requirements.txt
- name: Static Type Checking
run: |
pip install -r requirements.txt
mypy --install-types --non-interactive --show-error-codes --warn-unused-ignores --warn-redundant-casts -p $CI_PACKAGE
mypy --install-types --non-interactive --show-error-codes --warn-unused-ignores --warn-redundant-casts $CI_PACKAGE
10 changes: 9 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,11 +1,19 @@
*.egg-info
*.pyc
*.pyo
.DS_Store
.coverage
.dmypy.json
.fleet
.idea
.ipynb_checkpoints/
.ipynb_checkpoints
.mypy_cache
.sandbox
.vs
.vscode

__pycache__

build
colour_checker_detection.egg-info
dist
Expand Down
19 changes: 12 additions & 7 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,20 +1,25 @@
repos:
- repo: https://github.com/asottile/pyupgrade
rev: v2.31.0
rev: v3.2.2
hooks:
- id: pyupgrade
args: [--py38-plus]
args: [--py39-plus]
- repo: https://github.com/ikamensh/flynt/
rev: '0.76'
rev: '0.77'
hooks:
- id: flynt
- repo: https://github.com/psf/black
rev: 22.1.0
rev: 22.10.0
hooks:
- id: black
language_version: python3.8
language_version: python3.9
- repo: https://github.com/keewis/blackdoc
rev: v0.3.8
hooks:
- id: blackdoc
language_version: python3.9
- repo: https://github.com/PyCQA/flake8
rev: 4.0.1
rev: 6.0.0
hooks:
- id: flake8
- repo: https://github.com/pycqa/pydocstyle
Expand All @@ -23,4 +28,4 @@ repos:
- id: pydocstyle
args:
- --convention=numpy
- --add-ignore=D104,D200,D202,D205,D301,D400
- --add-ignore=D104,D200,D202,D205,D301,D400
2 changes: 1 addition & 1 deletion .readthedocs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ version: 2
build:
os: ubuntu-20.04
tools:
python: "3.8"
python: "3.11"

sphinx:
configuration: docs/conf.py
Expand Down
2 changes: 1 addition & 1 deletion CONTRIBUTORS.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Contributors
Development & Technical Support
-------------------------------

- **Thomas Mansencal**, *Lead Pipeline Developer @ WetaFX*
- **Thomas Mansencal**, *Technology Supervisor @ Wētā FX*

Project coordination, overall development.

Expand Down
2 changes: 1 addition & 1 deletion README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Colour - Checker Detection
|actions| |coveralls| |codacy| |version|

.. |actions| image:: https://img.shields.io/github/workflow/status/colour-science/colour-checker-detection/Continuous%20Integration?label=actions&logo=github&style=flat-square
.. |actions| image:: https://img.shields.io/github/workflow/status/colour-science/colour-checker-detection/Continuous%20Integration%20-%20Quality%20&%20Unit%20Tests?label=actions&logo=github&style=flat-square
:target: https://github.com/colour-science/colour-checker-detection/actions
:alt: Develop Build Status
.. |coveralls| image:: http://img.shields.io/coveralls/colour-science/colour-checker-detection/develop.svg?style=flat-square
Expand Down
12 changes: 6 additions & 6 deletions colour_checker_detection/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,19 +41,19 @@
"detect_colour_checkers_segmentation",
]

RESOURCES_DIRECTORY: str = os.path.join(os.path.dirname(__file__), "resources")
EXAMPLES_RESOURCES_DIRECTORY: str = os.path.join(
RESOURCES_DIRECTORY, "colour-checker-detection-examples-datasets"
ROOT_RESOURCES: str = os.path.join(os.path.dirname(__file__), "resources")
ROOT_RESOURCES_EXAMPLES: str = os.path.join(
ROOT_RESOURCES, "colour-checker-detection-examples-datasets"
)
TESTS_RESOURCES_DIRECTORY: str = os.path.join(
RESOURCES_DIRECTORY, "colour-checker-detection-tests-datasets"
ROOT_RESOURCES_TESTS: str = os.path.join(
ROOT_RESOURCES, "colour-checker-detection-tests-datasets"
)

__application_name__ = "Colour - Checker Detection"

__major_version__ = "0"
__minor_version__ = "1"
__change_version__ = "3"
__change_version__ = "4"
__version__ = ".".join(
(__major_version__, __minor_version__, __change_version__)
)
Expand Down
Loading

0 comments on commit 16ee05e

Please sign in to comment.