cv2-rgb
copied
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Readme
Files and versions
Updated 2 months ago
image-decode
Image Decode Implementation with CV2
author: Kaiyuan Hu, Rentong Guo
Description
An image decode operator implementation with OpenCV.
Code Example
Load a image from path './src_dog.jpg'.
Write a pipeline with explicit inputs/outputs name specifications:
from towhee import pipe, ops, DataCollection
p = (
pipe.input('path')
.map('path', 'image', ops.image_decode.cv2_rgb())
.output('path', 'image')
)
Factory Constructor
Create the operator via the following factory method:
image_decode.cv2_rgb()
Interface
An image decode operator takes an image path as input. It decodes the image back to ndarray.
Parameters:
img: str
Image file path.
Returns: towhee.types.Image (a sub-class of numpy.ndarray)
The decoded image data as numpy.ndarray.
More Resources
- Scalar Quantization and Product Quantization - Zilliz blog: A hands-on dive into scalar quantization (integer quantization) and product quantization with Python.
- How to Get the Right Vector Embeddings - Zilliz blog: A comprehensive introduction to vector embeddings and how to generate them with popular open-source models.
- Understanding Computer Vision - Zilliz blog: Computer Vision is a field of Artificial Intelligence that enables machines to capture and interpret visual information from the world just like humans do.
- The guide to clip-vit-base-patch32 | OpenAI: clip-vit-base-patch32: a CLIP multimodal model variant by OpenAI for image and text embedding.
- Using Vector Search to Better Understand Computer Vision Data - Zilliz blog: How Vector Search improves your understanding of Computer Vision Data
- Demystifying Color Histograms: A Guide to Image Processing and Analysis - Zilliz blog: Mastering color histograms is indispensable for anyone involved in image processing and analysis. By understanding the nuances of color distributions and leveraging advanced techniques, practitioners can unlock the full potential of color histograms in various imaging projects and research endeavors.
- Understanding ImageNet: A Key Resource for Computer Vision and AI Research: The large-scale image database with over 14 million annotated images. Learn how this dataset supports advancements in computer vision.
- Image Embeddings for Enhanced Image Search - Zilliz blog: Image Embeddings are the core of modern computer vision algorithms. Understand their implementation and use cases and explore different image embedding models.
Jael Gu
a0243c4475
| 12 Commits | ||
---|---|---|---|
.gitattributes |
1.1 KiB
|
2 years ago | |
README.md |
3.0 KiB
|
2 months ago | |
__init__.py |
700 B
|
2 years ago | |
image_decode_cv2.py |
2.8 KiB
|
4 months ago | |
requirements.txt |
29 B
|
2 years ago | |
result.png |
58 KiB
|
2 years ago | |
src_dog.jpg |
26 KiB
|
2 years ago |