<h1 align="center">
<img src="gesund/assets/gesund_logo.png" width="300" alt="Gesund Logo">
</h1><br>
# Validation Metrics Library
[![Test Workflow](https://github.com/gesund-ai/gesund/actions/workflows/test.yml/badge.svg)](https://github.com/gesund-ai/gesund/actions/workflows/test.yml)
[![PyPi](https://img.shields.io/pypi/v/gesund)](https://pypi.org/project/gesund)
[![PyPI Downloads](https://img.shields.io/pypi/dm/gesund.svg?label=PyPI%20downloads)](
https://pypi.org/project/gesund/)
This library provides tools for calculating validation metrics for predictions and annotations in machine learning workflows. It includes a command-line tool for computing and displaying validation metrics.
- **Documentation:** https://gesund-ai.github.io
- **Source code:** https://github.com/gesund-ai/gesund
- **Bug reports:** https://github.com/gesund-ai/gesund/issues
- **Examples :** https://github.com/gesund-ai/gesund/tree/main/gesund/examples
## Installation
To use this library, ensure you have the necessary dependencies installed in your environment. You can install them via `pip`:
```sh
pip install gesund==latest_version
pip install pycocotools@git+https://github.com/HammadK44/cocoapi.git@Dev#subdirectory=PythonAPI/
```
## Basic Usage
```python
# import the library
from gesund import Validation
from gesund.validation._result import ValidationResult
from gesund.core._managers.metric_manager import metric_manager
from gesund.core._managers.plot_manager import plot_manager
# Call the default configuration from utils
from utils import callable_plot_config
# Select your problem type {"classification", "object_detection", "semantic_segmentation"}
# example usage for problem type
problem_type = "classification"
plot_configuration = callable_plot_config(problem_type)
metric_name = "lift_chart"
cohort_id = None
data_dir = f"./tests/_data/{problem_type}"
# create a class instance
validator = Validation(
annotations_path=f"{data_dir}/gesund_custom_format/annotation.json",
predictions_path=f"{data_dir}/gesund_custom_format/prediction.json",
class_mapping=f"{data_dir}/test_class_mappings.json",
problem_type=problem_type,
data_format="json",
json_structure_type="gesund",
plot_config=plot_configuration,
cohort_args={"selection_criteria": "random"},
metric_args={"threshold": [0.25, 0.5, 0.75]},
)
# run the validation workflow
validation_results = validator.run()
# save the results
validation_results.save(metric_name)
# plot the results
validation_results.plot(metric_name="auc", save_plot=False, cohort_id=cohort_id)
```
## Code of Conduct
We are committed to fostering a welcoming and inclusive community. Please adhere to the following guidelines when contributing to this project:
- **Respect**: Treat everyone with respect and consideration. Harassment or discrimination of any kind is not tolerated.
- **Collaboration**: Be open to collaboration and constructive criticism. Offer feedback gracefully and accept feedback in the same manner.
- **Inclusivity**: Use inclusive language and be mindful of different perspectives and experiences.
- **Professionalism**: Maintain a professional attitude in all project interactions.
By participating in this project, you agree to abide by this Code of Conduct. If you witness or experience any behavior that violates these guidelines, please contact the project maintainers.
## License
This project is licensed under the MIT License. See the [LICENSE](LICENSE) file for details.
Raw data
{
"_id": null,
"home_page": null,
"name": "gesund",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.6",
"maintainer_email": "Hammad Khalid <hammad@gesund.ai>, Akson Varghese <akson@gesund.ai>, Ozkan Uysal <ozkan@gesund.ai>",
"keywords": "gesund, medical, radiology, machine learning, ai, artificial intelligence",
"author": null,
"author_email": "Veysel Koccaman <veysel@gesund.ai>, Hammad Khalid <hammad@gesund.ai>, Akson Varghese <akson@gesund.ai>, Ozkan Uysal <ozkan@gesund.ai>",
"download_url": "https://files.pythonhosted.org/packages/b1/01/cd7dfacece4f75c50541d9cc83ab3f7316ee31b13c14a6bb9e2c0e585f3a/gesund-0.2.0.tar.gz",
"platform": null,
"description": "<h1 align=\"center\">\n <img src=\"gesund/assets/gesund_logo.png\" width=\"300\" alt=\"Gesund Logo\">\n</h1><br>\n\n# Validation Metrics Library\n\n[![Test Workflow](https://github.com/gesund-ai/gesund/actions/workflows/test.yml/badge.svg)](https://github.com/gesund-ai/gesund/actions/workflows/test.yml)\n[![PyPi](https://img.shields.io/pypi/v/gesund)](https://pypi.org/project/gesund)\n[![PyPI Downloads](https://img.shields.io/pypi/dm/gesund.svg?label=PyPI%20downloads)](\nhttps://pypi.org/project/gesund/)\n\n\nThis library provides tools for calculating validation metrics for predictions and annotations in machine learning workflows. It includes a command-line tool for computing and displaying validation metrics.\n\n- **Documentation:** https://gesund-ai.github.io\n- **Source code:** https://github.com/gesund-ai/gesund\n- **Bug reports:** https://github.com/gesund-ai/gesund/issues\n- **Examples :** https://github.com/gesund-ai/gesund/tree/main/gesund/examples\n\n\n## Installation\n\nTo use this library, ensure you have the necessary dependencies installed in your environment. You can install them via `pip`:\n\n```sh\npip install gesund==latest_version\npip install pycocotools@git+https://github.com/HammadK44/cocoapi.git@Dev#subdirectory=PythonAPI/\n```\n\n## Basic Usage\n\n```python\n# import the library\n\nfrom gesund import Validation\nfrom gesund.validation._result import ValidationResult\nfrom gesund.core._managers.metric_manager import metric_manager\nfrom gesund.core._managers.plot_manager import plot_manager\n\n# Call the default configuration from utils\nfrom utils import callable_plot_config\n\n# Select your problem type {\"classification\", \"object_detection\", \"semantic_segmentation\"}\n\n# example usage for problem type\nproblem_type = \"classification\"\nplot_configuration = callable_plot_config(problem_type)\nmetric_name = \"lift_chart\"\ncohort_id = None\ndata_dir = f\"./tests/_data/{problem_type}\"\n\n# create a class instance\nvalidator = Validation(\n annotations_path=f\"{data_dir}/gesund_custom_format/annotation.json\",\n predictions_path=f\"{data_dir}/gesund_custom_format/prediction.json\",\n class_mapping=f\"{data_dir}/test_class_mappings.json\",\n problem_type=problem_type,\n data_format=\"json\",\n json_structure_type=\"gesund\",\n plot_config=plot_configuration,\n cohort_args={\"selection_criteria\": \"random\"},\n metric_args={\"threshold\": [0.25, 0.5, 0.75]},\n)\n\n# run the validation workflow\nvalidation_results = validator.run()\n# save the results \nvalidation_results.save(metric_name)\n# plot the results\nvalidation_results.plot(metric_name=\"auc\", save_plot=False, cohort_id=cohort_id)\n\n```\n\n\n## Code of Conduct\n\n\nWe are committed to fostering a welcoming and inclusive community. Please adhere to the following guidelines when contributing to this project:\n\n- **Respect**: Treat everyone with respect and consideration. Harassment or discrimination of any kind is not tolerated.\n- **Collaboration**: Be open to collaboration and constructive criticism. Offer feedback gracefully and accept feedback in the same manner.\n- **Inclusivity**: Use inclusive language and be mindful of different perspectives and experiences.\n- **Professionalism**: Maintain a professional attitude in all project interactions.\n\nBy participating in this project, you agree to abide by this Code of Conduct. If you witness or experience any behavior that violates these guidelines, please contact the project maintainers.\n\n## License\n\nThis project is licensed under the MIT License. See the [LICENSE](LICENSE) file for details.\n\n",
"bugtrack_url": null,
"license": null,
"summary": "A CRO platform for clinical-grade AI Train. Validate. Secure clearance. Gesund.ai orchestrates the AI as-a-Medical Device lifecycle, providing privacy-centered access to diverse yet standardized medical data sources, and a unique analytical toolbox that fosters clinical validation, regulatory clearance and effective marketing",
"version": "0.2.0",
"project_urls": {
"Documentation": "https://gesund-ai.github.io/",
"Homepage": "https://github.com/gesund-ai/gesund",
"Issues": "https://github.com/gesund-ai/gesund/issues"
},
"split_keywords": [
"gesund",
" medical",
" radiology",
" machine learning",
" ai",
" artificial intelligence"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "5b037c9dacdc3cd532a9682038791fa6fafbc5548ad4b0c85482397dc1f45e90",
"md5": "f0146d4f8fa1b1d017b18271bcf03bf2",
"sha256": "0ed46622bf9085d4a127dd516f7f2696e869900defb74df2a1c21bf06429d86a"
},
"downloads": -1,
"filename": "gesund-0.2.0-py3-none-any.whl",
"has_sig": false,
"md5_digest": "f0146d4f8fa1b1d017b18271bcf03bf2",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.6",
"size": 60714,
"upload_time": "2024-12-28T18:23:52",
"upload_time_iso_8601": "2024-12-28T18:23:52.075045Z",
"url": "https://files.pythonhosted.org/packages/5b/03/7c9dacdc3cd532a9682038791fa6fafbc5548ad4b0c85482397dc1f45e90/gesund-0.2.0-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "b101cd7dfacece4f75c50541d9cc83ab3f7316ee31b13c14a6bb9e2c0e585f3a",
"md5": "883a2935bfabc98f35392788b6ef5125",
"sha256": "573d0697c9f2de8024a3fa63c176eff4765a5f3640c660c04d9cc52cf4a5d296"
},
"downloads": -1,
"filename": "gesund-0.2.0.tar.gz",
"has_sig": false,
"md5_digest": "883a2935bfabc98f35392788b6ef5125",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.6",
"size": 39418,
"upload_time": "2024-12-28T18:23:54",
"upload_time_iso_8601": "2024-12-28T18:23:54.246674Z",
"url": "https://files.pythonhosted.org/packages/b1/01/cd7dfacece4f75c50541d9cc83ab3f7316ee31b13c14a6bb9e2c0e585f3a/gesund-0.2.0.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-12-28 18:23:54",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "gesund-ai",
"github_project": "gesund",
"travis_ci": false,
"coveralls": false,
"github_actions": true,
"requirements": [
{
"name": "bson",
"specs": [
[
"==",
"0.5.10"
]
]
},
{
"name": "jsonschema",
"specs": [
[
"==",
"4.23.0"
]
]
},
{
"name": "scikit-learn",
"specs": [
[
"==",
"1.3.2"
]
]
},
{
"name": "pandas",
"specs": [
[
"==",
"2.0.3"
]
]
},
{
"name": "seaborn",
"specs": [
[
"==",
"0.13.2"
]
]
},
{
"name": "opencv-python",
"specs": [
[
"==",
"4.10.0.84"
]
]
},
{
"name": "dictances",
"specs": [
[
"==",
"1.5.3"
]
]
},
{
"name": "miseval",
"specs": [
[
"==",
"1.2.2"
]
]
},
{
"name": "numpy",
"specs": [
[
"==",
"1.21.6"
]
]
},
{
"name": "numba",
"specs": [
[
"==",
"0.55.2"
]
]
},
{
"name": "tqdm",
"specs": [
[
"==",
"4.66.5"
]
]
},
{
"name": "pycocotools",
"specs": []
},
{
"name": "seaborn",
"specs": [
[
"==",
"0.13.2"
]
]
},
{
"name": "pytest",
"specs": [
[
"==",
"8.3.3"
]
]
},
{
"name": "pydantic",
"specs": [
[
"==",
"2.9.2"
]
]
}
],
"lcname": "gesund"
}