PyOPIA
===============================
A Python Ocean Particle Image Analysis toolbox
# Quick tryout of PyOPIA
1) Install [uv](https://docs.astral.sh/uv/getting-started/installation)
2) Initialize PyOPIA project with a small example image dataset and run processing
```bash
uvx --python 3.12 --from pyopia[classification] pyopia --init-project pyopiatest --example-data
cd pyopiatest
uvx --python 3.12 --from pyopia[classification] pyopia process config.toml
```
3) Inspect the processed particle statistics in the processed/ folder
See the documentation for more information on how to install and use PyOPIA.
# Documentation:
[](https://pyopia.readthedocs.io) [](https://pyopia.readthedocs.io/en/latest/?badge=latest)
[pyopia.readthedocs.io](https://pyopia.readthedocs.io)
# Current status:
- Under development. See/regester issues, [here](https://github.com/SINTEF/pyopia/issues)
----
# Development targets for PyOpia:
1) Allow nonfamiliar users to install and use PyOpia, and to contribute & commit code changes
2) Not hardware specific
3) Smaller dependency list than PySilCam -Eventual optional dependencies (e.g. for classification)
4) Can be imported by pysilcam or other hardware-specific tools
5) Work on a single-image basis (...primarily, with options for multiprocess to be considered later)
6) No use of settings/config files within the core code - pass arguments directly. Eventual use of settings/config files should be handled by high-level wrappers that provide arguments to functions.
7) Github workflows
8) Tests
Normal functions within PyOpia should:
1) take inputs
2) return new outputs
3) don't modify state of input
4) minimum possible disc IO during processing
## Contributions
We welcome additions and improvements to the code! We request that you follow a few guidelines. These are in place to make sure the code improves over time.
1. All code changes must be submitted as pull requests, either from a branch or a fork.
2. Good documentation of the code is needed for PyOpia to succeed and so please include up-to-date docstrings as you make changes, so that the auto-build on readthedocs is complete and useful for users. (A version of the new docs will complie when you make a pull request and a link to this can be found in the pull request checks)
3. All pull requests are required to pass all tests before merging. Please do not disable or remove tests just to make your branch pass the pull request.
4. All pull requests must be reviewed by a person. The benefits from code review are plenty, but we like to emphasise that code reviews help spreading the awarenes of code changes. Please note that code reviews should be a pleasant experience, so be plesant, polite and remember that there is a human being with good intentions on the other side of the screen.
5. All contributions are linted with flake8. We recommend that you run flake8 on your code while developing to fix any issues as you go. We recommend using autopep8 to autoformat your Python code (but please check the code behaviour is not affected by autoformatting before pushing). This makes flake8 happy, and makes it easier for us all to maintain a consistent and readable code base.
## Docstrings
Use the NumPy style in docstrings. See style guide [here](https://numpydoc.readthedocs.io/en/latest/format.html#documenting-classes)
# Installing
## For users
Users are expected to be familiar with Python. Please refer to the recommended installation instructions provided on the documentation pages, [here](https://pyopia.readthedocs.io/en/latest/intro.html#installing)
## For developers from source
Install (uv)[https://docs.astral.sh/uv/getting-started/installation/]
1. Navigate to the folder where you want to install pyopia using the 'cd' command.
If you use git:
Download repository from github, and move into the new directory:
```bash
git clone https://github.com/SINTEF/pyopia.git
cd pyopia
```
For the next steps, you need to be located in the PyOPIA root directory that contains the file 'pyproject.toml'.
2. Install all requirements with
```bash
uv sync --all-extras
```
3. (optional) Run local tests:
```bash
uv run pytest
```
#### Version numbering
The version number of PyOPIA is split into three sections: MAJOR.MINOR.PATCH
* MAJOR: Changes in high-level pipeline use and/or data output that are not backwards-compatible.
* MINOR: New features that are backwards-compatible.
* PATCH: Backwards-compatible bug fixes or enhancements to existing functionality
## Build docs locally
```
sphinx-apidoc -f -o docs/source docs/build --separate
sphinx-build -b html ./docs/ ./docs/build
```
----
# License
PyOpia is licensed under the BSD3 license. See LICENSE. All contributors should be recognised & aknowledged.
Raw data
{
"_id": null,
"home_page": null,
"name": "PyOPIA",
"maintainer": null,
"docs_url": null,
"requires_python": "~=3.12",
"maintainer_email": null,
"keywords": "Imaging, Measurement, Ocean, Particles, Size distribution",
"author": null,
"author_email": "Emlyn Davies <emlyn.davies@sintef.no>, \"Alex Nimmo Smith@plymouth.ac.uk\" <alex.nimmo.smith@plymouth.ac.uk>",
"download_url": "https://files.pythonhosted.org/packages/82/f9/d869258cb2435a76cd8bb5ba26415f126f1fa0be3014fb6536d9b69941f0/pyopia-2.11.0.tar.gz",
"platform": null,
"description": "PyOPIA\n===============================\n\nA Python Ocean Particle Image Analysis toolbox\n\n# Quick tryout of PyOPIA\n\n1) Install [uv](https://docs.astral.sh/uv/getting-started/installation)\n2) Initialize PyOPIA project with a small example image dataset and run processing\n```bash\nuvx --python 3.12 --from pyopia[classification] pyopia --init-project pyopiatest --example-data\ncd pyopiatest\nuvx --python 3.12 --from pyopia[classification] pyopia process config.toml\n```\n3) Inspect the processed particle statistics in the processed/ folder\n\nSee the documentation for more information on how to install and use PyOPIA.\n\n# Documentation:\n\n[](https://pyopia.readthedocs.io) [](https://pyopia.readthedocs.io/en/latest/?badge=latest)\n\n[pyopia.readthedocs.io](https://pyopia.readthedocs.io)\n# Current status:\n\n- Under development. See/regester issues, [here](https://github.com/SINTEF/pyopia/issues)\n\n----\n# Development targets for PyOpia:\n\n1) Allow nonfamiliar users to install and use PyOpia, and to contribute & commit code changes\n2) Not hardware specific\n3) Smaller dependency list than PySilCam -Eventual optional dependencies (e.g. for classification)\n4) Can be imported by pysilcam or other hardware-specific tools\n5) Work on a single-image basis (...primarily, with options for multiprocess to be considered later)\n6) No use of settings/config files within the core code - pass arguments directly. Eventual use of settings/config files should be handled by high-level wrappers that provide arguments to functions.\n7) Github workflows\n8) Tests\n\nNormal functions within PyOpia should:\n\n1) take inputs\n2) return new outputs\n3) don't modify state of input\n4) minimum possible disc IO during processing\n\n## Contributions\n\nWe welcome additions and improvements to the code! We request that you follow a few guidelines. These are in place to make sure the code improves over time.\n\n1. All code changes must be submitted as pull requests, either from a branch or a fork.\n2. Good documentation of the code is needed for PyOpia to succeed and so please include up-to-date docstrings as you make changes, so that the auto-build on readthedocs is complete and useful for users. (A version of the new docs will complie when you make a pull request and a link to this can be found in the pull request checks)\n3. All pull requests are required to pass all tests before merging. Please do not disable or remove tests just to make your branch pass the pull request.\n4. All pull requests must be reviewed by a person. The benefits from code review are plenty, but we like to emphasise that code reviews help spreading the awarenes of code changes. Please note that code reviews should be a pleasant experience, so be plesant, polite and remember that there is a human being with good intentions on the other side of the screen.\n5. All contributions are linted with flake8. We recommend that you run flake8 on your code while developing to fix any issues as you go. We recommend using autopep8 to autoformat your Python code (but please check the code behaviour is not affected by autoformatting before pushing). This makes flake8 happy, and makes it easier for us all to maintain a consistent and readable code base.\n\n## Docstrings\n\nUse the NumPy style in docstrings. See style guide [here](https://numpydoc.readthedocs.io/en/latest/format.html#documenting-classes)\n\n# Installing\n\n## For users\n\nUsers are expected to be familiar with Python. Please refer to the recommended installation instructions provided on the documentation pages, [here](https://pyopia.readthedocs.io/en/latest/intro.html#installing)\n\n## For developers from source\n\n\nInstall (uv)[https://docs.astral.sh/uv/getting-started/installation/]\n\n1. Navigate to the folder where you want to install pyopia using the 'cd' command.\n\nIf you use git:\nDownload repository from github, and move into the new directory:\n\n```bash\ngit clone https://github.com/SINTEF/pyopia.git\ncd pyopia\n```\n\nFor the next steps, you need to be located in the PyOPIA root directory that contains the file 'pyproject.toml'.\n\n2. Install all requirements with\n\n```bash\nuv sync --all-extras\n```\n\n3. (optional) Run local tests:\n\n```bash\nuv run pytest\n```\n\n#### Version numbering\n\nThe version number of PyOPIA is split into three sections: MAJOR.MINOR.PATCH\n\n* MAJOR: Changes in high-level pipeline use and/or data output that are not backwards-compatible.\n* MINOR: New features that are backwards-compatible.\n* PATCH: Backwards-compatible bug fixes or enhancements to existing functionality\n\n## Build docs locally\n\n```\nsphinx-apidoc -f -o docs/source docs/build --separate\n\nsphinx-build -b html ./docs/ ./docs/build\n```\n\n----\n# License\n\nPyOpia is licensed under the BSD3 license. See LICENSE. All contributors should be recognised & aknowledged.\n",
"bugtrack_url": null,
"license": null,
"summary": "A Python Ocean Particle Image Analysis toolbox.",
"version": "2.11.0",
"project_urls": {
"Documentation": "https://pyopia.readthedocs.io",
"Repository": "https://github.com/sintef/pyopia"
},
"split_keywords": [
"imaging",
" measurement",
" ocean",
" particles",
" size distribution"
],
"urls": [
{
"comment_text": null,
"digests": {
"blake2b_256": "6a8291e6c2a4c48d3758d6a77c7809951cfa773b4e1a78fda2a3d22a47a984d6",
"md5": "ce33dbd966ba59a2f337987ab0dab3da",
"sha256": "5052ea19fbeeee405378ba0f332ba5930cf9121af06bda078937ce3037f4da0c"
},
"downloads": -1,
"filename": "pyopia-2.11.0-py3-none-any.whl",
"has_sig": false,
"md5_digest": "ce33dbd966ba59a2f337987ab0dab3da",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": "~=3.12",
"size": 73717,
"upload_time": "2025-09-06T12:48:30",
"upload_time_iso_8601": "2025-09-06T12:48:30.421921Z",
"url": "https://files.pythonhosted.org/packages/6a/82/91e6c2a4c48d3758d6a77c7809951cfa773b4e1a78fda2a3d22a47a984d6/pyopia-2.11.0-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": null,
"digests": {
"blake2b_256": "82f9d869258cb2435a76cd8bb5ba26415f126f1fa0be3014fb6536d9b69941f0",
"md5": "b37284f5c3e77aff7137eff3bd50a277",
"sha256": "05385e0eb458b62df799235f9235b2476506a1da35b8730e51a565cf1deef42f"
},
"downloads": -1,
"filename": "pyopia-2.11.0.tar.gz",
"has_sig": false,
"md5_digest": "b37284f5c3e77aff7137eff3bd50a277",
"packagetype": "sdist",
"python_version": "source",
"requires_python": "~=3.12",
"size": 62412,
"upload_time": "2025-09-06T12:48:31",
"upload_time_iso_8601": "2025-09-06T12:48:31.792539Z",
"url": "https://files.pythonhosted.org/packages/82/f9/d869258cb2435a76cd8bb5ba26415f126f1fa0be3014fb6536d9b69941f0/pyopia-2.11.0.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2025-09-06 12:48:31",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "sintef",
"github_project": "pyopia",
"travis_ci": false,
"coveralls": false,
"github_actions": true,
"lcname": "pyopia"
}