Functional programming for computer vision

Functional programming is a style of programming that avoids the use of side effects (like assignment) and uses functions as first class data objects. Compared with imperative programs, functional programs can be parallelized better, and provide better encapsulation, type checking, and abstractions. This is important for building and integrating large vision software systems. In the past, efficiency has been an obstacle to the application of functional programming techniques in computationally intensive areas such as computer vision. We discuss and evaluate several 'functional' data structures for representing efficiently data structures and objects common in computer vision. In particular, we will address: automatic storage allocation and reclamation issues; abstraction of control structures; efficient sequential update of large data structures; representing images as functions; and object-oriented programming. Our experience suggests that functional techniques are feasible for high- performance vision systems, and that a functional approach simplifies the implementation and integration of vision systems greatly. Examples in C++ and SML are given.

[1]  Andrew W. Appel,et al.  Standard ML of New Jersey , 1991, PLILP.

[2]  Bjarne Stroustrup,et al.  The C++ programming language (2nd ed.) , 1991 .

[3]  Lawrence Charles Paulson,et al.  ML for the working programmer , 1991 .

[4]  Robin Milner,et al.  Definition of standard ML , 1990 .

[5]  William D. Clinger,et al.  Revised3 report on the algorithmic language scheme , 1986, SIGP.

[6]  L. Peter Deutsch,et al.  Efficient implementation of the smalltalk-80 system , 1984, POPL.

[7]  M.N. Sastry,et al.  Structure and interpretation of computer programs , 1986, Proceedings of the IEEE.

[8]  Andrew W. Appel,et al.  Simple generational garbage collection and fast allocation , 1989, Softw. Pract. Exp..

[9]  David Ungar,et al.  The design and evaluation of a high performance Smalltalk system , 1987 .

[10]  Annika Aasa,et al.  An efficiency comparison of some representations of purely functional arrays , 1988, BIT Comput. Sci. Sect..

[11]  Thomas M. Breuel Lexical Closures for C++ , 1988, C++ Conference.

[12]  David C. Cann,et al.  SISAL 1.2: high-performance applicative computing , 1990, Proceedings of the Second IEEE Symposium on Parallel and Distributed Processing 1990.

[13]  John H. Reppy,et al.  Asynchronous Signals is Standard ML , 1990 .

[14]  David Robson,et al.  Smalltalk-80: The Language and Its Implementation , 1983 .

[15]  Bjarne Stroustrup,et al.  The Annotated C++ Reference Manual , 1990 .

[16]  R. E. Strom Hermes: an integrated language and system for distributed programming , 1990, IEEE Workshop on Experimental Distributed Systems.