Skip to main content

image tools for deep learning

Project description

Introduction

yyimg is a high-level image-processing tool, written in Python and using OpenCV as backbend. This repo helps you with processing images for your deep learning projects.

Installation

Commands to install from pip or download the source code from our website https://pypi.org/project/yyimg

$ pip3 install yyimg==1.0.0rc

Example Useage

Take one image in Kitti dataset for example:

import yyimg
from PIL import Image
image, boxes, classes = yyimg.load_data()
Items Description
image a numpy array of shape (height, width, #channels)
boxes a numpy array of shape (N, 5), representing N 2Dboxes of [class_index, xmin, ymin, xmax, ymax]
classes a list of class names
print(classes)
['Car', 'Truck', 'Van', 'Pedestrian']

visualize 2D boxes

draw_image = yyimg.draw_2Dbox(image, boxes, class_category=classes)
draw_image = cv2.cvtColor(draw_image, cv2.COLOR_BGR2RGB) # BGR -> RGB
Image.fromarray(draw_image).show()

image

data augmentation

- horizontal_flip

with 2D bounding boxes:

aug_image, boxes = yyimg.horizontal_flip(image, boxes)

without 2D bounding boxes:

aug_image = yyimg.horizontal_flip(image)

image

- add_rain

aug_image = yyimg.add_rain(image)

image

- shift_gama

aug_image = yyimg.shift_gamma(image) 

image

- shift_brightness

aug_image = yyimg.shift_brightness(image)

image

- shift_color

aug_image = yyimg.shift_color(image)

image

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

yyimg-1.0.2.tar.gz (839.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

yyimg-1.0.2-py3-none-any.whl (840.5 kB view details)

Uploaded Python 3

File details

Details for the file yyimg-1.0.2.tar.gz.

File metadata

  • Download URL: yyimg-1.0.2.tar.gz
  • Upload date:
  • Size: 839.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.15.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.5.2

File hashes

Hashes for yyimg-1.0.2.tar.gz
Algorithm Hash digest
SHA256 dd09acea83a96c6e7cfeb37190e34519b67ebc6b25804d2f5d2422ef74ecdf92
MD5 4fc88dec34d8c500030f5d6f88b59937
BLAKE2b-256 b2885f0c3a21ed54b3c7bb397f7263c2f10b562e246dfc44ac910c58f1bc2537

See more details on using hashes here.

File details

Details for the file yyimg-1.0.2-py3-none-any.whl.

File metadata

  • Download URL: yyimg-1.0.2-py3-none-any.whl
  • Upload date:
  • Size: 840.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.15.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.5.2

File hashes

Hashes for yyimg-1.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 1f64fa4c7969ddf55222ad2c985cf882fbc0b85c227617bcb12154579928a2c7
MD5 1da17e0c6c75d70dd4aedd7956150b9c
BLAKE2b-256 a374fa73f7ad99d6cf1f79be66fc76b9c678526d2ffc09ed94cceb19337330d5

See more details on using hashes here.

Supported by

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