New User Special Price Expires in

Let's log you in.

Sign in with Facebook


Don't have a StudySoup account? Create one here!


Create a StudySoup account

Be part of our community, it's free to join!

Sign up with Facebook


Create your account
By creating an account you agree to StudySoup's terms and conditions and privacy policy

Already have a StudySoup account? Login here

Advanced Image Processing

by: Maudie Quitzon

Advanced Image Processing EE 565

Maudie Quitzon
GPA 3.98

Xin Li

Almost Ready


These notes were just uploaded, and will be ready to view shortly.

Purchase these notes here, or revisit this page.

Either way, we'll remind you when they're ready :)

Preview These Notes for FREE

Get a free preview of these Notes, just enter your email below.

Unlock Preview
Unlock Preview

Preview these materials now for free

Why put in your email? Get access to more of this material and other relevant free materials for your school

View Preview

About this Document

Xin Li
Class Notes
25 ?




Popular in Course

Popular in Electrical Engineering

This 27 page Class Notes was uploaded by Maudie Quitzon on Saturday September 12, 2015. The Class Notes belongs to EE 565 at West Virginia University taught by Xin Li in Fall. Since its upload, it has received 25 views. For similar materials see /class/202854/ee-565-west-virginia-university in Electrical Engineering at West Virginia University.

Similar to EE 565 at WVU

Popular in Electrical Engineering


Reviews for Advanced Image Processing


Report this Material


What is Karma?


Karma is the currency of StudySoup.

You can buy or earn more Karma at anytime and redeem it for class notes, study guides, flashcards, and more!

Date Created: 09/12/15
Matlab Advanced Programming Matt Wyant University of Washington Matlab as a programming Language Strengths as compared to CCFortran Fast to write no type declarations needed Memory allocationdeallocation handled automatically Functions and scripts can be accessed automatically from path VectorMatrix operations in many dimensions built in Polymorphic with respect to matrix dimensions Matlab as a programming Language Strengths Fairly easy to handle strings Easy inputoutput Easy to build a function library Mathematical functions built in Plotting and Visualization built in Additional toolboxes Matlab as a programming Language Weaknesses Expensive Debugging complex code can be tricky Not objectoriented Behavior of built in functions must be learned No type declarations needed example Namespace collisions example Outline Scripts vs Functions Techniques for writing functions Structures CellArrays Examples Not included Matlab graphics Objectoriented programming Interfaces to other languages Not much on handling matrices Matlab Scripts plotsquaredm X 55 y X A2 plotxy Run with plotsquared Advantages of Scripts Easy to write Easy to patch together and nest Can be cut and paste directly into Matlab command line Can use any variables already in the workspace Disadvantages of Scripts Scripts have uncertain variable scope Scripts are hard to modularize Modifications can be cumbersome Script inputs and outputs are not explicit Scripts are hard to loop over safely Scripts can be cumbersome to test Ways to protect against scope problems in scripts clear all include at top of script or type it sometimes not desirable Initialize all variables you use Beware assignment to parts of an un initialized array Suppose y is a 20x20 array Then the following script is run X 55 ylll x 2 plotxy Fixed version zeroslll Y X 55 ylll x quot2 plotxy Matlab Functions Example complexphaseandmagnitudem Arguments are passed by value All variables are internal unless you use GLOBAL variables so your workspace is not altered Can be called with fewer than specified input arguments Can be called with fewer than specified output arguments Functions can have indefinite arguments at the end of the argument list Advantages of Functions Reuseable develop your own libraries or get functions from others Robust rules all in one place debug shared methods once Sharable Selfdocumenting Can be used easily customize builtin matlab func ons Provide variable scope safety Can be called inside of scripts one rule one place Disadvantages of Functions Designing them takes time and practice Debugging can be more involved than for scripts Guidelines for writing functions Write at least minimal documentation required inputs optional inputs outputs units Use a descriptive function name Use descriptive variable names Possibly check the input arguments size number of dimensions type Guidelines for writing functions If you can don t assume the size of input matrices Write functions to apply a process to whole matrices not just scalars avoid looping over matrices If you see repeated similar procedures consider looping over them or making them a function If you can don t assume the size of input matrices Avoid GLOBAL variables Make them arguments instead If you need persistent variables use persistent If you need lots of physical constants pass them in as a structure Small simple functions can be very useful examples Evolve a script into a function Choose a script or piece of a script that has a narrowly defined purpose Choose a script or piece of a script that you are likely going to want to use multiple times Identify the parameters Gather all parameters at the top of the script Decide which parameters are going to be changed often These will be the input arguments Identify the useful outputs of the script These will be the output arguments Choose a good name Matlab Structures Group variables Group data of different sizestypes meta data with variables Sort by name Nest Cellarrays Containers for multiple Matlab objects of different types and sizes Useful for grouping character strings Can be used as commaseparated lists used to get subset of cell array used to get contents of cells Examples Exploiting Matlab matrix handling Passing back complex output using structures Extending existing Matlab functions using varargin Looping over variables with cellarrays Exploiting Matlab matrix handling Many builtin and user made functions can handle arbitrarily sized matrices Matrices typically must all be the same size The functions must use elementbyelement math methods on these matrices A X y X y X Y Example qsatm satvaporpressurem Passing back complex output using structures Example retrievesoundingm Saves all useful information about a procedure or computation Adding new info won t break existing functions or scripts Results can be passed to other functions or grouped in arrays Extending existing Matlab functions varargin allows you to create functions with an unspecified number of arguments Use varargin as last argument in your func on In body of the function the cell array called varargin contains a list of the extra arguments Example fitscatterplotm fitscatterplot2m Looping over variables with cell arrays CeIIarrays provide a convenient way to loop through variable data noloopm oopm References Matlab Help help help topic help function name doc function name wwwmathworkscom Graphics and GUl s with MATLAB Patrick Marchand and 0 Thomas Holland This talk will be placed soon at wwwatmoswashingtonedumwyant Additional Topics Matrix manipulations and higher dimensional matrices Handle Graphics Techniques Matlab Graphics for Publication and Presentation Performance Tips NetCDF Interface Handling Missing Data Interface with CC or Fortran


Buy Material

Are you sure you want to buy this material for

25 Karma

Buy Material

BOOM! Enjoy Your Free Notes!

We've added these Notes to your profile, click here to view them now.


You're already Subscribed!

Looks like you've already subscribed to StudySoup, you won't need to purchase another subscription to get this material. To access this material simply click 'View Full Document'

Why people love StudySoup

Steve Martinelli UC Los Angeles

"There's no way I would have passed my Organic Chemistry class this semester without the notes and study guides I got from StudySoup."

Janice Dongeun University of Washington

"I used the money I made selling my notes & study guides to pay for spring break in Olympia, Washington...which was Sweet!"

Jim McGreen Ohio University

"Knowing I can count on the Elite Notetaker in my class allows me to focus on what the professor is saying instead of just scribbling notes the whole time and falling behind."

Parker Thompson 500 Startups

"It's a great way for students to improve their educational experience and it seemed like a product that everybody wants, so all the people participating are winning."

Become an Elite Notetaker and start selling your notes online!

Refund Policy


All subscriptions to StudySoup are paid in full at the time of subscribing. To change your credit card information or to cancel your subscription, go to "Edit Settings". All credit card information will be available there. If you should decide to cancel your subscription, it will continue to be valid until the next payment period, as all payments for the current period were made in advance. For special circumstances, please email


StudySoup has more than 1 million course-specific study resources to help students study smarter. If you’re having trouble finding what you’re looking for, our customer support team can help you find what you need! Feel free to contact them here:

Recurring Subscriptions: If you have canceled your recurring subscription on the day of renewal and have not downloaded any documents, you may request a refund by submitting an email to

Satisfaction Guarantee: If you’re not satisfied with your subscription, you can contact us for further help. Contact must be made within 3 business days of your subscription purchase and your refund request will be subject for review.

Please Note: Refunds can never be provided more than 30 days after the initial purchase date regardless of your activity on the site.