Code Monkey home page Code Monkey logo

waldo's Introduction

waldo project

##Install :

This is a standard Golang project. Go to the project and install it . See also [https://golang.org/doc/install]

go install

##Getting started :

Once you have installed, you can run the waldo executable using command lines.

###Help

./waldo -h

Usage of /home/grego/go/bin/waldo:
  -key string
    	Key of the photo
  -readers int
    	Number of workers reading photos (default 12)
  -writers int
    	Number of workers indexing photos (default 12)

Note: Use either -key if you want to query a photo or you will run the read/write program.

###Run the program

./waldo

worker 3 indexing photo 01a2539a-9e53-4050-a6b5-d94f0ee6cc55.10ab5118-b1e5-4ac9-922e-125138dbdf87.jpg
worker 7 indexing photo 01a11242-35d0-4865-8f90-5db01a30ed51.e8ae7a45-8b4c-4142-b3d2-0f631d543b20.jpg
worker 5 indexing photo 01DD6669-1AF1-4A46-9D32-75FDD2882D17.ede96cc7-5500-4b3a-8828-26aabcaa2f4c.jpg
...
worker 4 indexing photo 01a8f6cd-3239-43ce-b756-95abf64a1b12.bf54b6d2-542e-4c48-8a8a-53b47e6b91d5.jpg
worker 12 indexing photo 01b819c4-c765-4dca-a407-609b64954126.a17c6591-de20-4b75-a5de-0bb11a34a116.jpg
worker 8 indexing photo 0188017b-0d90-4cab-9009-bbb74501c3d5.ede96cc7-5500-4b3a-8828-26aabcaa2f4c.jpg

FINISHED 129 photos have been processed

You should see the FINISHED flag with the total number of photos that have been read and indexed.

You might want to add more readers or writers and test performance by setting writers and readers command flags.

###Make a query to check a photo EXIF data

$GOPATH/bin/waldo -key 0009fcfe-376e-42fe-85a2-85ee7d2193d0.0649232a-b406-4ec1-b175-ba0d91aa3e7c.jpg
Artist = 
Copyright = 
DateTime = 2016:06:09 17:24:35
DateTimeDigitized = 2016:06:09 17:24:35
DateTimeOriginal = 2016:06:09 17:24:35
InteroperabilityIndex = R98
Make = NIKON CORPORATION
Model = NIKON D750
Software = Ver.1.02 
SubSecTime = 32
SubSecTimeDigitized = 32
SubSecTimeOriginal = 32

##Concurrency

Since I/O network resources and Disk I/O are the main bottleneck I have separated consumer from producer and made each process concurrent. The producer process reads and parses EXIF data. I called it Reader. The consumer process (Indexer) indexes EXIF data into a LevelDB data store.

This is a "concurrent read concurrent write" parallel memory model in which multiple go routine can read simultaneously , and multiple indexers can write simultaneously to a single LevelDB datastore.

The number of consumers rand producers are limited and configurable.

waldo's People

Contributors

guregodevo avatar

Watchers

James Cloos 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.