Coder Social home page Coder Social logo

open_image_google_ai_converter's Introduction

open_image_google_ai_converter

This script takes the output of OIDv6 and creates Google Vision AutoML compatible CSV files.

Requirements: You need to install the dimensions gem ("gem install dimensions")

Usage: ./open_image_google_ai_converter.rb path_to_oidv6_dataset_folder your_google_storage_bucket_name

It wil spit out the CSV file that you can upload to Google AutoML Vision models along with the pictures. It will basically create this format:

TRAIN,GOOGLE_BUCKET_URL_TO_PICTURE,LABEL,COORDINATES IN WEIRD 0-1 format

Example:

% ./open_image_google_ai_converter.rb ~/Downloads/dataset mygooglebucketname
TRAIN,gs://mygooglebucketname/squirrel_054016f3c062db4c.jpg,squirrel,0.37,0.05,,,0.91,0.86,,
TRAIN,gs://mygooglebucketname/bird_015999b27fffd5f8.jpg,bird,0.01,0.37,,,0.59,0.9,,
TRAIN,gs://mygooglebucketname/bird_015999b27fffd5f8.jpg,bird,0.38,0.13,,,0.71,0.63,,
TRAIN,gs://mygooglebucketname/bird_015999b27fffd5f8.jpg,bird,0.61,0.34,,,1.0,0.83,,
TRAIN,gs://mygooglebucketname/squirrel_1bf428228cf859f9.jpg,squirrel,0.49,0.54,,,0.68,0.71,,
TRAIN,gs://mygooglebucketname/dog_023452f5cfc72239.jpg,dog,0.18,0.58,,,0.43,0.83,,
TRAIN,gs://mygooglebucketname/dog_023452f5cfc72239.jpg,dog,0.39,0.53,,,0.65,0.83,,
TRAIN,gs://mygooglebucketname/dog_023452f5cfc72239.jpg,dog,0.4,0.24,,,0.49,0.36,,
TRAIN,gs://mygooglebucketname/dog_023452f5cfc72239.jpg,dog,0.49,0.22,,,0.59,0.35,,
TRAIN,gs://mygooglebucketname/dog_023452f5cfc72239.jpg,dog,0.59,0.22,,,0.68,0.33,,
[...]

open_image_google_ai_converter's People

Contributors

rb2k avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.