Skip to main content

A Python library for every Computer Vision Engineer

Project description

CvPal ๐Ÿ–ผ๏ธ

CvPal Logo

PyPI version License Open In Colab

Documentation

๐ŸŒŸ Introduction

Welcome to CvPal - Your Ultimate Computer Vision Companion! ๐Ÿš€

CvPal is a cutting-edge Python package designed to empower Computer Vision engineers worldwide. Our mission is to streamline image operations, dataset management, and synthetic data generation, allowing you to focus on what truly matters: building and optimizing your machine learning pipelines.

๐Ÿ† Proudly Sponsored by VisionFullSpace ๐Ÿ†

๐ŸŽฏ Features

  • ๐Ÿ–ผ๏ธ Synthetic Image Generation: Create custom datasets using text prompts
  • ๐Ÿ”„ Dataset Merging: Seamlessly combine datasets with multiple attributes
  • ๐Ÿ—‘๏ธ Label Management: Effortlessly remove or replace specific labels from your dataset
  • ๐Ÿ“Š Label Occurrence Counting: Accurately track label frequencies
  • ๐Ÿ“ Dataset Reporting: Generate comprehensive reports on your dataset
  • ๐Ÿ”Œ Easy Integration: Smoothly integrate with existing ML pipelines
  • ๐Ÿ“š Comprehensive Documentation: Detailed guides for all features
  • ๐Ÿค– AI-Powered Dataset Creation: Generate entire datasets with just a prompt
  • ๐Ÿผ Pandas Integration: Group images and labels into a pandas DataFrame for advanced manipulation

๐Ÿ“ Dataset Folder Structure

For optimal performance, please structure your dataset folder as follows:

folder/
โ”œโ”€โ”€ train/
โ”‚   โ”œโ”€โ”€ images/
โ”‚   โ””โ”€โ”€ labels/
โ”œโ”€โ”€ test/
โ”‚   โ”œโ”€โ”€ images/
โ”‚   โ””โ”€โ”€ labels/
โ””โ”€โ”€ valid/
    โ”œโ”€โ”€ images/
    โ””โ”€โ”€ labels/

For TXT format datasets, include a data.yaml config file:

folder/
โ””โ”€โ”€ data.yaml

Example data.yaml:

names:
  - Old_Paper
  - Rock
  - Scissors
nc: 3
roboflow:
  license: Private
  project: rock-paper-scissors-sxsw
  url: https://universe.roboflow.com/roboflow-58fyf/rock-paper-scissors-sxsw/dataset/14
  version: 14
  workspace: roboflow-58fyf
test: ../test/images
train: Rock-Paper-Scissors-SXSW-14/train/images
val: Rock-Paper-Scissors-SXSW-14/valid/images

๐Ÿš€ Installation

Install CvPal with a simple pip command:

pip install cvpal==1.0.0

๐Ÿ”ง Example Usage

from cvpal.generate import DetectionDataset
from cvpal.preprocessing import ImagesDetection

# Generate synthetic data
detection_dataset = DetectionDataset(model="stable-diffusion")
detection_dataset.generate("a cat looking at the camera", num_images=2, labels=["cat"], output_type="yolo", overwrite=False)

# Preprocess existing dataset
cp = ImagesDetection()
cp.read_data("/content/Rock-Paper-Scissors-SXSW-14", data_type="txt")
cp.report()

๐Ÿ“Š Supported Models and Formats

Model Name Supported Format Support in Package Detection Segmentation
YOLOv5-v11 TXT & YAML config โœ… โœ… โœ…
YOLOv3-v4 Darknet TXT โŒ โŒ โŒ
EfficientDet Pytorch JSON annotations โŒ โŒ โŒ
Detectron 2 JSON annotations โŒ โŒ โŒ
Segmentation Models XML format โŒ โŒ โŒ
TensorFlow Object Detection Binary format โŒ โŒ โŒ
Fine-tune PaliGemma JSONL annotations โŒ โŒ โŒ
Apple's CreateML Proprietary JSON format โŒ โŒ โŒ
Turi Create tools Proprietary JSON format โŒ โŒ โŒ

๐Ÿค Call for Contributions

Join the CvPal community and make a global impact! We welcome contributions of all sizes:

  • ๐Ÿ› Bug fixes and enhancements
  • ๐Ÿ“ Documentation improvements
  • ๐ŸŽจ UI/UX enhancements
  • ๐Ÿงช New feature development

To contribute major changes, please reach out through our mailing list first.

Other ways to contribute:

  • ๐Ÿ” Help triage issues
  • ๐Ÿ“š Create tutorials and presentations
  • ๐Ÿ•ต๏ธ Review pull requests

๐Ÿ“„ License

This project is licensed under the MIT License - see the LICENSE file for details.


Powered by VisionFullSpace
Empowering Computer Vision Worldwide

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

cvpal-1.0.1.tar.gz (15.5 kB view hashes)

Uploaded Source

Built Distribution

cvpal-1.0.1-py3-none-any.whl (16.2 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page