Structure of the model network. Each circle stands for a population of neurons with similar receptive fields and response properties. Magenta, blue, and orange lines represent feedforward excitatory, lateral inhibitory, and feedback excitatory projections, respectively. Edges and other local features of a figure (black dashed parallelogram) activate edge cells (E) whose receptive fields are shown by green ellipses. Edge cells project to border ownership cells (B) that have the same preferred orientation and retinotopic position as the E cells they receive input from. However, for each location and preferred orientation there are two B cell populations with opposite side-of-figure preferences, in the example shown BL whose neurons respond preferentially when the foreground object is to the left of their receptive fields and BR whose members prefer the foreground to the right side of their receptive fields. E cells also excite other E cells with the same preferred orientation (connections not shown), as well as a class of inhibitory cells (IE) which, in turn, inhibit E cells of all preferred orientations at a given location. Only E cells of one preferred orientation are shown. B cells have reciprocal, forward excitatory and feedback modulatory connections with two types of grouping cells, Gc and Go, which integrate global context information about contours and objects, respectively. E cells receive positive (enhancing) modulatory feedback from these same grouping cells. Opposing border ownership cells compete directly via IB cells and indirectly via grouping cells, which bias their activity and thus generate the response differences of opposing border ownership selective neurons. G cell populations also directly excite inhibitory grouping cells (IG; again with the indices L and R), which inhibit Gc cells nonspecifically and Go cells in all orientations except the preferred one. Top-down attention is modeled as input to the grouping cells and can therefore either be directed towards objects (solid lines) or contours (dashed lines) in the visual field (top).