group #6 evan davidson afsaan kermani viker lamardo scott moriarty

37
Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

Upload: jeffrey-lawson

Post on 17-Dec-2015

219 views

Category:

Documents


1 download

TRANSCRIPT

Page 1: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

Group #6

Evan Davidson

Afsaan Kermani

Viker Lamardo

Scott Moriarty

Page 2: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

What is Park Sense?

Park sense is a system which maps out a parking lot and detects and displays which parking spaces are vacant and which are occupied.

Page 3: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

Motivation

• We wanted to solve an everyday problem that is relevant to UCF students

• Can take up to 30 minutes to find parking during peak traffic hours

• 55,000 students at UCF and only 15,500 parking spaces available, not all of which are available to students

• Help students and faculty get to class on time

Page 4: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

Objectives

• Accurate car detection

• Detect the car during all times of the day

• Capable of accommodating a network of cameras so that the project is scalable and can be applied to most of the parking lots in the real world

Page 5: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

Requirements

• Cost effective and easy to install

• Weather resistant

• Fixed position

• Wide range of view

• Scheduled day/night mode

Page 6: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

Specifications

• Range: minimum of 2 spaces

• Cost: under $10 per parking space

• Power source: standard 120VAC (wall outlet) or 12V battery powered

• Accuracy: 95% and a system refresh time of less than 20 seconds

• Operating environments -Temperature: 0 to 115 °FHumidity: 80% RH

Page 7: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

Features

• LCD display that greets the user as they drive in to the parking lot

• Website showing live updates on the status of the parking spaces in the parking lot

• It doubles as a security system because we are using live video feeds

• Parking stats

Page 8: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

Research

Page 9: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

Ultrasonic Sensors• Would require a large number of sensors to cover a full parking lot

• Wide range allowed us to possibly use one sensor per two parking spots

Advantage Disadvantage

UltrasonicEmitter/Receiver

1.64’’

Page 10: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

Infrared Sensors

Infrared

• Range was not as wide as the ultrasonic sensor

• Less expensive than the ultrasonic sensor

Advantage Disadvantage

Page 11: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

Camera

2.34’’ 5.91’’

•We decided to use the Vivotek IP7330 for the Park Sense System•Description: bullet-style network camera designed for outdoor applications•Advantages:

•shields from harsh conditions such as rain and dust•supports tamper detection (i.e. blockage, redirection, & spray-painting)•Functions as a security camera for students in the parking lot•Has both a long and wide range•Has both day and night vision capabilities•Easy connection router and server to perform image processing•Supports PoE (power over Ethernet)

Page 12: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

Camera

Server

Captures an Image

Image processing

Data analysis

Generates statistics

Display

Outputs data

System Block Diagram

Page 13: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

Image capture • The network camera captures an jpg image from the mjpg stream

Page 14: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

Image processing • The captured image is then processed through the code to accurately object detect cars in the parking lot

Page 15: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

Data output• The program then outputs to a .csv file with information based on the processed image.

Page 16: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

Dynamic website• The website is able to update the number of

rows, columns, and statistical values by reading the .csv file that our initial analysis produces.

Page 17: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

Display

Because we are already generating a webpage, all we have to do is keep that site displayed on an LCD screen mounted at the entrance to the parking lot

Page 18: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

System refresh & update display

• The website is then updated with the proper graphical view of the vacant parking lots.

Page 19: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

Networking

• Originally we planned on using multiple sensors in a mesh network design, but due to budget constraints and design modifications we decided to use a basic Ethernet network to allow for scalability in practical applications

• The camera operates on a local area network (LAN) with the computer and display.

Page 20: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

OpenCV

Page 21: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

Haar-Like Features

The value of a Haar-like feature is the difference between the sum of the pixel gray values within the black and white rectangular regions

The image is then scanned by a sub window containing a Haar-like feature trying to detect on the classifiers it was trained on

Page 22: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

Cascade of Classifiers• AdaBoost uses a “weak” learning

algorithm and a training set to create strong classifiers– Adaptive because later classifiers are geared to

be in favor of sub-windows misclassified by previous classifiers

• Series of classifiers are applied to every sub-window, the first eliminates a large number of negative sub-windows and passes all positives (lots of false positives)– Followed by a set amount of stages which do

the same to reduce the number of false positives in the final product

Page 23: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

Data Preparation

Collect positive images. Obtain negative sample set. Create info files. Generate vec files. Train cascade.

Page 24: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

Object Marking

For the positive sample set, object marking was required. The positive info file looked like the following:

Page 25: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

Testing a Cascade

Page 26: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

Software

C++ OpenCV Library Single Run, repeated using a batch file

Can be continual

Low CPU usage Scalable

Page 27: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

Software Flow

1. Capture image

2. Gray scale

3. Object detection

4. Region of interest rectangle comparing

5. Output to .csv file

6. Sleep for set time interval

repeat

Page 28: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

Determining a Hit• For each rectangular object detected, the X,Y

coordinates and the height and width are stored in a cvRect() object within another object which contains the total number of objects found, CvSeq

• These are passed to the function RectDetect() which also takes in the same set of values for a single ROI

• The boundaries of each are compared to determine there’s an overlap

• Once a hit is announced for a given ROI no other detected objects will be compared to that ROI to save on processing time

Page 29: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

Testing

Page 30: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

Testing

• Haar training:• Created a variety of cascades including cars,

headlights and windshields. Also tested rectangles to possibly detect empty spots.

• Testing the cascades• Analyzing hits, misses, and false hits

•Website:• Loading the .csv properly• Aligning .csv cells with parking spots

Page 31: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

The Test Setup

• Determine best test subjects among model cars or pictures of cars• Determine the best camera positioning for accuracy.• Control the lighting

• Testing IR• Calibrate the regions of interest

Page 32: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

Testing Results Trying to detect full cars and headlights,

resulted in ~ 0% We tried to detect windshields on a cascade

using ~500 positives and ~500 negatives.Results varied between 40-80%Shadows generate false positives.Camera distance from the cars affected

accuracyNuanced lighting led to diminished accuracyIR detection worked toward center of image.

Page 33: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

Testing Results Continued The windshields likely succeeded

because it resembles a Haar-like feature. Line features and center surround features.

The windshield is somewhat consistent between all cars.

Ideally, multiple cascades would be used to detect all cars.

Page 34: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

Problems

• We are all hardware oriented in a mostly software project• Lighting conditions in the parking lot were a problem as stated.• Cars that are the same color as the asphalt.• Working with open source library was difficult.• Recommended cascades call for between 2,000 and 4,000 positives and 4,000 to 10,000 negatives.

• Training of such a robust cascade would require at least a week of processing on a home computer

Page 35: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

BudgetPart Cost

Vivotek IP 7330 Camera $270

Server $0 – already owned

LCD Display $0 – already owned

Router $0 – already owned

Miscellaneous $50

Total $320

Page 36: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

Milestones

Page 37: Group #6 Evan Davidson Afsaan Kermani Viker Lamardo Scott Moriarty

Demo and

Q & A