Digital Electronics and Analog Photonics for Convolutional Neural Networks (DEAP-CNNs)
Paper · 2019 · Viraj Bangari, Bicky A. Marquez, Heidi B. Miller et al.
Summary
A convolutional neural network can look for the same feature across an image by moving a small filter from place to place. At each position it multiplies the values under the filter by their corresponding weights, then adds the products. Repeating that calculation across positions, channels and filters makes convolution a major part of the processing workload. The authors propose DEAP, short for Digital Electronic and Analog Photonic, to carry out this part of the computation with light while keeping the network connected to digital memory and electronic control.
In DEAP, different wavelengths carry different values from an image patch. A bank of tunable silicon microring resonators weights the light at each wavelength. A pair of photodetectors produces a difference signal so that a filter can assign either positive or negative weights. The design performs this operation separately for each input channel and adds the resulting electrical signals to obtain a single output value. To process the next patch, the system changes the inputs and keeps the filter settings. Several copies of the convolutional unit can work on different outputs at the same time.
The authors trained a handwriting classifier offline and used its learned parameters in a software simulation of the architecture. On a test set of 500 MNIST images, the simulated DEAP classifier reached 98% overall accuracy with microring control represented at 7-bit precision. A standard CNN with max pooling reached 98.6% overall accuracy in the comparison. The DEAP classifier used average pooling followed by offline downsampling. The simulation represented the optical transfer functions and the amplification stage, with analog noise and distortion outside its scope.
A separate analysis used component specifications to estimate convolution runtimes and compared them with measured GPU runtimes from DeepBench. With two convolutional units, the authors project a speed advantage of 2.8 to 14 times relative to the mean GPU runtime across the selected workloads. Their power budget also puts the proposed configuration below the reported mean GPU power. The rate assumed for each unit is set by the converters that move signals between the digital and analog parts of the system. The paper thus gives a way to map trained filters onto photonic hardware, a simulated classification result and a conditional performance estimate. Measuring all three aspects together would require an integrated implementation.
Deep dive: Digital Electronics and Analog Photonics for Convolutional Neural Networks (DEAP-CNNs)
DEAP-CNNs proposes a hybrid processor that uses light for convolution and evaluates its accuracy on MNIST and its projected speed against GPUs. · about 39 minutes to read
The problem and its context
Why convolution is a hardware problem
The useful property of an image filter is that it can be applied wherever the feature of interest might appear. A filter can respond to a local pattern, and sweeping it across an image gives a map of where that pattern elicits a response. The same arrangement also creates a large amount of repeated work. The weight values stay fixed during the sweep, but at each new position they must be paired with another set of inputs. When patches overlap, some image values participate in successive calculations, each time under a different part of the filter.
The workload grows in several directions. A convolution can use an input with several channels, so an output value depends on a patch from every channel. It can also apply many filters, each producing its own output map. A later layer can take those maps as its channels and repeat the process. The paper cites earlier work in which convolution accounted for 86% to 94% of CNN execution time. That reported range motivates focusing on the operation during forward propagation, the process of carrying an input through already trained layers to produce an output.
The conventional approach described by the authors organizes the repeated calculations so that graphics processors can carry out many operations in parallel. A set of image patches can be written as a matrix, with a separate column for each position. A filter can be flattened into a row. Multiplying that row by the patch matrix then gives the filter's response at every position. Additional filter rows extend the same representation to multiple output maps. This is the calculation against which the proposed optical approach should be understood. GPU & parallel computing
Flattening a patch reveals an opportunity because a convolutional output is a dot product. Its calculation requires a collection of input values, a corresponding collection of weights and a way to add their products. Digital processors use arithmetic units arranged to execute such operations efficiently. In the photonic approach, the question is whether the powers of light at several wavelengths can represent the input values, whether optical devices can apply the weights and whether a detector can combine the contributions. The choice of physical representation then determines which parts of the arithmetic can happen together.
The proposed accelerator also reflects the distinction between learning a filter and using it. During training, filter values are adjusted in response to errors. During inference, when the network classifies an input using trained parameters, the same filter is applied repeatedly. DEAP takes advantage of this stability. It can hold a photonic weight bank at a fixed setting while digital circuitry supplies successive patches. Training and back-propagation remain outside the proposed photonic computation.
What earlier optical approaches offered
The authors place DEAP alongside three lines of photonic research. In the reservoir-computing systems they describe, a physical network supplies a set of internal responses for information processing. The hidden connections in the examples use predetermined random weights. Those connections can be valuable for fast processing, but the CNN mapping considered here requires the ability to load prescribed filter weights. The paper therefore looks to optical devices whose response can be programmed.
Mach–Zehnder interferometers offer another way to realize weighted connections. The authors also discuss a broadcast-and-weight approach based on tunable microring resonators. In that approach, signals share a waveguide, a structure that guides light along the chip. Each signal occupies a different wavelength. A weight bank selects how strongly the incoming signals contribute to an output, making a shared optical path compatible with individually adjustable weights.
The paper points to earlier demonstrations of several properties of broadcast-and-weight circuits. They include fan-in, the ability to bring multiple inputs together, and inhibition, the ability to give some inputs a negative effect. The authors also cite time-resolved processing and the ability to feed a photonic neuron's output back to itself. These precedents concern physical operations the architecture can draw on. DEAP applies the underlying approach to a specific arrangement of spatial patches, input channels and convolutional filters.
The authors present silicon photonics as a platform compatible with established complementary metal–oxide–semiconductor fabrication, abbreviated CMOS. That connection matters to their design because convolution requires more than a path for light. The circuit needs electronic controls to tune rings, amplifiers to read out their combined response and converters to communicate with memory. The proposal relies on integration between these functions and the optical weight banks.
A photonic CNN proposal by Mehrabian and colleagues supplies a more direct starting point. As the paper describes it, that design considered dynamic memory, buffers and microring resonators as parts of a possible accelerator. DEAP goes into the representation of the operands and the mapping of a handwriting classifier. Its questions are concrete. Which input value goes on which wavelength? How can a ring provide a signed weight when an optical power is non-negative? Where do the channel sums happen, and which parts of a filter fit into a given hardware configuration?
These questions set the scope of the contribution. The authors begin with an ordinary trained network, so the challenge is to preserve the intended forward computation while changing how its convolutional part is executed. They also want to know where a hardware speed advantage might come from once the optical core must receive fresh values and deliver its results to digital electronics. The architecture, the classifier simulation and the component analysis address different parts of that question.
The method, step by step
From an image patch to a dot product
Imagine placing a small filter over part of a digit image. Each entry in the filter is lined up with an image value. The two entries at each position are multiplied and all of the products contribute to one output. Moving the filter changes which image values are used. A bright pixel can make a positive or a negative contribution, depending on the weight at its relative position in the filter. The response therefore describes a pattern within the patch, rather than brightness alone.
The paper starts with the discrete convolution of two functions.
(f ∗ g)[t] = ∑[τ = −∞ to ∞] f[τ] g[t − τ]
The functions being combined are f and g, and ∗ denotes convolution. The index t selects the output position and τ indexes the terms in the sum. The bounds −∞ and ∞ describe a sum over all discrete input positions. The argument t − τ expresses the reversal and shift of the weighting function in this definition. As t changes, the entries of g are aligned with different entries of f.
The paper then illustrates the image calculation with a direct sum over the patch.
Oᵢⱼ = ∑[k = 1 to R] ∑[l = 1 to R] Fₖₗ Aᵢ₊ₖ,ⱼ₊ₗ
Oᵢⱼ is the output at spatial indices i and j. Fₖₗ is the filter entry at relative row k and column l, and Aᵢ₊ₖ,ⱼ₊ₗ is the corresponding input entry in image A. The edge length of the square filter is R, so both relative indices range from 1 through R. The hardware follows this pairing of entries in the filter and patch as they are loaded. The same operation can be written with vectors.
Oᵢⱼ = vec(F)ᵀ · vec(A_patch)
Oᵢⱼ again denotes the response at output row i and column j. F is the filter, and A_patch is the region of image A used to compute that response. vec puts the entries of its argument into a vector, ᵀ transposes the filter vector into a row, and · denotes the dot product. The flattening order can be chosen so long as it matches across the two operands. The implementation must preserve that match when it assigns values to wavelengths and tunes the corresponding rings.
For a CNN, both the patch and the filter include a channel index. A layer receiving earlier feature maps can use each map as a distinct input channel. A given output filter has its own weights for the patch in each of those channels. The channel contributions are added, yielding one spatial output for that filter. Applying several different filters produces several output channels.
Oᵢⱼ = vec(F)ᵀ · vec(A_patch(iS, jS; R, D))
Oᵢⱼ, F, vec, ᵀ and · have the same roles as in the image dot product, with F now extending through all input channels. A_patch(iS, jS; R, D) denotes the window taken from input A at the offsets given by iS and jS. i and j index the output grid, S is the stride or distance between successive window positions, R is the filter edge length, and D is the number of input channels. The spatial window has edge length R in each channel. Writing the equation for one filter keeps the output filter index implicit.
Padding adds zeros around the input before the window is moved. With unit stride and an unpadded input, the valid spatial positions occupy a smaller grid than the input whenever the filter is wider than a single entry. The paper gives the following general output dimensions.
⌈(H − R)/S⌉ + 1 by ⌈(W − R)/S⌉ + 1 by K
H and W are input height and width including any padding. R and S are the filter edge length and stride, and K is the number of filters. ⌈ ⌉ is the ceiling operation, which rounds upward, and 1 adds the initial position to each spatial count. The ceiling convention as printed needs care for strides that leave a remainder. The pseudocode advances through positions for which the full window fits, which gives a different last position in that case. The MNIST walkthrough uses stride one and is unaffected by that ambiguity.
Separating the patch geometry from the arithmetic leads directly to the division of labor in DEAP. Digital control selects a window and orders its values for transfer. Optical and electrical components implement the weighted sum for that window. The output can then return to digital storage, where its location and filter identity are tracked for the next stage.
How DEAP computes a convolutional output
The steps in order.
How a ring puts an input value onto light
A microring resonator is a circular waveguide coupled to a nearby straight guide. Some of the light travelling along the straight guide enters the ring. It circulates and recombines with light in the guide. The phase it accumulates around the ring determines how the contributions interfere and how much power emerges at the output. This dependence on phase gives the circuit a way to vary the transmitted power of a carrier without changing the number the carrier's wavelength identifies.
The all-pass arrangement has a single straight guide coupled to the ring. For that arrangement the paper gives an expression for the transmitted fraction at the through port.
Tₙ(φ) = (a² − 2ra cos(φ) + r²) / (1 − 2ra cos(φ) + (ar)²)
Tₙ(φ) is the ratio of output to input optical intensity for the all-pass device at phase φ. r is the self-coupling coefficient and a is the factor the paper uses to represent propagation loss in the ring and coupler. cos is the cosine function. The constants 1 and 2 and the squared terms describe the interference relationship in the transfer function. For a fixed device, the equation tells the designer how the fraction changes as the ring phase changes.
φ = 4π² d nₑff / λ
φ is the phase accumulated around the ring, d is its radius, nₑff is the effective refractive index and λ is the wavelength of the light. π is the circle constant. The factor 4π² comes from expressing the optical phase over a circular path. At a chosen wavelength, a shift in the effective refractive index changes the phase. DEAP uses current to heat the ring and shift its optical response, making a digital input value something the control circuitry can translate into an analog setting.
The input encoder seeks a phase that gives the desired normalized power. The inverse expression in the paper can be written with common input indexing as follows.
φᵢ = arccos((Aᵢ(1 + (ar)²) − a² − r²) / (2ra(1 − Aᵢ)))
φᵢ is the requested ring phase for input value Aᵢ, where i identifies the value and its carrier. a and r are the loss and coupling factors, ar is their product, and arccos returns an angle from a cosine value. The constants 1 and 2 arise from inverting the intensity transfer. The sign in this printed form is inconsistent with directly solving the stated all-pass transfer on the same phase convention. The operational condition for encoding is the power relation below. A ring setting has to satisfy that relation within the device's usable range.
Iₘₒd = Tₙ(φᵢ) |E₀|² = Aᵢ
Iₘₒd is the modulated optical intensity, Tₙ(φᵢ) is the all-pass transmission at the chosen phase, and |E₀|² is the squared magnitude of the incident electric-field amplitude E₀. Aᵢ is the desired encoded value, expressed on the intensity scale of the design. The equality presupposes the appropriate normalization. The physical variable representing the input is the output power on the carrier, while the phase is an internal control variable used to obtain that power.
Using a different wavelength for each position lets these encoded powers share a line. The paper describes this as wavelength-division multiplexing, or WDM. A carrier's wavelength identifies the position it represents. Its optical power carries the current value at that position. The weight bank must maintain the same correspondence. When the digital input window advances, the encoded power at a position may change, but the weight bank can still recognize the position by its wavelength.
How the weight bank gives contributions a sign
Multiplying by a weight requires a second optical operation. The proposal uses add–drop microrings in the weight bank. Each ring sits between two guides, so light can be observed at a through port and a drop port. Tuning the ring changes how incident power is distributed across those outputs. The paper gives the following transfer functions for the two ports.
Tₚ(φ) = ((ar)² − 2r² cos(φ) + r²) / (1 − 2r² cos(φ) + (r²a)²)
Tₚ(φ) is the through-port intensity fraction at phase φ. r and a again denote the self-coupling and loss factors, and cos denotes cosine. The constants 1 and 2 and the powers belong to the printed add–drop transfer function. The through port reports the light that remains on the path from the input guide.
T_d(φ) = (1 − r)² a / (1 − 2r² cos(φ) + (r²a)²)
T_d(φ) is the drop-port intensity fraction. φ, r, a and cos have the same meanings as in the through-port expression. Here d in the label T_d stands for drop, while d in the earlier phase equation represented ring radius. The numerator depends on coupling and loss. The denominator depends on those factors and on the phase around the ring.
To obtain a signed contribution, the weight bank sends the two outputs to a balanced photodiode. A photodiode converts received optical power to electrical current. A balanced pair takes the difference of currents associated with the two optical paths. Which path contributes positively depends on the wiring convention. A transimpedance amplifier, or TIA, converts and scales the resulting current for electrical readout. The paper describes the signed response using a gain multiplied by the difference of the through and drop functions. For a convention that assigns positive polarity to the drop path, the relationship is written below.
Iₘₒd = g(T_d(φᵢ) − Tₚ(φᵢ)) |E₀|²
Iₘₒd here denotes the amplified difference response. g is the electronic gain, T_d(φᵢ) and Tₚ(φᵢ) are the two port fractions at the ring phase for carrier i, and |E₀|² is the incident optical intensity. Reversing the pair reverses the sign. The paper's discussion shifts polarity conventions and one displayed expression uses the all-pass symbol in the port difference. The dot-product construction calls for comparing the two outputs of the add–drop device. Its essential property is that either side can contribute more photocurrent than the other.
This is how the circuit gets a negative number from non-negative optical powers. For instance, tuning a ring so that more of one carrier reaches the negatively wired detector makes that carrier's contribution negative. A change in the encoded input power then scales the magnitude of that contribution. A near balance between the two outputs gives a small effective weight. The comparison of powers and the encoding of inputs are separate operations, which allows a fixed filter to act on a changing sequence of patches.
The multiplexed dot product
The derivation treats the value on each carrier as a slowly changing power envelope. The envelope changes on a much slower time scale than the underlying optical oscillation. The paper represents the resulting signal in the frequency domain as a collection of components centered at the carrier frequencies.
Eₘᵤₓ(ω) = ∑[i = 1 to k] E₀ √(μᵢ) δ(ω − ωᵢ)
Eₘᵤₓ(ω) is the multiplexed field as a function of angular frequency ω. i labels each carrier, k is the number of carriers and ωᵢ is the angular frequency of carrier i. E₀ is the common incident field amplitude and μᵢ is a non-negative power envelope. Its square root √(μᵢ) scales the field amplitude. δ is the Dirac delta, used here to mark the frequency of a carrier. Under attenuation-only encoding, the paper restricts μᵢ to the interval from 0 to 1.
The two paths of the weight bank act like tunable optical filters on that collection of carriers.
E_w⁻(ω) = H⁻(ω) Eₘᵤₓ(ω)
E_w⁻(ω) is the weighted field destined for the negative detector input. H⁻(ω) is the field transfer function for that path, and Eₘᵤₓ(ω) is the field entering the weight bank at angular frequency ω. The superscript − labels the path according to detector polarity.
E_w⁺(ω) = H⁺(ω) Eₘᵤₓ(ω)
E_w⁺(ω) is the weighted field for the positive detector input. H⁺(ω) is the corresponding field transfer function. Eₘᵤₓ(ω) and ω again denote the incoming field and angular frequency. The superscript + identifies the other detector input. Taking squared magnitudes gives the intensity fractions relevant to photodetection.
The following form makes explicit the intensity difference used in the photodetection argument. It uses the two port fields and the detector's frequency response.
i_PD = ∫[−∞ to ∞] ℛ(ω)(|E_w⁺(ω)|² − |E_w⁻(ω)|²) dω
i_PD is the photocurrent from balanced detection and ℛ(ω) is the detector's spectral responsivity, which relates received power to current at angular frequency ω. |E_w⁺(ω)|² and |E_w⁻(ω)|² are the positive- and negative-path spectral power terms. The integral ∫ adds their responsivity-weighted difference over the spectrum, with dω denoting the frequency integration element. The subscripts and superscripts distinguish the detector and its two inputs. In the paper's discrete-carrier argument, the power contributions are evaluated at the carrier frequencies.
The derivation then assumes that the detector's responsivity varies little across the chosen band. With the responsivity and common carrier power absorbed into the scale of the encoded inputs, it gives the following dot product.
i_PD = ∑[i = 1 to k] Aᵢ Fᵢ* = A · F*
i_PD remains the detector current, Aᵢ is the input value assigned to carrier i after scaling and Fᵢ* is the normalized optical weight on that carrier. The star marks the normalized weight. A and F* are the vectors formed from those elements, k is the number of terms, and · is their dot product. Here the multiplication of input by weight is realized by attenuation and subtraction at each wavelength, while photodetection combines the contributions over the wavelength band.
The normalized weight is the difference between the two port fractions. In the near-lossless argument, the two ports share the incident power, so the drop-positive choice gives the simplified weight below.
Fᵢ* = 2T_d(φᵢ) − 1
Fᵢ* is the normalized weight for carrier i, T_d(φᵢ) is its drop-port fraction and φᵢ is the setting of the ring that weights it. The constants 2 and 1 turn the drop fraction into the difference of complementary fractions. A drop fraction between 0 and 1 corresponds to a signed weight between −1 and 1 in this approximation. The paper's intervening prose gives a port identity in a different sign order. The simplified weight equation expresses the complementary-power interpretation used for the dot product.
In practice, programming a weight means finding a phase that gives the required drop fraction. The paper also prints an inverse phase expression for that purpose.
φᵢ = arccos((2(1 − r)²a/(Fᵢ* + 1) − 1 − (r²a)²) / (2r²a))
φᵢ is the programmed phase for the normalized target Fᵢ*. r is self-coupling, a is the loss factor, arccos is inverse cosine, and 1 and 2 are the constants in the printed inverse. As written, the inverse and the stated drop-port formula are algebraically inconsistent. The programming condition conveyed by the derivation is to tune the drop fraction to the value specified by the normalized-weight equation. The choice of a physically attainable phase and the calibration relating a heater current to that phase are implementation issues.
Extending the range of weights and inputs
Learned kernel coefficients can have magnitudes greater than the normalized optical range. The proposed solution is to factor out a common scale. A weight bank uses normalized values for the relative strengths of the contributions. The electrical amplifier then restores their scale after the sum. The authors choose the largest absolute coefficient as the scale.
g_TIA = max[1 ≤ i ≤ k] |Fᵢ|
g_TIA is the gain assigned to the TIA, Fᵢ is the desired unnormalized coefficient at position i, and k is the number of coefficients in the dot product. max takes the largest value over the stated indices and |Fᵢ| is the absolute magnitude of the coefficient. Using this shared factor keeps the normalized magnitudes within the optical range for a non-zero weight vector.
F = g_TIA F*
F is the desired weight vector, F* is the vector represented optically, and g_TIA is the common electronic scale. Each optical coefficient therefore represents its original weight relative to the gain. The scheme preserves signs and relative sizes before readout.
A · F = g_TIA ∑[i = 1 to k] Aᵢ Fᵢ*
A is the input vector and F is the desired weight vector. · denotes the dot product. g_TIA scales the detector sum, Aᵢ is its input on carrier i, and Fᵢ* is the normalized optical weight for that carrier. k is the number of input–weight pairs. Applying the gain after summing works because every normalized coefficient was obtained using the same scale.
Providing signed weights still leaves a separate question about signed inputs. Optical power cannot itself represent a negative number under the input convention used so far. The paper sketches an extension that shifts the input before encoding.
μᵢ = (xᵢ + 1)/2
xᵢ is a signed input at position i in the interval from −1 to 1, and μᵢ is its non-negative power envelope. Adding 1 shifts the interval and dividing by 2 scales it to the allowed envelope range. This puts an optical offset on each carrier even when the intended input is zero.
The resulting response has a term from the signed inputs and a term from the common offset. In the following notation, the envelope's common scaling is included in the readout gain.
y_encoded = g(∑[i = 1 to k] Aᵢ Fᵢ* + B ∑[i = 1 to k] Fᵢ*)
y_encoded is the readout before offset correction, g is the shared gain, Aᵢ is the signed input component on the detector's scale and Fᵢ* is the normalized weight. B is the common offset on that same scale, set by the incident carrier power and the assumed constant detector responsivity. i labels the carrier and k counts the terms. The second sum depends on the programmed weights and is therefore predictable while the filter stays fixed. The paper proposes subtracting that bias current and identifies the additional circuitry and loss of input precision as tradeoffs.
The distinction between signed weights and signed inputs matters to the demonstration. A handwriting image can supply non-negative input intensities, and rectification after a convolution can supply non-negative activations for the next stage. The filters themselves can still use both signs. The balanced readout is therefore central to the classifier mapping, while the signed-input extension enlarges the intended range of uses.
From a weight bank to a convolutional unit
A weight bank operates on the wavelengths associated with one input channel. To build a complete convolutional unit, DEAP begins with a set of lasers at unique wavelengths. The wavelengths are combined on one guide, and the resulting signal is split into separate lines for the different channels. After the split, a given wavelength represents the same relative spatial position on every line. Its power can vary independently on each line because the image or feature value at that position can differ across channels.
Number of carrier wavelengths = Rₘ²
Rₘ is the largest supported square filter edge length for the convolutional unit. Its square Rₘ² is the number of spatial positions in that filter, each of which needs a separate carrier on a channel line. Reusing the carrier wavelengths across the separate lines lets the architecture add channels without assigning each channel its own additional set of distinct wavelengths.
Number of input modulators = Dₘ Rₘ²
Dₘ is the maximum number of input channels and Rₘ² is the number of spatial positions per channel at the design limit. Each channel line needs its own all-pass modulator at each of those positions. The two factors give the number of separately encoded powers that can enter the convolutional unit.
Each line also enters a corresponding photonic weight bank programmed with that filter's coefficients for the channel. The electrical output of a bank represents the channel's partial dot product. A passive voltage adder combines those channel contributions into the output of the whole filter at the current patch position. An analog-to-digital converter then puts that output on the digital side of the system. This is the distinction between the dot-product circuit and the convolutional unit. The former combines the carrier contributions for one channel. The latter combines all the channel responses for one spatial output and one filter.
The paper describes how to use a unit below its design limits. For a smaller spatial filter, weights in unused positions are set to zero, removing those positions from the sum. For an input with fewer channels, modulation on unused channel lines is set to zero. The mask for unused positions is part of configuring the filter. The active positions and channels then proceed through the same physical route as they would in a larger convolution.
How the architecture sweeps an image
For a full convolution, the digital side loads a filter into the weight banks and cycles through the image patches. It uses the selected stride to advance along a row and then along the height of the input. Each new patch requires updated inputs for the modulators. The weights remain in place across the sweep. Once that filter's output map is complete, the system can load the next filter and repeat the procedure. The pseudocode locates the output with both a spatial index and a filter index, so the processor can store each result in its proper map.
The memory and converters are part of this path. The paper places digital input values, filter weights and intermediate features in memory connected to a computer. Digital-to-analog converters, or DACs, drive the settings required by the optical chip. An analog-to-digital converter, or ADC, reads the result after the electrical sum. Digitizing the feature map makes it available to later stages, which can apply operations such as rectification before passing values into another convolution.
The design also allows several convolutional units to receive different patches concurrently. Each unit retains the internal wavelength and channel parallelism of the single-output circuit. The additional units expose another source of parallelism across output positions. The paper illustrates this by distributing successive windows between two units. Its approximate runtime complexity for distributing the output calculations is as follows.
O(KHW / (S² n_conv))
O in this expression is order-of-growth notation. K counts filters, H and W are the input spatial dimensions, S is the stride and n_conv is the number of convolutional units. The S² term represents spacing the sampled positions along both dimensions. The division by n_conv expresses the assumed ability to share the output work among units. As a description of the sweep, this counts output calculations without itemizing the cost of loading a new filter, issuing memory transfers or digitizing results.
How the learned classifier is mapped
The network was trained offline on MNIST handwritten digits. The authors name ADAM as the optimizer and back-propagation as the procedure for obtaining gradients. During training, those gradients guide changes to the filter coefficients, dense-layer weights and biases. The photonic architecture receives the resulting parameters for forward computation. The paper releases a DEAP software simulator and mapping tool for representing that process at a high level.
The test walkthrough begins with a 28 × 28 image. The first convolution applies a group of eight 5 × 5 filters with stride one. The result is a 24 × 24 × 8 feature array, to which the network applies a rectified linear unit, or ReLU. A ReLU leaves positive values available and maps negative ones to zero. The second group of filters takes the earlier feature maps as input and yields a 20 × 20 × 8 feature array. The paper describes both groups as 5 × 5 × 8. Its hardware mapping supplies the channel-wise sum needed when a later convolution receives several maps.
Following the second rectification, the implementation uses average pooling. Pooling combines values in a neighborhood to produce an aggregate feature response. The paper represents the local average with a 2 × 2 kernel whose coefficients are all 1/4. With stride one, this produces a 19 × 19 × 8 feature array. The subsequent choice of even-indexed positions happens offline, reducing the array to the reported 10 × 10 × 8 pooled output. This procedure separates local averaging, which can be expressed as convolution, from selection of the output samples.
The pooled array is flattened before it enters the dense classifier. A dense layer combines its inputs with learned weights to produce the next vector. The authors report dimensions of 128 × 800 and 128 × 10 for the two fully connected layers, along with their biases. The first consumes the flattened pooled features. The second turns the resulting representation into the values used for the digit decision. The paper's system diagram places digital storage and control around the optical convolution. The mapping of the complete classification procedure consequently includes both the photonic operations being simulated and steps performed on the digital side.
Experiments and results
Handwritten-digit recognition
The MNIST experiment asks whether the operations available in DEAP can reproduce convolution closely enough for a trained classifier to recognize digits. Its output metric is overall accuracy on a set of 500 test images. Each image yields a digit decision, and overall accuracy records the fraction of correct decisions across the set. The paper also describes the sequence of intermediate feature shapes. Those shapes make the evaluation a check of the mapping through the two convolutional stages, the pooling procedure and the dense classifier, with overall accuracy reported at the end.
The simulator uses the microring transfer functions, the balanced detector calculation and the amplifier gain. It treats the resonator controls as having 7-bit precision, a choice the authors relate to earlier laboratory observations. It sets the self-coupling and loss parameters equal, at r = a = 0.99. In this setup, finite control resolution affects the device settings used to express the desired input powers and filter coefficients. The simulator operates at the level of the transfer functions, so the selected settings are evaluated without adding analog component noise or distortion.
The comparison is a standard CNN with two convolutional layers and max pooling. Max pooling selects the largest value in a local neighborhood. The simulated DEAP configuration instead uses the local average and subsequent offline sample selection described above. The paper reports 98.6% overall accuracy for the standard CNN and 98% for simulated DEAP in the MNIST comparison.
Overall test accuracy on MNIST
Simulated DEAP retains high test accuracy, with the standard CNN scoring higher.
The numbers
| System or setting | accuracy % |
|---|---|
| Standard CNN with max pooling | 98.6 |
| Simulated DEAP CNN with average pooling (this paper) | 98 |
The result shows that the tested classifier can operate successfully under the simulated transfer functions and control resolution. It measures the configured pipeline as a whole. In particular, pooling changes along with the numerical representation of the convolution. The comparison therefore leaves open how much of the accuracy gap comes from finite ring precision, differences in pooling or other details of the two configurations. The authors take the accuracy as evidence that restricted control precision is compatible with this task in their simulator.
An overall score is especially easy to interpret when coupled with the setup. Here the paper tests one handwriting task on a specified set of test images and obtains a final digit classification after all stages. The score confirms that the errors introduced by the simulated convolutional path are tolerable for that particular classification pipeline. It leaves the size and distribution of intermediate convolution errors undetermined. A classifier can preserve its final decision even when individual feature values change, so the classification result and the numerical fidelity of individual convolutions answer different questions.
Estimating the power of a convolutional unit
The second part of the evaluation estimates power from component counts and per-device specifications. The size of a unit depends on both the spatial footprint of a filter and the number of input channels. A wider filter occupies more wavelengths per line and needs more tunable elements for each channel. A deeper input requires more lines and more weight banks. The authors use a limit of 100 wavelengths and a fabrication assumption of 1024 microrings for the modulator array when discussing the physical envelope of a unit.
The power budget combines the lasers, tunable rings, input converters, output amplifiers and output conversion. The paper uses 100 mW per laser, 19. Each ADC uses 76 mW, each TIA uses 17 mW, each DAC uses 26 mW, and each microring uses 5 mW. The calculation assigns counts to these devices using the dimensions of the selected convolution. Weight banks have a separate readout for each input channel, while the result after channel addition uses a common output converter. This layout couples the power estimate to the choice of spatial footprint and channel depth, even before the authors consider replicating a whole unit.
The two configurations used in the budget are a larger square filter at R = 10, D = 12 and a smaller one at R = 3, D = 113. Here R measures filter edge length and D counts channels. The paper reports 112 W for the larger filter configuration and 95 W for the smaller one and characterizes a unit as using around 100 W. These figures are power estimates because their unit is watts. The larger filter configuration also conflicts with the stated modulator limit when the paper's count rule is applied. Its estimate describes the budget as reported, with compatibility under that bound unresolved.
For the DeepBench discussion, the authors use about 110 W as the power of a single DEAP unit. They report mean GPU power of 295 W for the compared devices. The GPU figures are listed power specifications associated with the devices in the comparison. The DEAP figure is a component-based estimate. The chart uses the figures specific to the DeepBench comparison.
Power figures used in the DeepBench convolution comparison
The component budget for one DEAP unit is below the listed mean GPU power.
The numbers
| System or setting | W |
|---|---|
| Mean of the compared DeepBench GPUs | 295 |
| DEAP with a single convolutional unit (this paper) | 110 |
The paper also expresses single- and dual-unit consumption relative to the mean GPU figure, using the terminology of energy consumption. It reports 0.37 times for one unit and almost 0.75 times for two. The underlying figures discussed alongside those ratios are powers. Energy for a completed convolution would depend on both the power drawn during that operation and its duration. The distinction matters in interpreting the claim because the GPUs and DEAP have different reported runtimes, and the evaluation does not include a measurement of energy per workload.
From component speeds to a convolution runtime
The authors first estimate how long light takes to cross the optical path leading to the balanced detectors. Their expression approximates the path in terms of the number and circumference of the microrings.
t_prop = k 2πr_MRR / c
t_prop is the propagation time, k is the number of microrings in the path, r_MRR is the radius of a ring and c is the speed of light used in the estimate. π is the circle constant and 2πr_MRR is a ring circumference. The paper gives about 21 ps as the propagation time for a bank with 100 rings and about 50 GS/s for the corresponding reciprocal rate. These are estimates for the optical path, before the full chain of detection, amplification and conversion is considered.
The component analysis gives a balanced-photodiode rate of 25 GS/s and a TIA rate of 10 GS/s. The paper cites 128 GS/s for modulation of an individual microring and gives around 5 GS/s for the photonic weight bank. These figures describe different parts of the signal path. The fact that light traverses the rings quickly leaves other components responsible for delivering, reading and recording successive results. A fast ring or a short propagation delay on its own cannot determine how often the combined system delivers a digital output.
The paper assumes that both the DACs and the ADCs operate at 5 GS/s and support 7-bit precision. It specifies GDDR6 memory at 16 G with a 256-bit bus. Based on its component assumptions, the analysis assigns the unit a rate of 5 GS/s, corresponding to the reported 200 ps interval between convolutional outputs. The calculation treats this as a sustained output interval for the purpose of the benchmark. Feeding fresh patches and writing outputs at that rate depends on the memory and control path operating as assumed.
The runtime expression multiplies the interval for one output by a count based on the images, filters and spatial positions, then divides the work among the units.
t_runtime = 200 ps × (NK/n_conv) × ((H − R)/S + 1) × ((W − R)/S + 1)
t_runtime is the estimated convolution runtime. 200 ps is the reported interval per output for one unit, N is the number of images, K is the number of filters and n_conv counts convolutional units. H and W are the input height and width, R is the square filter edge length and S is the stride. Each 1 includes the starting window in its dimension. For workloads with rectangular filters, the paper identifies separate height and width values, Rₕ and R_w, for the corresponding factors. The runtime expression uses output geometry to estimate work and leaves discrete boundary handling to the mapping of the individual workload.
Comparison with DeepBench GPU timings
DeepBench supplies empirical timings for convolutions on GPUs. The paper selects workloads that differ in input geometry, channel count, batch size, filter count and stride. This comparison is distinct from running the complete MNIST classifier. Each workload specifies a convolution, and the authors compare the time required for that operation with the time predicted by the DEAP formula.
One workload has input width 700, height 161, depth 1 and 4 images. It uses 32 filters of width 5 and height 20, with stride 2. The rectangular filter illustrates why the benchmark admits separate edge lengths even though the architectural derivation starts with square windows. Mapping a rectangle onto the available wavelengths calls for a consistent assignment of its spatial positions to carrier slots. The timing analysis treats the workload as compatible with the relevant device budget.
Another workload uses a 112 × 112 input with 64 channels, 8 images and 128 filters. Each filter has a 3 × 3 spatial footprint and the stride is 1. The architecture would use the carrier set for the local spatial positions on each active channel line. The number of output filters then determines how many filter sweeps the runtime expression must account for. This workload emphasizes both channel aggregation within each output and repetition across outputs.
The remaining workload has 7 × 7 spatial input dimensions, 832 channels, 16 images and 256 filters. Its filters are 1 × 1 and the stride is 1. In this case, the dot product at each position chiefly combines values along the channel dimension. The three workloads therefore exercise different uses of the same proposed unit. The benchmark's applicability rests on the availability of a configuration that meets the relevant carrier and ring limits for each workload.
The GPU comparison covers the NVIDIA Tesla P100, AMD MI25, NVIDIA GTX 1080 Ti and AMD Vega FE. The authors take the GPU runtimes from DeepBench and calculate the DEAP runtimes. They plot the per-workload comparison with one and two DEAP units. According to their account, the configuration with two units gives lower estimated runtimes than the compared GPU timings. The results can be read as comparisons between a hardware projection and empirical GPU observations for the selected operations.
Against the mean GPU runtime, the paper reports a speed range of 1.4 to 7.0 times for a single unit across the selected convolutions. For two units it reports 2.8 to 14 times. The two-unit improvement follows from dividing the output workload between the units in the runtime expression. The speed range across workloads reflects the benchmark comparison, which places a DEAP estimate beside GPU timings for each convolution. Its endpoints describe variation across those workloads, rather than variation observed across repeated runs of an integrated DEAP processor.
The results consequently address two separate propositions. The simulator shows that a trained classifier can use transfer-function convolution at the selected precision and obtain the reported accuracy on MNIST. The runtime analysis shows what a set of convolutional units could achieve under the stated component rates and scheduling assumptions. Neither the elapsed time of the classification pipeline nor its measured energy is quantified by these two results together.
What the ablations show
The paper reports no formal ablation of the classifier or circuit, and instead offers comparisons of pooling and implementation configurations, component-rate analyses and projections for different numbers of convolutional units.
What the accuracy comparison tests
The standard CNN and the simulated DEAP CNN differ in the way features are pooled as well as in the way convolutions are represented. The standard network uses max pooling. The DEAP network performs a local average and then subsamples the result offline. The DEAP simulation also imposes the selected control resolution and uses device transfer functions. Overall accuracy at the end of this comparison answers whether the combination is sufficient for the test. It cannot assign any observed change to a specific stage.
The precision setting has particular importance because the authors cite 7-bit control as a practical constraint. The result gives a point on the space of possible implementations. It shows how the tested pipeline performs at that setting. The paper does not sweep the precision, report per-layer sensitivity or compare the same pooling procedure under different arithmetic conditions. Consequently, its experiment establishes feasibility at a reported setting while leaving the accuracy dependence on individual control choices unresolved.
The average-pooling mapping is itself an architectural analysis. Expressing averaging as a filter lets the convolutional machinery implement the local combination. Choosing the samples offline then gives the reduced output grid. This shows how a familiar layer can be composed from the available linear operation and digital control. Its inclusion in the classification run gives an example of working composition, though the experiment does not separately measure the contribution of that pooling choice to recognition accuracy or time.
What the single-unit and dual-unit estimates test
The comparison between one unit and two changes a parameter in the performance calculation and leaves the per-unit output interval fixed. It shows how much work can be distributed if each copy services its own stream of patches at the assumed rate. The parallelism here comes from computing distinct outputs concurrently. Within each unit, the wavelength and channel organization is the same as in the single-unit architecture.
The power budget also grows when a full unit is replicated. Under the paper's assumptions, the larger configuration gets its lower runtime by providing additional processing resources and a correspondingly larger power allocation. The calculation exposes the trade between throughput and the number of instantiated units. Because the arithmetic assumes continued service at the same rate per unit, it does not measure how much memory bandwidth and control capacity an additional physical unit would actually receive.
The power examples probe a different hardware choice. One configuration gives more of the ring allocation to spatial positions and the other gives more to channels. That difference changes the balance among lasers, input modulators and weight banks. The comparison illustrates why power for a convolutional unit cannot be inferred from edge length alone. It is a budget for different shapes of computation, subject to the unresolved consistency of the large configuration with the stated ring limit.
What the component analysis locates
The path from an input value in memory to a stored convolutional result includes several operations with different quoted rates. The rings modulate and weight carriers, the balanced photodiode reads the power difference, the amplifier produces an electrical readout, and the converters communicate with the digital side. By examining those rates in sequence, the authors identify the electronic interfaces as the practical limit in their estimate. The assigned unit rate follows the converter specifications rather than the propagation delay alone.
This analysis helps locate the conditions behind the projected advantage. A change to the fast optical path would have limited effect while the same digital interface cap remained in force. Conversely, replacing a slower interface with a faster one would shift attention to whichever stage then sets the output interval. These are consequences of the component budget. The paper has no integrated timing experiment that independently identifies the limiting stage under sustained operation.
The authors also illustrate how tuning a ring redistributes contributions between the two detector paths, and how amplifier gain scales the resulting response. Those plots address whether the proposed circuit can express both signs of a filter coefficient and use electrical gain to extend the scale. They explain individual operations that the simulation relies on. The evidence for the classifier still comes from the combined forward pass, with no component-by-component accuracy attribution.
Limitations
Limits identified by the authors
The paper restricts the hardware proposal to forward propagation. Training was performed offline, and the optimized parameters were then used by the simulator. The optical design addresses loading weights and evaluating weighted sums. It leaves the gradients, optimization and repeated weight updates of training to the electronic training procedure. Its performance estimate is therefore a claim about convolution during inference.
The authors describe the MNIST simulator as a transfer-level implementation. Photonic components introduce shot noise, spectral noise, Johnson–Nyquist noise and flicker noise, while conversion adds quantization effects and the electrical drive to a modulator can cause distortion. The simulation includes a finite control resolution but does not include those analog disturbances. How close the distribution of outputs on a physical chip would be to the simulated distribution is an open part of the implementation.
The paper observes that earlier research found cases where adding random noise during neural-network training reduced overfitting. That observation supports the possibility that a classifier can tolerate some variability. It supplies no measurement of tolerance to the particular disturbances, amplitudes or correlations that DEAP would encounter during inference. The authors also contrast the demonstrated 7-bit microring control with half-precision floating point, whose representation uses 16 bits. They treat greater photonic precision as an important development for widening the design's usefulness.
The interface between a silicon photonic chip and an electronic chip presents a packaging challenge, especially with a large number of connections. The authors also identify the need for circuitry to direct values from memory to the relevant DACs and return digitized results from the ADCs to memory. They assume that this control can operate quickly enough to have little influence on throughput. This assumption supports their projected output rate. The paper states that the routing circuitry still needs to be realized for a physical implementation.
The converter rates are another explicit limit. The authors suggest that photonic converters with sufficiently high precision could help raise throughput. That possibility remains a conditional design direction in the paper. Its benchmark calculation uses the electronic conversion rates and precision reported in the component analysis.
Limits of the evidence and calculation
The classification evidence is concentrated in one small CNN on the MNIST test set of 500 images. The experiment reports overall accuracy from that test. It does not provide a distribution over repeated runs, an assessment on a different image dataset or results for a deeper classifier. The tested network also uses non-negative activations after its rectifiers. The signed-input extension, with its proposed offset correction, therefore does not receive a separate end-to-end evaluation here.
The reported accuracy comparison gives no clean estimate of the price of finite precision. The reference CNN and the simulated architecture use different pooling procedures, and the paper does not supply a matched comparison in which the same learned classifier and pooling pipeline are kept fixed while just the convolutional implementation changes. Likewise, it reports no layer-level error measurements that would show where deviations first arise or how strongly later layers amplify them. The final accuracy is an empirical property of the simulated pipeline under the authors' selected conditions.
The timing comparison has a separate boundary. The DEAP side counts convolutional outputs and assigns a fixed interval to each. The GPU side comes from measured convolution runtimes. Time spent loading filter settings, staging patches, converting intermediate features and performing digital operations such as rectification and pooling is outside the stated convolution timing expression or absorbed into its throughput assumptions. The paper leaves open how the projected rate would translate into a complete inference time once those operations share physical resources.
Resource limits also need interpretation before the proposed benchmark mapping can be treated as a single hardware configuration. The architecture is initially described with a square spatial bound. A benchmark uses a rectangular filter with a height beyond the discussion's stated square edge bound. The paper treats compatibility through counts of available spatial positions and channels, while the original square formulation bounds an edge length. The association between carrier slots and rectangular positions helps explain the intended mapping. A fully specified implementation would still need to establish which shapes a fabricated unit can load.
A related issue appears in the component budget. Applying the stated modulator count to the larger square-filter case conflicts with the stated maximum of 1024 modulators. The reported budget for that case can be recorded as an estimate, while its use as an allowable extreme of the design envelope remains unsupported by the count rule. These geometry and count issues matter independently of the idea of summing channel responses in parallel. They affect which workload fits and how many components a fit requires.
Some of the derivation likewise needs a consistent convention before it can specify circuit settings. The architecture's sign mechanism is the difference between the add–drop port powers, but the paper reverses their order in parts of the description and prints inverse-phase relations that do not follow directly from its forward transfer expressions. The dot-product explanation can be understood from the intended transfer and the balanced readout. The exact setting for a physical ring would have to be checked against the device response and chosen detector polarity.
Finally, the power and runtime comparisons involve different kinds of evidence. Power on the DEAP side comes from summing component specifications, and its runtime comes from an assumed sustained rate. The observed runtimes belong to the GPUs in DeepBench. Though the authors describe relative consumption using energy language, the stated comparison uses watt figures and does not measure energy spent on a completed DEAP convolution. The paper therefore supports a prospective comparison whose applicability depends on the power, throughput and integration assumptions being realized together.
What came after
The paper's forward-looking direction was to integrate and test the full path from digital memory through the optical convolution and back to stored results. Its proposal leaves a concrete distinction between showing that a balanced photonic circuit can represent trained weights and showing how fast a complete system can keep such a circuit supplied with data. Greater precision and faster conversion are the component improvements the authors identify, alongside the packaging and control work needed to bring the system together.
No later citing work is documented here, so there is no supported account of which subsequent systems adopted the DEAP mapping or tested its performance projections.
Cite
Cite as Viraj Bangari, Bicky A. Marquez, Heidi B. Miller, Alexander N. Tait, Mitchell A. Nahmias, Thomas Ferreira de Lima, Hsuan-Tung Peng, Paul R. Prucnal and Bhavin J. Shastri. 2019. Digital Electronics and Analog Photonics for Convolutional Neural Networks (DEAP-CNNs). arXiv:1907.01525.
@misc{bangari2019digital,
title = {{Digital Electronics and Analog Photonics for Convolutional Neural Networks (DEAP-CNNs)}},
author = {Viraj Bangari, Bicky A. Marquez, Heidi B. Miller, Alexander N. Tait, Mitchell A. Nahmias, Thomas Ferreira {de Lima}, Hsuan-Tung Peng, Paul R. Prucnal and Bhavin J. Shastri},
year = {2019},
doi = {10.1109/jstqe.2019.2945540},
eprint = {1907.01525},
archivePrefix = {arXiv},
url = {https://doi.org/10.1109/jstqe.2019.2945540}
}This page in Markdown https://md.research.elamur.ai/free/en/papers/bangari-2019-digital-electronics-analog-photonics-convolutional/