Abstract:
A circuit architecture for computing the outputs of odd and even symmetric spatial filters simultaneously comprises at least two resistive networks interconnected by at least one controlled current source. In one embodiment the nodes of the resistive network are arranged in a two-dimensional array to allow filtering of two-dimensional signals such as images. The resulting filters are orientation selective. The spatial orientation and the scale of the filter can be selected by appropriately tuning the resistive elements forming the resistive networks and the gains of the controlled sources. The controlled sources may be voltage controlled (eg transconductance amplifiers) or current controlled. This circuit architecture may be implemented in VLSI to incorporate both image sensing and orientation selective filtering on the same chip. The high computational speed of the resulting devices, as well as the ability to adjust the spatial orientation and scale of the filters, enables the computation in real time of the outputs of several filters tuned to a variety of orientations and scales.

Description:
FIELD OF THE INVENTION 
     This invention relates to the circuit architecture of two-dimensional steerable and scalable spatial filters for image processing apparatus, and in particular to such filters adapted to spatially filter a set of input currents supplied by an array of photosensitive inputs forming an image sensor. 
     BACKGROUND OF THE INVENTION 
     Oriented filters are useful for vision and image processing tasks such as texture analysis, edge detection, and motion analysis. An important sub-class of oriented filters are Gabor filters, which have complex valued convolution kernel          g        (     x   ,   y     )       =       1         2                 π          σ                 -                    x   2     +     y   2         2        σ   2                       j        (         ω   xo        x     +       ω   yo        y       )                                  
     where σ, ω xo , ω yo . This filter is tuned to spatial frequency (ω x0 , ω y0 ) and responds maximally to edges which are oriented at an angle θ=atan(ω yo /ω xo ) where θ is defined to be the angle between the horizontal (x) axis and the line perpendicular to the edge. The real part of g(x,y) is often referred to as the even Gabor filter kernel since it is even symmetric. The imaginary part of g(x,y) is often referred to as the odd Gabor filter kernel since it is odd symmetric. Gabor filter kernels have been used to model the receptive fields of neurons in the visual cortex. They have also found applications in computer vision such as stereo vision, binocular vergence control, texture segmentation and face recognition. 
     One problem with using oriented filters is that it is often necessary to compute the outputs of many filters tuned to different orientations which can be computationally expensive. To overcome this difficulty when using serial digital processing, Freeman and Adelson proposed the use of “steerable filters” (W. T. Freeman &amp; E. H. Adelson, “ The design and use of steerable filters” IEEE Trans. Pattern Analysis and Machine Intelligence,  vol. 13, no. 9, pp 891-906, Sept. 1991) wherein the output of a filter tuned to an arbitrary orientation can be synthesized as a linear combination of the outputs of a small set of “basis filters”. Steerable filters are especially useful for applications where the filter orientation must be adaptively tuned to match the image characteristics. Unfortunately, Gabor filters are not steerable in this sense. 
     Another important concept in the field of image processing is that of “scale space” (A. P. Witkin “ Scale-space filtering” Proc.  8 th    Int. Joint Conf. Artificial Intelligence,  pp. 1019-1022 IEEE 1983). The concept of scale space is that images consist of details at multiple “scales” or sizes. This may be best understood by reference to an example such as an image of a tree. At the largest scale, the boundary between the tree and the background may be detected, whereas at the smallest scale the boundaries between different leaves may be detected. Scale space filtering refers to the filtering of an image with convolution kernels of different sizes. 
     PRIOR ART 
     Several analog circuit architectures and hardware realizations for convolving one dimensional images with Gabor-type filters have been reported. A resistor network with negative resistive connections between second nearest elements was shown to be able to implement an even Gabor-type filter (L. Raffo, S. P. Sabatini, D. D. Caviglia and G. M. Bisio, “ Anisotropic active resistor meshes for implementing image processing operators” Electronics Letters,  vol. 29, no. 22, pp. 960-961 May 27, 1993). Gabor-type filters with arbitrary phase can be obtained by linear combinations of the outputs of three nearest neighbour cells (L. Raffo “ Resistive network implementing maps of Gabor functions of any phase”, Electronics Letters,  vol. 31, no. 22, pp 1913-1914, Oct. 26, 1995), and an implementation of a one dimensional array of nine cells based on transconductance amplifiers is also known (G. M. Bisio, G. M. Bo, M. Confalone, L. Raffo, S. P. Sabatini and M. P. Zizola “ An analog VLSI computational engine for early vision tasks” Proc.  7 th    Intl. Conf. Artificial Neural Networks—ICANN  &#39;97, pp. 1175-80, 1997). Also known are simulations of a double-layer transistor network operating in sub-threshold which overcomes the problem of negative resistance connections between second nearest neighbours (M. Barbaro, A. Nazarro, L. Raffo, “ Synthesis of a recurrent double - layer transistor network for early vision tasks” Proc. IEEE International Symposium on Circuits and Systems,  vol. 3, pp. 219-222, May 1998). 
     The present applicant has previously reported a one dimensional circuit architecture which simultaneously computes both odd and even Gabor-type filter outputs (B. Shi “ Gabor - type image filtering with cellular neural networks” Proc. IEEE International Symposium on Circuits and Systems,  vol. 3, pp. 558-561, May 1996). This previous architecture had a number of disadvantages, however. The first disadvantage is that for spatial frequencies less than 2atan0.5, not all filter bandwidths are achievable using only positive resistors. A second disadvantage was that the conductances of the resistors interconnecting the two resistive grids needed to matched with the gains of the transconductance amplifiers. A final disadvantage was that allowing only positive resistance values, the network could only be tuned to positive spatial frequencies. One of the major disadvantages of all of these one dimensional architectures is that it is not clear how they can be extended to two dimensional filtering where the scale and orientation of the Gabor-type filter can be tuned electronically. 
     SUMMARY OF THE INVENTION 
     An object of the present invention is to provide an analog circuit architecture which is able to compute the outputs of oriented filters with tunable orientation and scale. The filters are Gabor-type filter, which are similar to Gabor filters except that the functions modulating the complex exponentials are not Gaussian. 
     According to the present invention therefore there is provided an analog circuit for spatially filtering a plurality of signals simultaneously at inputs to an array comprising: 
     (a) a first resistive network having a plurality of nodes, each said node being associated with an input to the array, 
     (b) a second resistive network having a plurality of nodes, each said node being associated with an input to the array, 
     (c) means for injecting a current into each node of the first resistive network such that the magnitude of said current is dependent upon the voltages and/or currents in the second resistive network associated with nodes corresponding to the nearest neighbours of the corresponding input in the array, 
     (d) means for injecting a current into each node of the second resistive network such that the magnitude of said current is dependent upon the voltages and/or currents in the first resistive network associated with nodes corresponding to the nearest neighbours of the corresponding input in the array, and 
     (e) means for providing input to the circuit by injecting a current into each node of the said array such that the magnitude of said current is dependent upon the signal at the input of the array associated with said node. 
     The nodes are preferably disposed in a two-dimensional array, which is preferably a regular grid such as a rectangular, hexagonal or tridiagonal grid. However, although the invention is particularly useful in the context of a two-dimensional array, it may also be applied to a one-dimensional array which would still have a number of applications such as image tracking and alignment. 
     In preferred embodiments of the invention the means for injecting current dependent on the signal at each input to the array is a photosensitive element adapted to convert the intensity of light into an electrical current. 
     Preferably each of the resistive networks comprises transistor circuits such that the resistive connection between any first node and any second node of the circuit comprises a transistor circuit such that the current flowing between the first and second node increases monotonically with the voltage difference between the two nodes and the dependence between current and voltage is adjustable via one or more bias voltages. 
     In one possible embodiment the means for injecting current into each node of the first resistive network is a set of voltage controlled current sources controlled by the voltages at nodes in the second resistive network corresponding to nearest neighbours of the node in the array, and the means for injecting current into each node of the second resistive network is a set of voltage controlled current sources controlled by the voltages at nodes in the first resistive network corresponding to the nearest neighbours of the node in the array, and the dependence of the output currents on the control voltages is adjustable via one or more bias voltages. 
     In this embodiment the voltage controlled current sources may, for example, be transconductance amplifiers. 
     Preferably in this embodiment of the invention the nodes are disposed in a rectangular two-dimensional array and the current injected into each node of the first resistive network is supplied by two voltage controlled current sources, the first voltage controlled current source being controlled by the difference between the voltages at the nodes of the second resistive network corresponding to the right and left nearest neighbours of the node and the second voltage controlled current source being controlled by the difference between the voltages at the nodes of the second resistive network corresponding to the top and bottom nearest neighbours of the node, and the current injected into each node of the second resistive network being supplied by two voltage controlled current sources, the first voltage controlled current source being controlled by the difference between the voltages at the nodes of the first resistive network corresponding to the left and right nearest neighbours of the node and the second voltage controlled current source being controlled by the difference between the voltages at the nodes of the first resistive network corresponding to the bottom and the top nearest neighbours of the node. 
     In another embodiment of the invention the means for injecting current into each node of the first resistive network is a set of current controlled current sources whose inputs are the currents through resistive elements in the second resistive network connected to nodes corresponding to the nearest neighbours of the node in the array and wherein the means for injecting current into each node of the second resistive network is a set of current controlled current sources whose inputs are the currents through resistive elements connected to nodes in the first resistive network corresponding to the nearest neighbours of the node in the array, and wherein the dependence of the output currents on the control currents is adjustable via one or more bias voltages. 
     Whether or not the invention uses voltage or current controlled current sources, the resistive connections and the dependence of the injected currents on the voltages and/or currents may be adjusted to tune the orientation and scale of the filter. 
     It will be understood that the invention also extends to a device for spatially filtering a plurality of signals simultaneously at inputs to an array comprising a circuit as described above. 
     Furthermore, it will also be appreciated that the present invention extends to a method for filtering a two dimensional discrete signal with two filters simultaneously where the convolution kernel of the first said filter is even symmetric and orientation selective and wherein the convolution kernel of the second said filter is odd symmetric and orientation selective, comprising: 
     (a) providing first and second resistive networks, each said network having a plurality of nodes, each node being associated with one element of said two dimensional signal, 
     (b) providing means for injecting current into each node of the first resistive network such that the magnitude of the current is dependent on the voltages and/or currents in the second resistive network associated with the nodes corresponding to the nearest neighbours of the corresponding element of the two-dimensional signal, 
     (c) providing means for injecting current into each node of the second resistive network such that the magnitude of the current is dependent on the voltages and/or currents in the first resistive network associated with the nodes corresponding to the nearest neighbours of the corresponding element of the two-dimensional signal, 
     (d) providing means for communicating the two-dimensional signal to the circuit by injecting a current into each node of the said array such that the magnitude of the said current is dependent upon the element of the two-dimensional signal associated with said node, and 
     (e) providing means for outputting an electronic signal which depends upon a current or voltage associated with each node of the first and the second resistive networks. 
    
    
     BRIEF DESCRIPTION OF THE DRAWINGS 
     An embodiment of the invention will now be described by way of example and with reference to the accompanying drawings, in which: 
     FIG. 1 is a schematic illustration of the circuit architecture of a one dimensional filter, 
     FIG. 2 is a schematic illustration of the circuit architecture of a two dimensional filter, 
     FIGS.  3 ( a ) and ( b ) are measured (a) even and (b) odd filter outputs from a sensor tuned to horizontal orientations in response to a central light spot, 
     FIGS.  4 ( a ) and ( b ) are measured (a) even and (b) odd filter outputs from a sensor tuned to vertical orientations in response to a central light spot, 
     FIGS.  5 ( a ) and ( b ) are measured (a) even and (b) odd filter outputs from a sensor tuned to vertical orientations and a smaller scale than FIGS.  4 ( a ) and ( b ) in response to a central light spot, 
     FIGS.  6 ( a ) and ( b ) are measured (a) even and (b) odd filter outputs from a sensor tuned to 45° orientations in response to a central light spot, 
     FIGS.  7 ( a )-( l ) show results similar to FIGS. 3 to  6  for a 45×45 array, 
     FIG. 8 schematically illustrates an hexagonal array, 
     FIGS.  9 ( a ) and ( b ) show how transistor elements may be used as resistive elements, 
     FIG. 10 shows a one-dimensional array using transistor elements, and 
     FIG. 11 shows one possible current controlled current source. 
    
    
     DETAILED DESCRIPTION OF PREFERRED EMBODIMENTS 
     For ease of understanding and clarity, the present invention will firstly be described by reference to an embodiment in the form of a one dimensional array as shown in FIG.  1 . Its description clarifies understanding to the two dimensional array described further below. The circuit of the embodiment of FIG. 1 comprises the architecture for one pixel in a one dimensional array and consists of two resistive arrays  1 , 2  which are coupled by a pair of transconductance amplifiers  3 , 4 . The pixel of FIG. 1 may be designated as pixel m and connects to adjacent pixels m−1 and m+1 in an array of M pixels. In FIG. 1 the resistive elements are labeled by their conductances and the transconductance amplifiers are labeled by their gains. 
     In the array each pixel receives an input u(m) in the form of an input current encoding image intensity. The input current is supplied by any suitable photosensitive element. As will be shown by the following analysis, in this one dimensional embodiment the steady state voltages v r (m) and v i (m) at the corresponding nodes of the resistive arrays are even and odd Gabor-type filter outputs. 
     Defining v(m)=v r (m)+jv i (m) to be the complex valued filter output at pixel m, writing Kirchoff&#39;s Current Law one can verify that                      t                       v        (   m   )         =         a     -   1            v        (     m   -   1     )         +       a   0          v        (   m   )         +       a   1          v        (     m   +   1     )         +     u        (   m   )                                where              [           a     -   1                 a   0               a   1           ]     =     [             G     1      x       +     jG     2      x                     -     G   0       -     2        G     1      x                       G     1      x       -     jG     2      x               ]                            
     Using the results of B. E. Shi, “ Gabor - type filtering in space and time with cellular neural networks” IEEE Transactions on Circuits and Systems - I: Fundamental Theory and Applications,  vol. 45, no. 2, pp. 121-132, Feb 1998 and assuming an infinite array the transfer function of the array is found to be            V        (     ω   x     )         U        (     ω   x     )         =       H        (     ω   x     )       =     1       λ   2     +       α   2          (     2   -     2                 cos                   (       ω   x     -     ω   xo       )         )                     where                   V        (     ω   x     )            (     U        (     ω   x     )       )                   represent                 the                 discrete                 Fourier           transform                 of                 the                 output                   (   input   )                   and                   α   2     =         G     1      x     2     +     G     2      x     2                       λ   2     =       G   0     +     2        G     1      x         -     2        α   x   2                       ω   xo     =     atan        (       G     2      x       /     G     1      x         )                                    
     For small values of λ and ω x  close to ω xo , H(ω x ) is approximately equal to the continuous space filter transfer function,            H   c          (     ω   x     )       =       1       λ   2     +         α   2          (       ω   x     -     ω   xo       )       2         .                            
     Thus the impulse response of the array is a discrete approximation to the continuous space impulse response            h   c          (   x   )       =       1     2                 α                 λ                              -                λ   α               x                      j                   ω   xo        x                                
     which is similar to that of a one dimensional Gabor filter except that the Gaussian modulating function has been replaced by a Lapiacian modulating function. 
     In the above analysis the node voltages v r (m) and v i (m) are taken as the output of the array. However, as an alternative the currents i r (m) and i r (m) from the two transconductance amplifiers  3 , 4  may be taken as the output of the filter array. There are two advantages of doing so. The first is that the output may then be readily available simply by mirroring the output of the two transconductance amplifiers  3 , 4 . The second advantage is that the computation of these currents involves an extra high pass filtering operation which removes constant and slowly varying components of the signal. 
     Defining the complex valued current output of the pixel to be i(m)=i r (m)+ji i (m) this is related to the nodal voltage output by 
     
       
           i ( m )= jG   2x ( v ( m− 1)− v ( m+ 1))  
       
     
     Noting that G 2x =α 2 sinω xo  it can be found that the transfer function from the input current to the output current is            I        (     ω   x     )         U        (     ω   x     )         =       2                   α   2        sin                   ω   xo        sin                   ω   x           λ   2     +       α   2          (     2   -     2                 cos                   (       ω   x     -     ω   xo       )         )                                  
     The differencing operation applied by the transconductance amplifiers is a discrete space approximation to differentiation. Since the filtering is linear, the operation of the array may be considered as filtering a high-pass filtered version of the input via the impulse response h c (x). 
     FIG. 2 illustrates the circuit architecture for one pixel (m,n) of a two dimensional array of M×N elements. Starting from the top of FIG.  2  and going clockwise around the figure, pixel (m,n) is connected to adjacent pixels (m, n+1), (m+1, n), (m, n−1), and (m−1, n). each pixel receives an input current u(m,n) from a photosensitive element of any desired type. It will be seen that the architecture comprises first and second resistive arrays  10 , 11  extending in the M direction of the array, ie towards pixels (m−1, n) and (m+1, n), and third and fourth resistive arrays,  12 , 13  extending in the N direction of the array. Transconductance amplifiers  14 , 15  connect arrays  10 , 11  and transconductance amplifiers  16 , 17  connect arrays  12 , 13 . There are two common nodes  18 , 19 . Node  18  is the junction of arrays  10  and  12  and the outputs of transconductance amplifiers  14  and  16  connect to this node. Node  19  is the junction of arrays  11  and  13  and the outputs of transconductance amplifiers  15  and  17  connect to this node. In FIG. 2 resistive elements are labeled by their conductances and the transconductance amplifiers are labeled by their gains. 
     The architecture of the embodiment of FIG. 2 implements the differential equation                    t                       v        (     m   ,   n     )         =         ∑     k   ,     l   =     -   r         t            a     k   ,   l            v        (       m   +   k     ,     n   +   l       )           +     bu        (     m   ,   n     )                   Where              [           a       -   1     ,   1             a     0   ,   1             a       -   1     ,   1                 a       -   1     ,   0             a     0   ,   0             a     1   ,   0                 a       -   1     ,     -   1               a     0   ,     -   1               a     1   ,     -   1               ]     =     [         0           G     1      y       -     jG     2      y             0               G     1      x       +     jG     2      x               -     (       2        G     1      x         +     2        G     1      y         +     G   0       )               G     1      x       -     jG     2      x                 0           G     1      y       +     jG     2      y             0         ]                            
     The transfer function from input current to nodal voltage is given by          H        (       ω   x     ,     ω   y       )       =     1             λ   2     +       α   x   2          (     2   -     2                 cos                   (       ω   x     -     ω   xo       )         )       +                 α   y   2          (     2   -     2                 cos                   (       ω   y     -     ω   yo       )         )                     Where                   α   x   2     =         G     1      x     2     +     G     2      x     2           ,                  α   y   2     =         G     1      y     2     +     G     2      y     2                           ω   xo     =     atan        (       G     2      x       /     G     1      x         )         ,                  ω   yo     =     atan                   (       G     2      y       /     G     1      y         )                   and                     λ   2     =       G   0     +     2        G     1      x         +     2        G     1      y         -     2                   α   x   2       -     2          α   y   2     .                                      
     The filter is tuned to two dimensional frequencies (ω xo , ω yo ) corresponding to a spatial frequency magnitude of Ω={square root over (ω xo   2 +L +ω yo   2 +L )} and orientation θ=atan(ω xo /ω yo ). The values λ/α x  and λ/α y  are approximately equal to the half 6 dB bandwidth of the filter in the x and y directions. Because the x and y bandwidth must be the same for the shape of the filter impulse response to be independent of orientation, it can be assumed that α=α x =α y . 
     As with the one dimensional embodiment described above the output can be taken as the nodal voltages of the array, however it is advantageous to take the output as the current outputs of the transconductance amplifiers. If i r (m,n) is the sum of the output currents of the transconductance amplifiers driving node v r (m,n), then the complex valued current i(m,n)=i r (m,n)+ji i (m,n) satisfies 
     
       
           i ( m,n )= jG   2x ( v ( m− 1, n )− v ( m+ 1, n ))+ jG   2y ( v ( m,n− 1)− v ( m,n+ 1))  
       
     
     The transfer function from input to output current can be approximated by the continuous space transfer function            I        (       ω   x     ,     ω   y       )         U        (       ω   x     ,     ω   y       )         =       j                 2                     α   2          (         ω   xo          ω   x       +       ω   yo          ω   y         )             λ   2     +       α   2          (         (       ω   x     -     ω   xo       )     2     +       (       ω   y     -     ω   yo       )     2       )                                  
     Thus the filtering operation performed by the transconductance amplifiers approximates the directional derivative in the direction of the tune orientation θ and this enhances the orientation of the array. 
     A major advantage of the array of the present invention is that it is readily steerable and scalable, that is to say that it can be tuned to a particular orientation and to a particular scale. Furthermore this tuning can be done by appropriate selection of the resistances and the gains of the transconductance amplifiers as will now be explained. 
     The relative half bandwidth of the filter may be defined as        Δ   =     λ     α                 Ω                              
     If this half bandwidth is kept constant, then the inverse of the tuned spatial frequency magnitude α=Ω −1  becomes a scale parameter. Given desired values of Ω, θ and Δ it is possible to choose resistance and transconductance gains that result in the corresponding filter. 
     If G 2(max)  is the maximum value of G 2  dictated by the circuit design, for given Ω, θand Δ 
     1. α 2 =G 2(max) {square root over (1+L +cot 2 +L Ω)} 
     2. G 1x =α 2 cos(Ωcosθ) G 2x =α 2 sin(Ωcosθ) G 1y =α 2 cos(Ωsinθ) G 2y =α 2 sin(Ωsinθ) 
     3. G 0 =α 2 [(ΔΩ) 2 +4−2cos(Ωcosθ)−2cos(Ωsinθ)] 
     Thus it can be seen that the interconnections between the cells and the values of the resistances and transconductance gains of the array determine the spatial frequency magnitude (ie the scale) the orientation of the filter. As long as the desired spatial frequency is less than π/2 all orientations can be achieved using positive resistances. spatial frequencies greater than π/2 correspond to spatial periods smaller than 4 pixels and are thus more likely to be higher then are required in practice. In order to achieve all orientations both positive and negative gains of the transconductance amplifiers are necessary. However, a negative transconductance gain is easier to obtain than a negative resistance. The relative bandwidth Δ is determined by the resistance G 0  from each node to ground. For all spatial frequency magnitudes and for all orientations, any relative bandwidth Δ can be achieved using a positive value for G 0 . 
     It is possible to vary the spatial frequency magnitude from Ω min  to Ω max &lt;π/2, the orientation from −π to π and the relative bandwidth from Δ min  to Δ max  by varying the resistances and transconductance gains between the following ranges: 
     −G 2(max) ≦G 2x , G 2y ≦G 2(max)    
     G 2(max) cotΩ max ≦G 1x , G 1y ≦α 2 max 
     G 0(min) ≦G 0 ≦G 0(max)    
     Where 
     
       
         α min   2   =G   2(max) {square root over (1++L cot  2 +L Ω max +L )} 
       
     
     
       
         α max   2   =G   2(max) {square root over (1+L +cot  2 +L Ω min +L )} 
       
     
     
       
         {i G 0(min) +L =α max   2 +L ((Δ min +L Ω min +L ) 2 +2−2 +L cos Ω min +L )  
       
     
     
       
           G   0(max) +L =α min   2 +L {(Δ max +L Ω max +L ) 2 +4−4 +L cos ( 2   {square root}{square root over (2)} Ω max )} 
       
     
     The maximum gain of the transconductance amplifiers can be chosen arbitrarily. One of the advantages of the present invention can be shown by considering the limits on G 0 . The lower limit can be considered first. For fixed Ω, G 0  is minimised for orientations θ=k(π/2) and Δ=Δ min : 
     
       
           G   0 =α 2 {(Δ min Ω) 2 +2−2 cos Ω} 
       
     
     As Ω decreases G 0  decreases due to the decrease in the terms in the brackets, but this decrease is partially offset by an increase in α 2  which in turn is due to the fact that the spatial frequency is being decreased by increasing the resistances of the resistive array rather than by decreasing the transconductance gains. 
     To consider the upper limit, for fixed Ω, G 0  is maximised for orientations θ=(2k+1)(π/4) and Δ=Δ max : 
     
       
           G   0 =α 2 {(Δ max Ω) 2 +4−4 cos ( 2   {square root over (2)} Ω)} 
       
     
     As Ω increases G 0  increases due to the terms in the brackets, but this increase is partially offset by a decrease in α 2 . Thus the range over which G 0  must be adjusted is decreased. 
     The required orientations of the filter determine the constraints on the transconductance amplifiers. In some applications it may not be necessary to steer the filter over the entire range −π to π since the orientations θ and θ+π are essentially equivalent. Allowing the filter to be steered over only 0 to π relaxes the constraint on G 2y  to 0≦G 2y ≦G 2(max) . Other applications may require only a few orientations, such as horizontal and vertical orientations and this can further relax the requirements on the transconductance amplifiers. 
     A practical implementation of the present invention has been made as a 25×25 pixel array using the 1.2 μm AMI CMOS n-well process available through MOSIS. Each pixel and its associated processing circuitry occupies an area of 146×129 μm. The total size, including pads, is 4.4×4.4 mm. The chip requires a supply of ±2.5V. The circuits are implemented using transistors operating above threshold. 
     Input to the chip is supplied via on-chip phototransistors. The photocurrents are mirrored into a common node which computes the average of the currents in the entire array. The average current is then subtracted from each pixel&#39;s current to give the input to the array. 
     The tuned orientation is limited to horizontal and vertical which relaxes the design requirements on the transconductance amplifiers as explained above. The transconductance amplifiers are implemented using 5 transistor NMOS differential pairs loaded by PMOS current mirrors. The measured value of G 2(max)  is 8 μA/V. The gains are selected by switching the bias currents on or off. Resistances G 0 , G 1x  and G 1y  are implemented using CMOS transmission gates. The resistances are tunable by adjusting the gate voltages of the NMOS and PMOS transistors. The conductances can be varied over the following ranges with a linear range of ±300 mV: 
     2.5 μA/V≦G 0 ≦9 μA/V 
     7 μA/V≦G 1x , G 1y ≦28 μA/V 
     This corresponds to a spatial frequency range between 0.29 and 0.85 radians, ie spatial periods from 7.4 to 22 pixels. The relative half bandwidth can vary from 0.26 to 0.47. 
     Output from the array is obtained by mirroring the photocurrents and the outputs of the transconductance amplifiers. The currents, corresponding to the photosensor, even filter and odd filter outputs are switched via switches controlled by D flip flops onto three read-out lines which are held at virtual ground. On-chip transimpedance amplifiers convert the currents to voltages for output. 
     To test the spatial filtering of this embodiment of the invention, a light spot was focussed onto the center of the chip using a 4 mm lends and the outputs scanned off. The fixed pattern noise, measured with no light incident on the chip, was subtracted from the output in a digital postprocessing step. In FIGS. 3 to  6  the intensity levels have been normalised so that neutral Grey corresponds to zero and black and white correspond to the same absolute value. FIGS. 3 and 4 show the response of the chip when tuned to horizontal and vertical orientations. The difference in responses of the chip when tuned to the same orientation but different scales can be observed by comparing FIGS. 4 and 5. The difference is clearer when examining the even filter outputs, the odd filter outputs appear similar because the directional derivative performed by the transconductance amplifiers and the rapid decay of the modulating function at the origin cause the odd impulse response to obtain its peak positive and negative values near to the origin. 
     Although the sensor of this embodiment was not designed to enhance orientations other than vertical and horizontal, by setting G 2x =G 2y  45° orientation selectivity can be obtained. 
     FIGS.  7 ( a )-( l ) show the results from a 45×45 pixel array tuned to orientation θ=π/3 (FIGS.  7 ( a ) &amp; ( b )), π/6 (FIGS.  7 ( c ) &amp; ( d )), 0 (FIGS.  7 ( e ) &amp; ( f )), −π/6 (FIGS.  7 ( g ) &amp; ( h )), −π/3 (FIGS.  7 ( i ) &amp; ( j )) and −π/2 (FIGS.  7 ( k ) &amp; ( l )). The chip can be tuned to orientations between −π and π, but results are only shown here for a set of orientations between −π/2 and π/2 since the responses for orientations between θ+π is the same as that for θ except for a change of sign in the odd part. 
     The present invention can be applied to a one dimensional array which may have applications in the field of image tracking and alignment and of course also to a two-dimensional array. A two-dimensional array may be arranged in a rectangular grid as described above, but that is not the only possibility. For example another possible arrangement would be a hexagonal array in which each pixel was provided with six nearest neighbours (as opposed to four in a rectangular array). FIG. 8 schematically illustrates such as array and in this possibility the resistive networks would extend in three directions rather than two as in a rectangular array. 
     In the embodiments described above the current sources are voltage controlled current sources in the form of transconductance amplifiers. However, another possibility is to use current controlled current sources. In the voltage controlled embodiments described above transistor circuits are used operating above threshold. While this results in a very fast circuit, it also requires a relatively large power consumption. Where applications do not require extremely fast frame rates, it is possible to read off speed for reduced power consumption. 
     One way of achieving this is to use sub-threshold operating transistors, eg MOS transistors as the resistive elements in the first and second resistive networks and then to use current controlled current sources in place of the transconductance amplifiers connecting the networks. FIGS.  9 ( a ) and ( b ) illustrate how the resistive elements in the network may be replaced by the transistor network. FIG.  9 ( a ) shows a part of a resistive network and FIG.  9 ( b ) shows how the same network part may be implemented using MOS transistors and keeping the same relationships between the currents. 
     By replacing the resistive elements with transistor elements (which act as pseudo-conductance elements) a one-dimensional array is shown in FIG. 10 which illustrates the circuits associated with two pixels and their neighbours in a current mode implementation of the present invention. In this embodiment the voltage controlled current sources (ie the transconductance amplifiers) connecting the networks are replaced by current controlled current sources in the form of current amplifiers as shown in FIG.  11 . The input currents to the current amplifiers are supplied directly from the drains of the corresponding transistors M v  and the gain of the amplifier is controlled by the difference between the voltages V s1  and V s2 . Raising V s2  decreases the gain. 
     It will thus be seen that the present invention can provide a circuit architecture, especially a two dimensional circuit architecture, for orientation selective Gabor-type filtering consisting of two resistive networks coupled by voltage controlled current sources such as transconductance amplifiers (when operated in a voltage mode), or interconnected by current controlled current sources (when operated in a current mode). The orientation and scale of the filter can be adjusted by appropriate selection of the resistance and transconductance values. By means of time multiplexing one chip can compute the outputs of filters tuned to different scales and orientations. 
     The architecture of the present invention overcomes a number of disadvantages of the prior art. In particular the architecture can achieve all bandwidths for all spatial frequencies between 0 and π/2. By eliminating resistance connecting the resistive arrays, there is no need to match the resistances to the gains of the transconductance amplifiers. Furthermore since both negative and positive gains of the voltage/current controlled sources can be implemented all orientations can be achieved.