# ImageAnalyst
ImageAnalyst is a library that simplifies image analysis. The library achieves this goal by standardizing the input and output
vectors of a few machine learning models and by providing some high-level analysis algorithms.
## Requirements
The application requires:
- [Python](https://www.python.org/) ~= 3.9
- [pip](https://pip.pypa.io/en/stable/)
<!--
## Extras
The application has some extras that can be installed:
- [cv2](https://github.com/BergLucas/ImageAnalystCV2)
- [hf](https://github.com/BergLucas/ImageAnalystHF)
- [tf](https://github.com/BergLucas/ImageAnalystTF)
- [onnx](https://github.com/BergLucas/ImageAnalystONNX)
!-->
## Download & Installation
There is two ways to download and install the application.
### Using PyPI
You can download and install the application using [PyPI](https://pypi.org/project/image-analyst/). To do so, run the following command:
```bash
pip install image-analyst
```
### Using the GitHub releases
You can download the application on the [downloads page](https://github.com/BergLucas/ImageAnalyst/releases). Then, you can install the application by running the following command:
```bash
pip install image_analyst-X.X.X-py3-none-any.whl
```
(Note: The X.X.X must be replaced by the version that you want to install.)
<!--
## Example
This example allows you to track objects from your webcam. It requires the `cv2` extra.
```python
from image_analyst.cv2.utils import convert_image, create_frame_generator
from image_analyst.cv2.models import YoloV3OpenCV
from image_analyst.trackers import IOUTracker
import cv2
def report_callback(filename: str, current_size: float, total_size: float):
print("{} {:.2f}%".format(filename, current_size/total_size*100), end="\r", flush=True)
model = YoloV3OpenCV.coco(report_callback=report_callback)
tracking_function = IOUTracker(model)
with create_frame_generator(0) as frame_generator:
for frame in frame_generator:
converted_frame = convert_image(frame, model.supported_format, model.supported_dtype)
instances = tracking_function(converted_frame)
for instance in instances:
xmin, ymin, xmax, ymax = instance.bounding_box.as_tuple()
text = "{} {} {:.2f}".format(instance.id, instance.class_name, instance.score)
cv2.rectangle(frame, (xmin, ymin), (xmax, ymax), (0, 255, 0), 2)
cv2.putText(frame, text, (xmin, ymin), cv2.FONT_HERSHEY_SIMPLEX, 1, (0, 255, 0), 2)
cv2.imshow("Tracking", frame)
if cv2.waitKey(1) & 0xFF == ord('q'):
break
cv2.destroyAllWindows()
```
!-->
## License
All code is licensed for others under a MIT license (see [LICENSE](https://github.com/BergLucas/ImageAnalyst/blob/main/LICENSE)).
Raw data
{
"_id": null,
"home_page": "https://github.com/BergLucas/ImageAnalyst",
"name": "image-analyst",
"maintainer": "",
"docs_url": null,
"requires_python": ">=3.9,<4.0",
"maintainer_email": "",
"keywords": "image,analysis",
"author": "Lucas Berg",
"author_email": "55436804+BergLucas@users.noreply.github.com",
"download_url": "https://files.pythonhosted.org/packages/0a/0d/98287195840afb114854e3f7266a0e5df6d5307e063769e1bdad516862f1/image_analyst-0.2.0.tar.gz",
"platform": null,
"description": "# ImageAnalyst\n\nImageAnalyst is a library that simplifies image analysis. The library achieves this goal by standardizing the input and output\nvectors of a few machine learning models and by providing some high-level analysis algorithms.\n\n## Requirements\n\nThe application requires:\n\n- [Python](https://www.python.org/) ~= 3.9\n- [pip](https://pip.pypa.io/en/stable/)\n<!--\n## Extras\n\nThe application has some extras that can be installed:\n\n- [cv2](https://github.com/BergLucas/ImageAnalystCV2)\n- [hf](https://github.com/BergLucas/ImageAnalystHF)\n- [tf](https://github.com/BergLucas/ImageAnalystTF)\n- [onnx](https://github.com/BergLucas/ImageAnalystONNX)\n!-->\n## Download & Installation\n\nThere is two ways to download and install the application.\n\n### Using PyPI\n\nYou can download and install the application using [PyPI](https://pypi.org/project/image-analyst/). To do so, run the following command:\n\n```bash\npip install image-analyst\n```\n\n### Using the GitHub releases\n\nYou can download the application on the [downloads page](https://github.com/BergLucas/ImageAnalyst/releases). Then, you can install the application by running the following command:\n\n```bash\npip install image_analyst-X.X.X-py3-none-any.whl\n```\n\n(Note: The X.X.X must be replaced by the version that you want to install.)\n<!--\n## Example\n\nThis example allows you to track objects from your webcam. It requires the `cv2` extra.\n\n```python\nfrom image_analyst.cv2.utils import convert_image, create_frame_generator\nfrom image_analyst.cv2.models import YoloV3OpenCV\nfrom image_analyst.trackers import IOUTracker\nimport cv2\n\ndef report_callback(filename: str, current_size: float, total_size: float):\n print(\"{} {:.2f}%\".format(filename, current_size/total_size*100), end=\"\\r\", flush=True)\n\nmodel = YoloV3OpenCV.coco(report_callback=report_callback)\n\ntracking_function = IOUTracker(model)\n\nwith create_frame_generator(0) as frame_generator:\n for frame in frame_generator:\n converted_frame = convert_image(frame, model.supported_format, model.supported_dtype)\n instances = tracking_function(converted_frame)\n\n for instance in instances:\n xmin, ymin, xmax, ymax = instance.bounding_box.as_tuple()\n\n text = \"{} {} {:.2f}\".format(instance.id, instance.class_name, instance.score)\n cv2.rectangle(frame, (xmin, ymin), (xmax, ymax), (0, 255, 0), 2)\n cv2.putText(frame, text, (xmin, ymin), cv2.FONT_HERSHEY_SIMPLEX, 1, (0, 255, 0), 2)\n\n cv2.imshow(\"Tracking\", frame)\n\n if cv2.waitKey(1) & 0xFF == ord('q'):\n break\n\ncv2.destroyAllWindows()\n```\n!-->\n## License\n\nAll code is licensed for others under a MIT license (see [LICENSE](https://github.com/BergLucas/ImageAnalyst/blob/main/LICENSE)).\n\n",
"bugtrack_url": null,
"license": "",
"summary": "ImageAnalyst is a library that simplifies image analysis.",
"version": "0.2.0",
"project_urls": {
"Homepage": "https://github.com/BergLucas/ImageAnalyst",
"Repository": "https://github.com/BergLucas/ImageAnalyst"
},
"split_keywords": [
"image",
"analysis"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "41c8e61f5262772f7c9e52f2ba9dbfc017f52fae50822ae94cac88853575fe4a",
"md5": "c701138ef192bcbc04e87f195b3cb857",
"sha256": "e2858a7322f92a06cab4194d4a2c5a788132f4e7522935824af34b425be9b627"
},
"downloads": -1,
"filename": "image_analyst-0.2.0-py3-none-any.whl",
"has_sig": false,
"md5_digest": "c701138ef192bcbc04e87f195b3cb857",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.9,<4.0",
"size": 10923,
"upload_time": "2023-07-23T23:04:39",
"upload_time_iso_8601": "2023-07-23T23:04:39.161518Z",
"url": "https://files.pythonhosted.org/packages/41/c8/e61f5262772f7c9e52f2ba9dbfc017f52fae50822ae94cac88853575fe4a/image_analyst-0.2.0-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "0a0d98287195840afb114854e3f7266a0e5df6d5307e063769e1bdad516862f1",
"md5": "2f22ee9b986640e2fa0a1ceb4fdeb8f8",
"sha256": "3a4cbd6726ce0039fa434ae8b30836a1245b13f3089daed4d4e7ed0527838d06"
},
"downloads": -1,
"filename": "image_analyst-0.2.0.tar.gz",
"has_sig": false,
"md5_digest": "2f22ee9b986640e2fa0a1ceb4fdeb8f8",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.9,<4.0",
"size": 9771,
"upload_time": "2023-07-23T23:04:40",
"upload_time_iso_8601": "2023-07-23T23:04:40.876215Z",
"url": "https://files.pythonhosted.org/packages/0a/0d/98287195840afb114854e3f7266a0e5df6d5307e063769e1bdad516862f1/image_analyst-0.2.0.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2023-07-23 23:04:40",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "BergLucas",
"github_project": "ImageAnalyst",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"lcname": "image-analyst"
}