-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Adding files from NIU cookiecutter. * Replace CI workflow. Co-authored-by: sfmig <[email protected]> * Move source code files to package directory. * Remove separate linting job. * Gitignore and precommit from NIU template. * Gitignore and precommit from NIU template. * Move the tests to the NIU structure and fix imports. * remove spurious index increase * Remove egg! * Add recursive include of .sh and .md, fix configure linters. * Name the linting job. * Make linters happy. * Fix frame_extraction test data path. * Drop python 3.11 for now. * Remove pypi publishing actions step. * Apply suggestions from code review Co-authored-by: Sam Cunliffe <[email protected]> Signed-off-by: sfmig <[email protected]> * Name all jobs using imperatives. Use consistent order for job attributes. * remove user-specific gitignore bits * remove some commented bits * rename to dense_optical_flow * rename to opencv_notebooks * rename to pose_estimation * rename to stereo_calibration * delete files with old names * Update pyproject.toml Co-authored-by: sfmig <[email protected]> Signed-off-by: Sam Cunliffe <[email protected]> --------- Signed-off-by: sfmig <[email protected]> Signed-off-by: Sam Cunliffe <[email protected]> Co-authored-by: sfmig <[email protected]> Co-authored-by: sfmig <[email protected]>
- Loading branch information
1 parent
99e1fd1
commit 3665608
Showing
40 changed files
with
372 additions
and
251 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
name: tests | ||
|
||
on: | ||
push: | ||
branches: | ||
- "*" | ||
tags: | ||
- "*" | ||
pull_request: | ||
|
||
jobs: | ||
linting: | ||
name: Run pre-commit linters | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: neuroinformatics-unit/actions/lint@v2 | ||
|
||
manifest: | ||
name: Check Manifest | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: neuroinformatics-unit/actions/check_manifest@v2 | ||
|
||
test: | ||
name: Run tests on ${{ matrix.os }} py${{ matrix.python-version }} | ||
needs: [linting, manifest] | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
matrix: | ||
# Run all supported Python versions on linux | ||
os: [ubuntu-latest] | ||
python-version: ["3.9", "3.10"] | ||
# Include one macos run | ||
include: | ||
- os: macos-latest | ||
python-version: "3.10" | ||
steps: | ||
- uses: neuroinformatics-unit/actions/test@v2 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
|
||
build_sdist_wheels: | ||
name: Build source distribution | ||
needs: [test] | ||
runs-on: ubuntu-latest | ||
if: github.event_name == 'push' && github.ref_type == 'tag' | ||
steps: | ||
- uses: neuroinformatics-unit/actions/build_sdist_wheels@v2 |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,94 @@ | ||
# Byte-compiled / optimized / DLL files | ||
__pycache__/ | ||
*.py[cod] | ||
*$py.class | ||
|
||
# C extensions | ||
*.so | ||
|
||
# Distribution / packaging | ||
.Python | ||
env/ | ||
build/ | ||
develop-eggs/ | ||
dist/ | ||
downloads/ | ||
eggs/ | ||
.eggs/ | ||
lib/ | ||
lib64/ | ||
parts/ | ||
sdist/ | ||
var/ | ||
*.egg-info/ | ||
.installed.cfg | ||
*.egg | ||
|
||
# PyInstaller | ||
# Usually these files are written by a python script from a template | ||
# before PyInstaller builds the exe, so as to inject date/other infos into it. | ||
*.manifest | ||
*.spec | ||
|
||
# Installer logs | ||
pip-log.txt | ||
pip-delete-this-directory.txt | ||
|
||
# Unit test / coverage reports | ||
htmlcov/ | ||
.tox/ | ||
.coverage | ||
.coverage.* | ||
.cache | ||
nosetests.xml | ||
coverage.xml | ||
*,cover | ||
.hypothesis/ | ||
|
||
# Translations | ||
*.mo | ||
*.pot | ||
|
||
# Django stuff: | ||
*.log | ||
local_settings.py | ||
|
||
# Flask instance folder | ||
instance/ | ||
|
||
# Sphinx documentation | ||
docs/_build/ | ||
|
||
# MkDocs documentation | ||
/site/ | ||
|
||
# PyBuilder | ||
target/ | ||
|
||
# Pycharm and VSCode | ||
.idea/ | ||
venv/ | ||
.vscode/ | ||
|
||
# IPython Notebook | ||
.ipynb_checkpoints | ||
|
||
# pyenv | ||
.python-version | ||
|
||
# OS | ||
.DS_Store | ||
**/__pycache__/** | ||
|
||
# Video and image files | ||
*.MOV | ||
*.slp | ||
*.layout | ||
*.json | ||
*.png | ||
*.mp4 | ||
|
||
/data/ | ||
/bboxes_labelling/annotations | ||
/stereo calibration/check_chessboard_cells_size/* | ||
/pose estimation/animal_size_4k/* | ||
/pose estimation/top_down_model_4k_230713/* | ||
# Metadata and pose-estimation files | ||
*.slp | ||
*.json | ||
|
||
# include mp4 files in tests/data dir | ||
# Test data to includ | ||
# TODO: move this to GIN? (or at least the larger files) | ||
!/tests/data/**/*.mp4 | ||
!/tests/data/**/*.json |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,38 +1,36 @@ | ||
repos: | ||
- repo: https://github.com/charliermarsh/ruff-pre-commit | ||
rev: v0.0.280 | ||
hooks: | ||
- id: ruff | ||
args: ["--config", "pyproject.toml"] | ||
- repo: https://github.com/Lucas-C/pre-commit-hooks | ||
rev: v1.5.1 | ||
hooks: | ||
- id: forbid-tabs | ||
- repo: https://github.com/pappasam/toml-sort | ||
rev: v0.23.1 | ||
hooks: | ||
- id: toml-sort-fix | ||
exclude: "crabs-exploration/pyproject.toml" | ||
- repo: https://github.com/pre-commit/mirrors-mypy | ||
rev: v1.4.1 | ||
hooks: | ||
- id: mypy | ||
- repo: https://github.com/pre-commit/mirrors-prettier | ||
rev: v3.0.0-alpha.9-for-vscode | ||
hooks: | ||
- id: prettier | ||
exclude: "crabs-exploration/.github/workflows/tests.yml" | ||
- repo: https://github.com/pre-commit/pre-commit-hooks | ||
rev: v4.4.0 | ||
hooks: | ||
- id: check-case-conflict | ||
- id: check-docstring-first | ||
# - id: check-executables-have-shebangs TODO: fix later | ||
- id: check-merge-conflict | ||
- id: check-toml | ||
- id: end-of-file-fixer | ||
- id: mixed-line-ending | ||
args: [--fix=lf] | ||
- id: trailing-whitespace | ||
- repo: https://github.com/charliermarsh/ruff-pre-commit | ||
rev: v0.0.280 | ||
hooks: | ||
- id: ruff | ||
- repo: https://github.com/psf/black | ||
rev: 23.7.0 | ||
hooks: | ||
- id: black | ||
- repo: https://github.com/pre-commit/mirrors-mypy | ||
rev: v1.3.0 | ||
hooks: | ||
- id: mypy | ||
additional_dependencies: | ||
- types-setuptools | ||
- repo: https://github.com/mgedmin/check-manifest | ||
rev: "0.49" | ||
hooks: | ||
- id: check-manifest | ||
args: [--no-build-isolation] | ||
additional_dependencies: [setuptools-scm] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
include LICENSE | ||
include README.md | ||
|
||
recursive-include crabs *.md | ||
recursive-include crabs *.sh | ||
|
||
exclude .pre-commit-config.yaml | ||
|
||
recursive-exclude * __pycache__ | ||
recursive-exclude * *.py[co] | ||
recursive-exclude docs * | ||
recursive-exclude tests * |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
# crabs-exploration | ||
|
||
exploring the crabs field data | ||
A toolkit for detecting and tracking crabs in the field. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
from importlib.metadata import PackageNotFoundError, version | ||
|
||
try: | ||
__version__ = version("crabs") | ||
except PackageNotFoundError: | ||
# package is not installed | ||
pass |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.