Object Oriented Framework for Filtering

Slides:



Advertisements
Similar presentations
C Language.
Advertisements

Chapter 13 – Introduction to Classes
Types in Ruby and other languages….  Classes and objects (vs prototypes)  Instance variables/encapsulation  Object creation  Object equality/comparison.
Data Structures A data structure is a collection of data organized in some fashion that permits access to individual elements stored in the structure This.
Review What is a virtual function? What can be achieved with virtual functions? How to define a pure virtual function? What is an abstract class? Can a.
Programming Paradigms Introduction. 6/15/2005 Copyright 2005, by the authors of these slides, and Ateneo de Manila University. All rights reserved. L1:
Lecture 10: Part 1: OO Issues CS 540 George Mason University.
Procedural programming in Java
Object Oriented Programming in Java. Object Oriented Programming Concepts in Java Object oriented Programming is a paradigm or organizing principle for.
Maths for Computer Graphics
George Blank University Lecturer. CS 602 Java and the Web Object Oriented Software Development Using Java Chapter 4.
ISBN Chapter 11 Abstract Data Types and Encapsulation Concepts.
Nyhoff, ADTs, Data Structures and Problem Solving with C++, Second Edition, © 2005 Pearson Education, Inc. All rights reserved Inheritance.
R-1 University of Washington Computer Programming I Lecture 17: Multidimensional Arrays © 2000 UW CSE.
Review CSC 171 FALL 2004 LECTURE 21. Topics Objects and Classes Fundamental Types Graphics and Applets Decisions Iteration Designing Classes Testing and.
1 ES 314 Advanced Programming Lec 2 Sept 3 Goals: Complete the discussion of problem Review of C++ Object-oriented design Arrays and pointers.
Design Patterns academy.zariba.com 1. Lecture Content 1.What are Design Patterns? 2.Creational 3.Structural 4.Behavioral 5.Architectural 6.Design Patterns.
Games Development 2 Entity / Architecture Review CO3301 Week
© Drexel University Software Engineering Research Group (SERG) 1 Based on the paper by Philippe Kruchten from Rational Software.
LECTURE LECTURE 17 More on Templates 20 An abstract recipe for producing concrete code.
C++ Object Oriented 1. Class and Object The main purpose of C++ programming is to add object orientation to the C programming language and classes are.
Introduction to Object-oriented programming and software development Lecture 1.
Spreadsheet-Based Decision Support Systems Chapter 22:
Java Class Syntax CSIS 3701: Advanced Object Oriented Programming.
Lists in Python.
1 CSC 221: Introduction to Programming Fall 2012 Functions & Modules  standard modules: math, random  Python documentation, help  user-defined functions,
More with Methods (parameters, reference vs. value, array processing) Corresponds with Chapters 5 and 6.
Mason Vail.  A data type definition – “blueprint for objects”  Includes properties and/or methods ◦ “instance” data / methods – specific to one object.
An Introduction to Java Chapter 11 Object-Oriented Application Development: Part I.
Programming Languages and Paradigms Object-Oriented Programming (Part II)
Porting Implementation of Packet Utilization Standard from ADA to JAVA Annelie Hultman (TEC-EME) Donata Pedrazzani (TEC-EMS) ESA/ESTEC 2004 JPUS de-briefing.
Feb 20, 2002Soumya Mohanty, AEI1 GEO++ A general purpose C++ DSP library Plan of presentation Soumya Mohanty: Overview R. Balasubramanian: MPI Shell, Frame.
Copyright 2003 Scott/Jones Publishing Standard Version of Starting Out with C++, 4th Edition Chapter 13 Introduction to Classes.
Java Objects and Classes. Overview n Creating objects that belong to the classes in the standard Java library n Creating your own classes.
Agenda Object Oriented Programming Reading: Chapter 14.
Applications Development
ISBN Chapter 11 Abstract Data Types and Encapsulation Concepts.
1 CSC241: Object Oriented Programming Lecture No 25.
Java Fundamentals Usman Ependi UBD
1 OOP - An Introduction ISQS 6337 John R. Durrett.
PROGRAMMING IN C#. Collection Classes (C# Programming Guide) The.NET Framework provides specialized classes for data storage and retrieval. These classes.
Software Reuse Course: # The Johns-Hopkins University Montgomery County Campus Fall 2004 Session 5 Lecture # 4 – October 5, 2004.
(1) ICS 313: Programming Language Theory Chapter 11: Abstract Data Types (Data Abstraction)
CSC Programming for Science Lecture 28: Multi-dimensional Arrays.
Java & C++ Comparisons How important are classes and objects?? What mechanisms exist for input and output?? Are references and pointers the same thing??
OOPS CONCEPT.  OOPS  Benefits of OOPs  OOPs Principles  Class  Object Objectives.
MULTI-DIMENSIONAL ARRAYS 1. Multi-dimensional Arrays The types of arrays discussed so far are all linear arrays. That is, they all dealt with a single.
Singleton Academy, Pune. Course syllabus Singleton Academy Pune – Course Syllabus1.
Mid-Year Review. Coding Problems In general, solve the coding problems by doing it piece by piece. Makes it easier to think about Break parts of code.
CIS 595 MATLAB First Impressions. MATLAB This introduction will give Some basic ideas Main advantages and drawbacks compared to other languages.
Classes Classes are a major feature of C++. They support – – Abstraction – Data hiding – Encapsulation – Modularity – Re-use through inheritance.
ENEE150 – 0102 ANDREW GOFFIN Abstract Data Types.
Objects as a programming concept
JAVA MULTIPLE CHOICE QUESTION.
Basic 1960s It was designed to emphasize ease of use. Became widespread on microcomputers It is relatively simple. Will make it easier for people with.
C++ Templates.
The Object-Oriented Thought Process Chapter 1
Physical Structure of GDB
Object-Orientated Programming
OOP and ADTs Chapter 14 Nyhoff, ADTs, Data Structures and Problem Solving with C++, Second Edition, © 2005 Pearson Education, Inc. All rights reserved.
Subprograms and Programmer Defined Data Type
Use of Mathematics using Technology (Maltlab)
Introduction to Data Structure
Dr Tripty Singh Arrays.
Object-Oriented Programming
Simulation And Modeling
Programming Languages and Paradigms
Oriented Design and Abstract Data Type
C++ Object Oriented 1.
Games Development 2 Entity / Architecture Review
Presentation transcript:

Object Oriented Framework for Filtering Jonathan Wiersma Jarett Hailes MITACS-PINTS

Presentation Overview Overview of Programming Concepts Procedural Programming Object Oriented Design Current State of PINTS Projects Proposed Improvements Filtering project framework Common Interfaces Shared set of utility classes Refactoring Implementation and Challenges Conclusion & Future Directions

Procedural Programming - Overview integer char Variables float pointer Data Structures combinations of previous Functions multiple inputs (parameters) single output (return value) Different than functions in math: May map same input to different outputs behavior can depend on state of global variables variables are mutable

Procedural Programming – Example 1 Global variable (accessible to all functions) int global_var; void main() { int a,b,c; a = 3; b = 4; c = sum(a,b); output(c); } int sum(int x, int y) { return x + y; function variables Variable assignment Function call

Object Oriented Design - Basics Objects Classes Variables/State Methods

Object Oriented Design - Classes Combines a data structure (set of variables) with operations related to that data structure (methods) Describes a class of objects (like a set) An object is an instance of a class and has a state

Object Oriented Programming: Code Structure Procedural Program: Object Oriented Program: Data Structures Global variables Class 1 Data Structure methods Procedures/functions Class 2 Data Structure methods

Object Oriented Design - Concepts Encapsulation Inheritance Polymorphism

State of Code at PINTS Each project is a completely separate entity Interfaces are different between projects Interfaces are not clearly defined (templates) No code reuse – improvements only effect one project Large undertaking to create a new project Not easy to read and understand

Improvements being Developed Create a filtering project framework Shared underlying structure Suite of useful utility classes Abstract output model (M-V-C pattern)

Framework for Filtering Projects Create a set of generic classes and interfaces (via inheritance) Have filters use these generic interfaces so they don’t require customized code Design a framework to ease the development effort of applying a filter to a new application

Shared Filtering Interface SERP Filter DType Signal Observation Observer POD Signal POD 13 Observation POD 13 SERP Observer

CVS – Concurrent Versioning System Allows several users to work on the same files at the same time Stores old versions and changes Also useful for text and latex documents

CVS Layout

Interfaces Filter SERP Filter DType Signal Observation Observer POD Signal POD 13 Observation POD 13 SERP Observer

Interfaces Signal BoundedSignal DType position void evolve() AbsDomain domain AbsDomain domain()

Interfaces Observation ODType position void observe(Signal, double dt)

Interfaces Observer SERP Observer Observation void observe(Observation, double dt) SERP Observer double weightedOffset(Signal, double dt)

CVS Math Package - Algebra Ideally: Matrix Row Matrix Column Matrix Row Vector Column Vector

CVS Math Package - Algebra Row Vector Scalar values[] int dimension math operators (+,-,*,+=,-=,*=,etc) accessors RowVector norm() void normalize()

CVS Math Package - Algebra Column Vector Scalar values[] int dimension math operators (+,-,*,+=,-=,*=,etc) accessors ColumnVector norm() void normalize()

CVS Math Package - Algebra Row Matrix RowVector values[] int nrows, ncols math operators (+,-,*,+=,-=,*=,etc) accessors RowMatrix inverse() void invert()

CVS Math Package - Coordinates Euclidean Coordinate Polar Coordinate

CVS Math Package - Coordinates CType value math operators (+,-,*,+=,-=,*=,etc) accessors

CVS Math Package - Coordinates Polar Coordinate CType max, min math operators (+,-,*,+=,-=,*=,etc) accessors

CVS Math Package - Domain Abstract Domain Abstract Bounded Domain Vector Box Domain

CVS Math Package - Domain Abstract Domain bool contains(DType) Abstract Bounded Domain DType min, max DType min() DType max()

CVS Math Package - Domain Range Type Abstract Function Domain Type Continuous Function Discrete Function

CVS Math Package - Domain Abstract Function int dimension Range operator()(Domain val) int dimension() Range Type Domain Type

CVS Math Package - Domain Abstract Function Range Type int dimension Domain Type Range operator()(Domain val) int dimension() Continuous Function Range operator()(Domain val) DiscreteFunction discretize() DiscreteFunction fft(VBoxDom<DType>, int)

CVS Math Package - Domain Abstract Function Range Type int dimension Domain Type Range operator()(Domain val) int dimension() Discrete Function VectorBoxDomain<DType> domain MultiDArray<RType> data int numDivisions DType delta[] RType index(int idx[]) DiscreteFunction fft(int type) accessors

Graphics - Legacy Packages of raster graphics procedures Outdated Custom code Not supported Very low level

Graphics - povray 3D Ray Tracing program Beautiful output Slow Rendering Separate Application Requires specific input format

Graphics - VTK Object Oriented 3D Visualization Toolkit Uses standard visualization network Fairly fast Easy to incorporate into real-time display Support for several languages

Graphics – Output Classes Text Output PovRay Output VTK Output POD 13 PovRay Output POD 13 VTK Output

Utilities - Simulations Abstract Simulation Classes Rapid Simulation Development Code reuse Standard Code Layout Signal Simulation Observation Simulation Filter Simulation

Utilities - Simulations Controller Simulation View Model Simulation View Simulation Model POD 13 Filter View 1 Filter Simulation Model Filter Output SERP Filter Signal Observation Text Output VTK Output POD Signal POD 13 Observation

Utilities - Structures Data Structures Hash Table / Hash Bin List Multi Dimensional Array Dictionary We’ve made some container data structures for use in all other directories. Are there to facilitate portability of data across classes (much like Vector and matrix classes in math) Most containers are templatable.

Refactoring Splitting large classes into smaller ones Better encapsulation Fewer variables to remember Fewer methods to remember More abstraction Splitting large methods into smaller ones Less code to read through to understand method Easier to reuse code Moving methods (feature envy) Easier to understand Easier to locate

Implementation Signal – evolve() Observation - observe(Signal) Observer – depends on filter(s) used Output – output()

Challenges Multiple Inheritance Return by value Graphics MVC Model Observer Interfaces Return by value multiple copies inheritance Graphics MVC Model templates

Future Directions Single Filtering Application for all Projects Scripting Language Language Change (java?) Talk on using CVS for latex papers Suggestions