Book Image

Practical Data Analysis - Second Edition

By : Hector Cuesta, Dr. Sampath Kumar
Book Image

Practical Data Analysis - Second Edition

By: Hector Cuesta, Dr. Sampath Kumar

Overview of this book

Beyond buzzwords like Big Data or Data Science, there are a great opportunities to innovate in many businesses using data analysis to get data-driven products. Data analysis involves asking many questions about data in order to discover insights and generate value for a product or a service. This book explains the basic data algorithms without the theoretical jargon, and you’ll get hands-on turning data into insights using machine learning techniques. We will perform data-driven innovation processing for several types of data such as text, Images, social network graphs, documents, and time series, showing you how to implement large data processing with MongoDB and Apache Spark.
Table of Contents (21 chapters)
Practical Data Analysis - Second Edition
Credits
About the Authors
About the Reviewers
www.PacktPub.com
Preface

Introduction to image processing with PIL


The goal of this chapter is to present some of the pre-installed capabilities of Wakari. In this section, we will explore some of the basic functions of PIL (Python Image Library), such as histograms, filters, operations, and transformations. We already installed and used PIL in Chapter 5, Similarity-Based Image Retrieval.

First, we will upload the images 412.jpg (Dinosaur) and 826.jpg (Land) to the path (see the arrow in the following screenshot). The images came from the Caltech-256 images-dataset used in Chapter 5, Similarity-Based Image Retrieval.

Opening an image

The first thing we need to start working is to import the PIL and pylab modules. Next, we will use the open() method of the Image object. Finally, we will visualize the image with the imshow() method of pylab. In the following screenshot, we can see the output of the code:

Tip

We can find more information about PIL from its website: http://www.pythonware.com/products/pil/

Working with...