Extreme Illuminated Vision Processing with a Graded Alloyed Perovskite In-sensor Computing Network

Domain: neuroscience
Published: 2026-04-10
Editorial outcome: minor_revision

Abstract
In-sensor computing is proposed to reduce energy expenditure and processing latency by unifying sensing and computation within the hardware layer, yet the application under extreme illuminating scenario remains constrained by simultaneously obtaining broadband responsivity, large linear dynamic range and fast response. Here, we report a fully vapor-deposited graded Pb-Sn alloyed perovskite heterojunction photodiode with improved crystal quality. It enables the detection of light from visible to infrared light with a 230 dB linear dynamic range and 33 ns response time. We also develop a wafer-scale imaging processor by integrating the photodiode to a reconfigurable array. With this approach, we demonstrate biomedical detection and spatiotemporal trajectory encoding. The in-sensor processor realizes low-power high-resolution visible to infrared wavelength edge detection, adaptive background suppression under dim light and noise-immune high-speed dynamic imaging. Our results extend the options for in-sensor computing hardware, and thus pave a way toward practical artificial intelligent machine vision.

Introduction
Traditional machine vision systems isolate sensing and processing units, incurring substantial energy consumption and latency from data transfer between image sensors and backend processors. This bottleneck hinders real-time applications in edge computing and artificial intelligence1,2. In-sensor or near-sensor computing addresses this by enabling pixel-level preprocessing before data transmission, necessitating in-situ reconfigurable photoresponsivity3,4. Recent advances leverage novel device architectures, including electrical doping5, ion migration6, ferroelectric effect7, float gating mechanism8, to dynamic reconfigure photoresponsivity. These approaches have demonstrated functionalities critical to machine vision, such as objection recognition9, motion perception5,10, high-speed data processing11, spectral extraction12, and in-sensor data compression13.

Practical application of in-sensor computing technology in machine vision, particularly for extreme illuminated conditions, however, remains a significant challenge, requiring the operation of photodiode with high speed, large dynamic range and extended wavelength12,14,15. Firstly, imaging under dim light or noisy environment is demanded yet difficult for a large number of important application context. Dealing with both weak and strong illuminated regions in a same image calls for sensors with a large linear dynamic range (LDR). Unfortunately, the LDR in most sensors is limited to no more than 150 dB, although a few work reported higher LDR by sacrificing the imaging speed16,17. Secondly, a neuromorphic visual system, such as for autonomous vehicles and robotics, needs to capture dynamic images. As a fundamental prerequisite, photodiode must have the operation speed down to nano-second level. However, response time is always compromised by power efficiency or detecting sensitivity. And finally, it is also necessary to expand the response to ultraviolet or infrared light, to capture information unavailable in the visible spectrum. For example, biomedical imaging is often operated at the infrared range.

Organic-inorganic hybrid perovskites, with high absorption coefficients and long carrier diffusion lengths, show great promise for optoelectronics. Recent advances have demonstrated the fabrication of thin film photodetector with better performance than crystalline Si18–21. Tin alloying narrows the bandgap and extends spectral responsivity into the near-infrared (NIR) while reducing lead base perovskite toxicity22,23. However, oxidation of Sn2+ to Sn4+ induces self p-doping and deep traps, elevating dark current and noise as well as undermining stability24. Even though sophisticated 2D/3D heterojunctions can partially suppress Sn2+ oxidation, the intrinsically low conductivity of 2D perovskites (~10−5 S cm−1) limits the photo-response efficiency25,26. Accordingly, realizing scalable, high quality, monolithically integratable perovskite units for practical in-sensor computing has remained as an open challenge.

Here, we introduce a gradient composition engineering strategy that provides a protective layer for oxidation suppression of Sn2+. By this approach, we fabricate stable lead-tin (Pb-Sn) alloyed perovskite films via fully vapor-deposition process. And based on these advancements, we demonstrate a scalable broadband bipolar programmable perovskite unit (BPPU). The core device comprises two sets of back-to-back cascaded perovskite photodiodes. This architecture enables rapid, stable, and precise control of photoresponse purely through circuit‑level biasing, avoiding trade‑offs in hysteresis, speed, or reliability. The uniform vapor-phase deposition ensures symmetric bipolar response tuning under low bias (±200 mV), fast response time of 33.0/37.4 ns and a large LDR of 230 dB. By integrating the BPPU into wafer-scale arrays, we achieve diverse in-sensor computing function such as adaptive background suppression, biomedical sensing and spatiotemporal trajectory encoding.

Results
Design of Pb-Sn perovskite graded heterojunction photodiode
A fully vapor-deposition process is used for sequential layer-by-layer stacking of functional layers, which meets the requirements for future scalable, CMOS compatible and high-precision fabrication. The resulting device architecture is a vertical stacks of FTO/Spiro-TTB/perovskite/C60/BCP/Ag (Fig. 1a).

High-quality Pb-Sn alloyed perovskite graded heterojunction is fabricated using a synergistic strategy combining compositional engineering and self-encapsulation as shown in Fig. 1b: First, co-evaporate SnI2 and PbI2 to form a homogeneous (SnI2:PbI2) mixing layer. Second, keep depositing PbI2 while shutting off the SnI2 source to deposit a thin pure PbI2 capping layer, forming a (SnI2:PbI2)/PbI2 heterojunction. The PbI2 capping layer acts as an encapsulation layer for the underlying SnI2. Finally, reacting the (SnI2:PbI2)/PbI2 heterojunction with vaporized methylamine iodide (MAI) at 180°C that converts it into MAPbxSn1-xI3/MAPbI3 perovskite thin film. Subsequent annealing, activate thermal diffusion promotes the crystallization and establishes a Pb-Sn ratio gradient across the film.

The effectiveness of the component engineering by the top PbI2 layer is supported by X-ray diffraction (XRD), optical absorption, and emission shifting in Supplementary Fig. 1 & Supplementary Fig. 2. Scanning electron microscopy (SEM) analysis verifies PbI2 capping profoundly optimizes perovskite thin film morphology (Supplementary Fig. 3). While homogeneous structure perovskite films show a porous morphology with pinhole defects (Fig. 1c), introducing an 80 nm PbI2 capping layer on Pb-Sn alloyed precursor films yields dense perovskite grains with reduced inter crystalline voids (Fig. 1d). This microstructural densification decreases effectively suppressing leakage currents from 8.5×10−6 A to 5.6×10−8 A at −0.5 V bias for the device (Supplementary Fig. 4).

Effective prevention of Sn2+ oxidation in the graded structure is supported by the time evolution of photoluminescence (PL) (Fig. 1e-f, Supplementary Fig. 5). In homogeneous perovskite structure, the primary PL peak at 923 nm (Pb-Sn alloyed perovskite phase) suffers 50% intensity loss within 200 s (79% within 750 s), accompanied by an anomalous 702 nm emission peak emerging after 200 s—a signature of photoinduced Sn2+ oxidation forming MA2SnI6 phases27,28. In stark contrast, the sample pre-covered 80 nm PbI2 maintains >91% PL intensity of Pb-Sn alloyed perovskite over 750 s without secondary peak formation, demonstrating exceptional photostability. The effective encapsulation and protection of Sn2+ oxidation was further confirmed through femtosecond laser ablation XPS depth profiling of the aged samples (Supplementary Fig. 6). In devices characterization, devices based on the pre-covered 80 nm PbI2 layer show improved operational stability than the homogeneous control sample, with on-off switching characteristics remaining virtually unchanged after long-term continuous operation exceeding 700 hours (Supplementary Fig. 7) and demonstrating remarkable photostability even under strong light irradiation (Supplementary Fig. 8).

To verify the formation of compositional and band-structure gradient in the perovskite film, in-depth X-ray photoelectron spectroscopy (XPS) analysis is first employed, revealing Sn:Pb ratio evolves gradually from 0.05:0.95 at the surface to 0.4:0.6 in the bulk (Supplementary Fig. 9). Ultraviolet photoelectron spectroscopy (UPS) measurement in Supplementary Fig. 10 is then employed to reveal the band structure, giving detail band alignment in Fig. 1g. It shows a type-II heterojunction between the Pb-Sn alloy region with band gap around 1.33 eV and Pb-rich surface layer with band gap around 1.50 eV. This continuous gradient results in a progressive spatial tilting of both the conduction band minimum (CBM) and valence band maximum (VBM) across the entire active layer, effectively generating a built-in electric field. The Mott-Schottky analysis in Supplementary Fig. 11 further reveals an enhancement of built-in potential from 0.58 V in homogeneous film to 0.66 V in the gradient film. This built-in field actively drives photo-generated electrons towards the lead-rich region (orange arrow) and holes towards the tin-rich region (blue arrow) via directional drift, thereby transitioning carrier transport from diffusion-dominated to efficient drift-dominated. As a result, acceleration of charge separation and transport, substantially shortening carrier transit and residence time within the active layer can be expected. The observation of faster rise and fall times in the photoresponse of the graded heterojunction (Supplementary Fig. 12) provides evidence for the improved carrier transport kinetics.

The thickness of pre-covered PbI2 layer (Δ𝑑 = 20–110 nm) is a critical parameter for the compromise of device operational stability, carrier transport efficiency, and NIR sensitivity. The 80 nm PbI2 pre-covered layer provides an optimized NIR response. When the PbI2 thickness exceeds 80 nm, Pb-Sn balanced region which serves as the primary infrared absorber, is too short to preserve photo-response beyond 850 nm. This attenuation is directly evidenced by a 33% responsivity decrease at 850 nm in Δ𝑑 = 110 nm devices (0.28 A W−1 versus 0.42 A W−1 for 80 nm devices, Supplementary Fig. 13). Conversely, sub-80-nm pre-covered layers fail to adequately suppress oxidation-induced degradation, leading to deteriorated response. With the optimized structure, the gradient Pb-Sn alloyed perovskite film achieves a zero-bias external quantum efficiency (EQE) of 61.07% at 850 nm (Fig. 1h). This wavelength is crucial for NIR applications such as vein imaging that rely on the characteristic absorption of hemoglobin in the 760–850 nm spectral range. Although the PbI2 coating weakens the device’s short-wave infrared response above 850 nm, the high sensitivity maintained within the key spectral window fully meets the physical requirements of the targeted biomedical applications. This structure simultaneously satisfies essential intelligent vision system requirements including multi-wavelength adaptability, environmental stability, and rapid response capabilities.

Bipolar photoresponse perovskite in-sensor computing unit
In a machine vision system, the convolution of input optical signals and weights relies on a programmable photoresponse characteristics. As shown in the Fig. 2a, the designed BPPU integrates two vertically stacked photodiodes comprised of shared functional layer but adjacent electrically-isolated Ag electrodes. Detailed photocurrent-voltage characteristic of BPPU is shown in Supplementary Fig. 14. Fig. 2b shows the typical bias-dependent bipolar photoresponse that is understood by the equivalent circuit in the inset. Under uniform illumination intensity P, the photocurrent of BPPU is described by 𝐼total = 𝐼D1 + 𝐼D2. This relationship is verified by the photoresponse characteristic of individual photodiode by separately illuminating each diode. It’s found that the photodiode D1 contributed to the positive photoresponse and D2 contribute to the negative photoresponse. Fig. 2c maps the reconfigurable photoresponse as a function of incident power across a 400 mV window (−200 to +200 mV). The net responsivity can be continuously tuned from negative to positive. This enables optoelectronic analog multiplication and accumulation (MAC) for in-sensor computing applications (see below). Notably, the low operating voltage indicates the device is operated with ultra-low power consumption.

Building upon this back-to-back cascading configuration, leakage currents are self-cancelled as shown in Supplementary Fig. 15, suppressing the noise current to 7.44×10−14 A Hz−0.5 under 1 Hz as shown in Fig. 2d. The photodiode exhibits exceptional 230 dB LDR from 4.75 pW cm−2 to 1.50 W cm−2 under 860 nm in the BPPU at zero bias (Fig. 2e, Supplementary Fig. 16). Our device demonstrates competitive advantages over recently reported broadband (visible–NIR) photodetectors, as detailed in Supplementary Table 1. The BPPU achieves ultrafast bipolar photoresponse speed of 33.0 ns rise time and 37.4 ns fall time (Fig. 2f). It results from the cascaded architecture. The back-to-back connected diodes’ equivalent capacitance (𝐶eq = 𝐶1𝐶2 / (𝐶1+𝐶2)) reduces by 50% compared to single-photodiode configurations. The comparative data in Supplementary Fig. 17 provides direct experimental validation for this capacitance reduction effect.

This design establishes a new architecture for in-sensor computing devices, simultaneously addressing the longstanding trade-off between detection speed, sensitivity and power consumption in conventional photonic systems. Remarkably, our device accomplishes adjustable photo-response with an unprecedentedly low programming voltage of ±0.2 V – a figure significantly lower than state-of-the-art bipolar programmable photodetectors (Supplementary Table 2). The 230 dB dynamic range allows unified processing of vision with both low-light and high-flux parts without any gain switching/adapting. It overcomes the critical bottleneck of saturation-induced feature loss in existing neuromorphic vision sensors.

In-sensor computing core
Under zero bias, the BPPU readily functions as a computing kernel for hardware-level background (BG) suppression as demonstrated in Fig. 2g. The photocurrent fluctuations are constrained within <12.5 nA despite global BG illumination increasing from dark to 19.1 mW cm−2. This stability arises from responsivity cancellation (𝑅1 = −𝑅2) between neighboring diodes (D1 & D2 in Fig. 2b). It creates a hardware differential connection that effectively subtract the common-mode BG. But the total current is still able to sensitively response to locally illuminated signals. For example, a moving light spot induces negative (positive) signal when it goes through D1 (D2) zones. Our measurements suggest under dark BG, the array can resolve motion signal as dim as 146 pW (Fig. 2h). Even under a 42.18 mW intense BG illumination, a target signal down to 530 nW can be still successfully extracted from the strong BG (Fig. 2i), which corresponds to an interference level 98 dB stronger than the target signal. This robust performance is corroborated by the dynamic range measurements under strong background illumination (Supplementary Fig. 18). The BPPU achieves sub-microsecond fast BG suppression by directly performing analog photocurrent subtraction within the sensor hardware. This ability is not only promising for high-contrast scenes, but also bypassing conventional analog-to-digital conversion and digital signal processing. It definitely saves power and prevents precision loss. It is important to note that the excellent background suppression of the BPPU relies on uniform illumination across its two sub-pixels. In practical scenarios, spatial gradients or local shadows in back ground illumination may reduce the suppression efficiency and introduce low-frequency spatial artifacts. These effects can be mitigated by subsequent signal processing or system-level calibration strategies.

To further demonstrate the in-sensor computing capabilities, we also designed an extended BPPU array by integrating two fundamental units through a shared Ag current output terminal, as illustrated in Fig. 3a. Fig. 3b shows the equivalent circuit of this enhanced design. It provides independent bias terminals (𝑉A, 𝑉B) to program the responsivity of two branches and sum the photocurrent at the output terminal. Therefore, it is easy to understand each extended BPPU array serves as a minimum in-pixel MAC core for the input light intensity and weights defined by the bias voltage:
𝐼output = [𝑅(𝑉A),𝑅(𝑉B)] [𝑃A / 𝑃B] (1)

The MAC core can be further scaled up to form convolution kernel. We demonstrated a chip-level implementation of 2×2 and 6×6 extended BPPU arrays on a 4-inch wafer (Fig. 3c). Quantitative verification of film uniformity was achieved by measuring PL peak positions across 17 positions (Fig. 3d, Supplementary Fig. 19), revealing a standard deviation of only 2.21 nm. To further confirm the reliability of our deposition technique, the uniformity and reproducibility of the Sn/Pb gradient structure were assessed via XPS profiling, which shows high consistency over batches (Supplementary Fig. 20). Such exceptional homogeneity ensures high device-to-device consistency (Supplementary Fig. 21). The arrays can be programmed into any matrices for convolution operation. Fig. 3e&f give an instance. Base on the aforementioned reconfigurability, extensibility, and scalability, we next demonstrate the application of BPPU in intelligent vision tasks, from biomedical imaging/processing to real-time motion tracking.

In-sensor imaging processing for biomedical applications
BPPU based biological feature extraction was demonstrated using a home-built galvanometer-based scanner (Supplementary Fig. 22) for acquisition of both surface topography and subsurface vascular structures. For fingerprint biometrics, high-precision epidermal topography is captured under −0.2 V bias. It resolves ridge-valley structures (200–400 μm spacing) and sweat pore distributions (40–100 μm diameter, Fig. 4a). Switching to 0 V bias enables horizontal edge detection, where only the ridge boundaries are resolved as distinct intensity transitions (Fig. 4b) due to the differential output eliminated background signals. As shown in Fig. 4c, this operation manages to suppress nonlinear background variations and enables direct hardware-level extraction of Level 2 biometric features (bifurcations, ridge endings) and Level 3 identifiers (sweat pores)29,30. Notably, the resulting discretized edge map shows a 101% improvement in edge-specific signal-to-noise ratio, alongside 95.5% agreement with conventional digital processing outputs and higher contrast compared to conventional Sobel or Laplacian digital filters (Supplementary Fig. 23).

We also extended this in-sensor edge processing paradigm to deeper-tissue diagnostics through NIR absorption contrast. Hemoglobin in veins exhibits stronger absorption of NIR illumination than the surrounding tissues, such as skin and subcutaneous fat. NIR is thus very suitable for veins imaging. However, post-image processing techniques such as contrast-limited adaptive histogram equalization and multi-scale filtering are required to address the weak contrast between the vein and surroundings tissue31–33. As shown in Fig. 4d, a photograph of a hand is provided with an inset highlighting the specific region used for imaging (Fig. 4e&f). A transmission image acquired using conventional imaging mode shows a high-intensity signal is detected between the fingers, while minimal venous detail is discernible (Fig. 4e), demonstrating the significant dynamic range challenge in conventional subcutaneous imaging. In contrast, under edge detection mode (Fig. 4f), the vein edges are clearly resolved due to abrupt transitions in hemoglobin concentration at vessel boundaries. This approach significantly enhances vein-to-tissue contrast, enabling clear visualization of vessels through differential absorption.

The device advantages for achieving this high quality image are two-fold. The intrinsically high LDR together with the differential architecture accommodate high-intensity background illumination from gap between fingers with tissue scattering and weak additive absorption signals from hemoglobin. Conventional photodetectors would otherwise saturate under high surface background intensity or lose vein-specific absorption variations in quantization noise. Consequently, the BPPU enables direct extraction of venous boundaries from raw NIR matrices without dynamic range compression. Notably, in contrast to conventional imaging with separate post-computation, our in-sensor computing approach operates at 0 V, approaching nearly zero-power data processing. Furthermore, the bipolar response characteristics of the extended BPPU array, in principle, allow it to be programmed to perform arbitrary two-dimensional linear convolution operations, effectively functioning as a versatile image processing kernel for various in-sensor computational imaging effects.

Beyond static in-sensor imaging application, the BPPU architecture also enables dynamic physiological monitoring through time-resolved differential sensing. Pulse wave velocity (PWV) is a critical parameter for assessing arterial stiffness, which has been linked to various cardiovascular diseases34. Traditional PWV (𝑣) measurement requires multiple sensors and complex signal processing to analyze the time delay between pulse waves at different measurement sites35–37. However, this out- and multi-sensor data processing can be simplified by utilizing BPPU in-sensor computing. Here, we verify it through the local measurement of the fingers.

Fig. 4g schematically shows the in-sensor procession the photoplethysmographic (PPG) signal of when NIR light passes through tissues. The spatial separation (𝐷 = 2.5 mm) between the two sub-photodiodes introduces a small time lag (∆𝑇 = 𝐷/𝑣, typically < 0.5 ms for 𝑣 > 5 m s−1) in the pulse wave arriving times. This results in phase-shifted PPG signals (𝑃(𝑡) and 𝑃(𝑡−∆𝑇)) with distinct temporal characteristics. The BPPU computes the differential-delay current as 𝐼diff(𝑡) = 𝐼1(𝑡)−𝐼2(𝑡) = 𝛼[𝑃(𝑡)−𝑃(𝑡−∆𝑇)], where 𝛼 is the optoelectrical related coefficient. Since the ∆𝑇is significantly shorter than the PPG pulse wave’s characteristic timescale, the peak differential current at the maximum pulse slope ((d𝑃/d𝑡)max) is approximated by first-order Taylor expansion:
𝐼diff,max ≈ 𝛼(d𝑃/d𝑡)max ∙∆𝑇 = 𝛼(d𝑃/d𝑡)max ∙ (𝐷/𝑣) (2)

This yields the fundamental relationship of peak magnitude (𝐼diff,max) and PWV:
𝑣 = 𝑘 / 𝐼diff,max (3)

where the calibration constant 𝑘 = 𝛼 ∙𝐷(d𝑃/d𝑡)max incorporates optoelectronic and individual hemodynamic parameters. As experimentally confirmed in Fig. 4h, this inverse proportionality enables the direct translation of differential current peaks into PWV values. Fig. 4i demonstrates synchronized decreasing trends in both BPPU-derived normalized PWV and heart rate during post-exercise recovery. Physiological validation of our measurements is established through covariation with heart rate, which exhibits known correlation with PWV dynamics. Detailed signal processing is provided in Supplementary Fig. 24. Our approach thus enables efficient PWV monitoring through simple differential current measurement, offering a practical alternative to conventional multi-sensor systems.

Robust motion trajectory recognition
Finally, we use a dynamic spatiotemporal pattern recognition task to explore the potential of BPPU for intelligent vision. The task involves to identify the motion trajectory mode (32 kinds of distinct trajectories shown in Fig. 5a) of a specific target. The BPPU was scaled up to a 6×6 array. The trajectory-specific time-domain signals are generated via a convolution operation: 𝐼output(𝑡) = ∑𝑁𝑖=1 𝑅𝑖 𝜙𝑖(𝑡), where 𝑅 denotes the programmable responsivity of the 𝑖-th pixel (Fig. 3f, right), 𝜙 represents the time-dependent incident optical signal, and 𝑁 = 36 corresponds to the 6×6 array configuration. It enables the extended BPPU array directly encodes the moving objects’ spatiotemporal signatures into discriminative neuromorphic information. Or in other words, the BPPU sensor array naturally supports artificial neutral network vision processing as it played as the first layer of a neural network. The comprehensive system and detail recognition process are established in Supplementary Fig. 25 and Methods, and schematically illustrated in Fig. 5b. The original sensor output current for each BPPU in time-domain are shown in Fig. 5c & Supplementary Fig. 26. They were directly encoded into machine-readable features and sequentially fed into a Long Short-Term Memory (LSTM) network for robust classification38,39. This workflow eliminates redundancy in conventional sensory systems (including data converters, digital edge detection, digital filtering, and optical flow calculation). Within the motion trajectory simulation platform measurements, the system achieves 100% classification accuracy across training, validation, and test sets (Fig. 5d) under noise-free conditions (Supplementary Fig. 27).

Robustness against noise is another main challenge for machine vision. We validate the system rigorous by examining its performance under perturbations. Specifically, we purposely introduced two distinct types of noise into the real trajectories: Gaussian noise and random walk noise. These were selected to simulate uncorrelated and temporally correlated interference common in real-world scenarios, as shown in Supplementary Fig. 28.

Briefly, the noises are coupled to the motion target by:
𝑥(𝑡𝑖) = 𝑥0(𝑡𝑖)+𝛼 ∙𝒩(0,𝜎2)
{ (4)
𝑦(𝑡𝑖) = 𝑦0(𝑡𝑖)+𝛼∙𝒩(0,𝜎2)
for gaussian noise, and
𝑥(𝑡𝑖) = 𝑥0(𝑡𝑖)+ 𝛼 ∑𝑖𝑘=1 𝒩(𝑘)(0,𝜎2) / 10
{ (5)
𝑦(𝑡𝑖) = 𝑦0(𝑡𝑖)+ 𝛼 ∑𝑖𝑘=1 𝒩(𝑘)(0,𝜎2) / 10
for random walk noise, where 𝑥0(𝑡𝑖) and 𝑦0(𝑡𝑖) denote noise-free positions, 𝛼 is the noise level (𝛼 = 4%, 8%, 12%, 16%, 20%), 𝒩(0,𝜎2) represents independent Gaussian variables with 0 mean and 𝜎2 (𝜎 = 1) variance, and 𝑘 indexes discrete time steps.

Fig. 5e summarizes the identification accuracy for signals subjected to single kind of noises. The Gaussian noise in our experiments models common uncorrelated, high-frequency disturbances in real-world scenarios, such as electronic readout noise in sensors and circuits as well as photon shot noise, which independently affects each measurement point. In this case, the system demonstrates exceptional resilience: test accuracy maintains 95.32% at 20% noise intensity, representing a marginal 4.68% degradation from baseline. This robustness stems from the uncorrelated nature of gaussian noise. The BPPU based system can effectively filter out this kind of transient perturbation. The random walk noise is selected to simulate cumulative, low-frequency interference, including mechanical drift or vibration and slow sensor baseline drift. Its accumulated effect introduces time-correlated deviations that distort the intended motion trajectory, thereby testing the system’s robustness against shape errors. These disturbances alter key shape features of the path and increase classification complexity. Nevertheless, the system maintains a test accuracy registers at 99.19% for 4% noise intensity and remains measurable at 81.71% under 20% intensity. This performance demonstrates robust tolerance to trajectory distortions.

And finally, we also performed a comprehensive evaluation by integrated training across all noise types and intensities, it yields a 90.87% classification accuracy (Fig. 5f and Supplementary Fig. 29). These results confirm the system’s robust discrimination capability, even for perceptually similar motion patterns under challenging conditions. Fundamentally limited by a 33‑ns temporal resolution, the BPPU-based system can directly encode fast motion. The corresponding theoretical maximum detectable velocity of 7.6×104 m s−1 (discussed in Supplementary Fig. 30), allowing the system to capture and classify rapid trajectories that would otherwise be blurred or missed by standard imaging systems.

Methods
Materials
FTO glasses, Lead (II) iodide (PbI2), 2,2’7,7’tetra(N,N-di-tolyl)amino-9,9-spiro-bifluorene (Spiro-TTB) and C60 were purchased from Advanced Election Technology CO., Ltd. Tin (II) iodide SnI2 (99.999%) was purchased from 3AMaterials. Methylammonium iodide (CH3NH3I, MAI) (99.8%) was purchased from TCI. 2,9-dimethyl-4,7-diphenyl-1,10-phenanthroline (BCP) were purchased from Xi’an Polymer Light Technology Corp. All of the chemicals were used as received.

Perovskite photodiode and BPPU fabrication
The device structure was configured with a vertically stacked structure. Prepatterned FTO substrates were cleaned, treated with oxygen plasma, and then deposited with a 6 nm Spiro-TTB layer via thermal evaporation (~0.1 Å s−1). The graded perovskite heterojunction was fabricated through a sequential vapor-deposition process wherein SnI2 and PbI2 were first co-evaporated at a 1:1 molar ratio to form a homogeneous underlying layer with a total fixed thickness of 180 nm. The SnI2 source was then terminated at a stage corresponding to a PbI2 capping thickness (varied from 0 to 110 nm), depositing a pure PbI2 overlayer. Finally, the stacked precursor film was converted into a compositionally graded perovskite structure via reaction with vaporized MAI in a 180 °C vacuum oven. After cooling, the perovskite film was IPA-spin cleaned and annealed (100 °C, 10 min). Subsequent layers included thermally evaporated C60 (23 nm, ~0.1 Å s−1) and BCP (8 nm, ~0.08 Å s−1). The Ag electrode was finally deposited by thermal evaporation through a patterned shadow mask. For optoelectronic characterization, imaging, and trajectory recognition, the sub-photodiode areas of the BPPUs are 0.04 cm2, 4×10−4 cm2, and 0.01 cm2, respectively.

Film characterization
Ultraviolet-visible absorption spectra were measured using SHIMADZU UV-2600. The PL spectrum was measured using confocal Raman microscope (WITec, Alpha300R) with a 532 nm laser as the excitation source. SEM images were acquired through a FEI Quanta 450 FEG field emission scanning electron microscope. XRD spectra were acquired using a BRUKER D8-Advance equipped with Cu K𝛼1 irradiation (𝜆 = 1.5406 Å). UPS characterizations were performed using with a Thermo Fisher Scientific K-Alpha+ equipped with a He I (21.22 eV) excitation source. XPS for Pb-Sn ratio characterizations were acquired on the same instrument (Al Kα radiation source). Femtosecond laser ablation (fs-LA) XPS depth profiling for Sn2+ oxidation analysis was performed using a Thermo Fisher Scientific Hypulse XPS system40,41. Single femtosecond laser pulses of 40 μJ per level were employed, delivered as a horizontally linearly polarized Gaussian beam with a wavelength of 1030 nm and a pulse duration of 160 fs.

Device characterization
The electrical characterization of the photodiode and BPPU devices was conducted in a dark metal box to avoid interference from ambient light. Current-voltage characteristics were measured using a source-measure unit (Keithley 2612A Source Meters).

The LDR measurement was referred to the methodology outlined in the literature42,43. The device was illuminated by a modulated laser and the resulting photocurrent was detected with a lock‑in amplifier (Guangzhou Sine Scientific Instrument Co., LTD, Model OE2031) under zero bias. The frequency spectral response was obtained by scanning the reference frequency and standardized according to the equivalent noise bandwidth determined by the lock-in amplifier’s filter order and time constant. During the experiment, the incident optical power was calibrated with an optical power meter (Daheng Optics, GCI-080302) and attenuated using a series of neutral density filters (Thorlabs).

Noise current measurements were conducted at room temperature under dark condition, also utilizing the lock-in amplifier. EQE spectra were acquired at zero bias using an Enlitech QE-C system. The response time was acquired by an oscilloscope (Tektronix, TDS2024C) through a trans-impedance amplifier.

The BPPU array was tested using a home-built multi-channel scanning system. A Keithley 3706A Switch/Multimeter with a plug-in card (Keithley 3730 matrix card) was used to select rows and columns to determine the read-out terminal to be tested.

Imaging processing demonstration
Our home-built galvanometer scanning imager utilizes dual-axis galvanometer driven by XY-voltage inputs for rapid predefined trajectory scanning. The system directs reflected or transmitted scene light through a camera lens onto the photodetector. Real-time voltage programming dynamically reconfigures BPPU’s image processing functions, with processed signals acquired via TIA and lock-in amplification for subsequent image reconstruction.

Motion trajectory experimental platform
An 850 nm laser serves as the light source, with its beam dynamically steered across the BPPU device following a preset trajectory via a dual-axis galvanometer scanner. The multi-channel digital-to-analog converter provides 18 independent biases, pre-programming the 6×6 BPPU array to the target response matrix. A TIA and a lock-in amplifier used to acquire the resulting time-series current signals generated by the BPPU under dynamic laser spot stimulation.

The acquired noise-free trajectories and with-noise variants were used to construct different datasets. For evaluating the impact of each noise intensity level, a dedicated dataset was assembled per intensity, consisting of 256 noise-free samples and 320 with-noise variants samples, yielding 576 samples in total. For the comprehensive evaluation involving integrated training across all noise types and intensities, a combined dataset was created by merging the noise-free data with all noisy samples, resulting in 3,232 samples in total. Each dataset was split into 60% for training, 20% for validation, and 20% for testing. The BPPU generated time-series features were fed into an LSTM network comprising a 128 hidden units LSTM layer, a fully connected layer, and a softmax output layer, which was trained with the Adam optimizer (initial learning rate: 0.001) for up to 100 epochs.

Peer review rounds
[{"round": 1, "reviewer_comments": {"reviewer_1": "This work reports a graded Pb-Sn alloyed perovskite heterojunction photodiode fabricated via vapor deposition, which is\nthen used to construct a bipolar programmable unit and an in-sense computing network. The research successfully\naddresses the classic challenge in high-performance photodetectors of simultaneously achieving broadband response,\nlarge linear dynamic range, and fast response speed. More importantly, the authors go beyond a simple device performance\ndemonstration by tightly integrating device innovation with system-level applications, showcasing a series of cutting-edge in-\nsensor computing applications ranging from biomedical imaging to robust motion trajectory recognition. Overall, this is a\noutstanding and impressive piece of work, paving a new way for perovskite applications in next-generation machine vision. I\nwould like to recommend this manuscript for publication in Nature Communications. Here are some specific comments and\nsuggestions:\n1. The introduction cites numerous works utilizing novel physical mechanisms (e.g., ion migration, ferroelectric effect) to\nachieve programmable photoresponse. Please further clarify whether the core innovation of the proposed BPPU architecture\nstems from a breakthrough in device physics or from an ingenious circuit architecture combination? How does it\nfundamentally differ from the mechanisms in the cited literature?\n2. The graded heterojunction design suppresses Sn2+ oxidation and creates a favorable band structure for charge\nextraction. The discussion should address the trade-off that the PbI2 capping layer reduces short-wave infrared response,\nand analyze if this is acceptable for target applications like vein imaging.\n3. Please provide the wavelengths of the background light and the light spot used in the background suppression capability\ntest (Fig. 2g-i), to confirm whether the suppression capability depends on the spectral difference between the spot and the\nbackground.\n4. The BPPU currently demonstrates differential (edge detection) and programmable convolution (trajectory recognition)\nfunctions. Theoretically, can this architecture implement arbitrary filter kernels (e.g., Gaussian blur, Sobel operator, etc.)?\n5. Why were Gaussian and random walk noise chosen for the trajectory robustness tests? What specific interference\nscenarios in real-world applications do they simulate respectively?\n6. There are minor grammatical and phrasing issues throughout the manuscript; careful professional polishing is\nrecommended. For example, \"It enables to detect…\"\nI recommend that the editor consider this manuscript for publication in Nature Communications after the authors have\nsatisfactorily addressed the points above. These revisions will not alter the core conclusions of the work but will make it\nmore complete and persuasive.", "reviewer_2": "In this manuscript, the authors report the development of a sensor-computing network based on gradient Pb-Sn alloyed\nperovskites, demonstrating a 238 dB linear dynamic range (LDR) and a 33 ns response time for the photodiodes fabricated\nvia vapor deposition. The photodiode is also integrated into a wafer-scale imaging processor, showcasing low-power, high-\nresolution imaging, background suppression, and biomedical sensing capabilities. This work is of significant importance for\nmachine vision and sensor computing applications. However, some aspects require further data support and discussion.\n1.The manuscript claims exceptional performance, but the comparison with existing works (especially on LDR and response\ntime) is insufficient. Provide a comprehensive benchmarking table comparing LDR, speed, detectivity, operating voltage,\nand wavelength range with recent perovskite, organic, and CMOS photodiodes.\n2.The LDR measurement method requires more explanation. How is noise floor defined and verified (integration time,\nbandwidth, instrument configuration)? Is the LDR measured at zero bias or across all biases? How exactly was the\nphotocurrent measured at the lowest power level?\n3.Although UPS/XPS data are referenced, the band diagram (Fig. 1g) is not quantitatively supported. Include simulation or at\nleast drift–diffusion discussion of how the graded junction improves carrier extraction and response speed.\n4.Figure S7 shows that the Sn/Pb ratio varies with depth. Please explain the cause of this variation and discuss its impact on\nthe material's optical and electronic properties, particularly in relation to carrier mobility and band structure. How does this\nvariation contribute to device performance?\n5.The manuscript mentions good performance under different illumination conditions, but does not address the performance\nunder high light intensity backgrounds. Please provide data on the device's performance under strong light backgrounds and\ndiscuss its stability, particularly focusing on dynamic range and saturation behavior under these conditions.\n6.Please explain why the background current values in Figure 2i differ significantly among the three sets of tests, whereas\nthe test deviations under different light intensities in Figure 2g are much smaller.\n7.The current value corresponding to the light intensity of 2 mW/cm² in Figure 2e is approximately 10 μA, whereas the zero-\nbias current in Figure S12 is much smaller than 0.1 μA. Please verify the accuracy and reliability of the data.\n8.For biomedical imaging: What is the signal-to-noise ratio improvement from edge detection? How do accuracy and\ncontrast compare with conventional Sobel or Laplacian digital filters?\n9.For trajectory encoding: What is the temporal resolution and minimum detectable velocity?", "reviewer_3": "This paper presents a graded Pb-Sn alloyed perovskite heterojunction photodiode fabricated via a full vapor deposition\nprocess, achieving broadband response from visible to infrared, an ultra-large linear dynamic range of 238 dB, and a fast\nresponse time of 33 ns. The authors further develop a wafer-scale in-sensor computing network, demonstrating its\napplication in biomedical imaging and spatiotemporal trajectory encoding. The work is highly compelling, showcasing\nsignificant advancements in material design, device performance, and system integration for intelligent machine vision. It is\nrecommended that the authors address the points raised below to further strengthen the manuscript.\n1. The manuscript contains several instances of non-standard unit formatting. For example, in line 151, a space is missing\nbetween the numerical value and its unit.\n2. While XPS/UPS data confirm a Sn/Pb gradient in a localized area, the uniformity and reproducibility of this gradient\nacross the entire wafer scale remain unverified. To robustly demonstrate the controllability of this deposition process for\nscalable manufacturing, please provide additional data.\n3. The PL stability data indirectly suggest suppressed Sn2+ oxidation. To provide direct chemical evidence, I recommend\ncomparing the Sn 3d XPS spectra, including depth profiling, of the homogeneous and graded heterojunction films before\nand after aging. This would visually demonstrate the effective suppression of Sn4+ formation in the graded structure.\n4. The 700-hour operational stability test shown in Fig. S6 is a key result. However, the critical parameters of the optical\nstimulus used for the \"on-off switching\" test are not specified . Please provide these details. In addition, is there a difference\nin the durability of devices under different light intensity stimuli?\n5. In Figure 2a, the labels for the material layers in the device structure are missing.\n6. To unequivocally verify that the noise reduction stems from correlated noise common-mode rejection in the back-to-back\nconfiguration—rather than inherently low noise in each individual photodiode—please provide the independent noise\ncurrent spectra for both sub-photodiodes (D1 and D2) measured at zero bias.\n7. The reported ultra-fast response time (33 ns) is remarkable. Please specify the intensity of the optical pulse used in this\nmeasurement.\n8. The authors’ explanation that the speed improvement arises from the reduced effective capacitance in the back-to-back\nstructure is theoretically reliable. However, in addition to this theoretical interpretation, the response speed of a single device\nshould also be measured and compared with that of the composite structure to provide practical verification.\n9. When the background illumination incident on the sensor array is not perfectly uniform (for example, when gradients or\nlocalized shadows are present), D1 and D2 will experience different light intensities. Could this lead to a degradation of the\nbackground-suppression effect, or even generate spurious signals?\n10. The manuscript reports an ultrahigh linear dynamic range of 238 dB together with a zero-bias EQE of ~61% at 850 nm,\nwhich is an excellent performance combination. To conclusively demonstrate that the photoresponse remains linear across\nthe entire dynamic range, and that the high EQE is not limited to a specific illumination level, please provide EQE curves\nmeasured under varying incident light intensities."}, "author_response": "To all Reviewers:\nDear Reviewers,\nThank you very much for your time and efforts in reviewing this manuscript for publication in\nNature Communications. We deeply appreciate your constructive and encouraging comments. After a\ncareful consideration all these questions and suggestions, we have revised the manuscript and compiled\na detailed point-by-point response as follows.\nThis work reports a graded Pb-Sn alloyed perovskite heterojunction photodiode fabricated via vapor\ndeposition, which is then used to construct a bipolar programmable unit and an in-sense computing\nnetwork. The research successfully addresses the classic challenge in high-performance photodetectors\nof simultaneously achieving broadband response, large linear dynamic range, and fast response speed.\nMore importantly, the authors go beyond a simple device performance demonstration by tightly\nintegrating device innovation with system-level applications, showcasing a series of cutting-edge in-\nsensor computing applications ranging from biomedical imaging to robust motion trajectory\nrecognition. Overall, this is an outstanding and impressive piece of work, paving a new way for\nperovskite applications in next-generation machine vision. I would like to recommend this manuscript\nfor publication in Nature Communications. Here are some specific comments and suggestions:\n1. The introduction cites numerous works utilizing novel physical mechanisms (e.g., ion migration,\nferroelectric effect) to achieve programmable photoresponse. Please further clarify whether the core\ninnovation of the proposed BPPU architecture stems from a breakthrough in device physics or from\nan ingenious circuit architecture combination? How does it fundamentally differ from the mechanisms\nin the cited literature?\nReply:\nThank you for raising this important question regarding the core innovation of our BPPU architecture.\nWe appreciate the opportunity to clarify that the novelty lies not in the discovery of a new physical\nmechanism, but in the synergistic integration of a stable material innovation with an ingenious circuit\narchitecture to achieve robust and programmable in-sensor computing. Below we detail the respective\ncontributions and the fundamental distinction from the mechanisms cited in the introduction.\n(1) Device-Level Innovation: The foundation of this work is the gradient Pb–Sn alloyed perovskite\nheterojunction fabricated via a fully vapor-phase process. This gradient structure constitutes a\nmaterial and device innovation by effectively suppressing Sn2+ oxidation and substantially\nenhancing operational stability. Moreover, its built-in bandgap gradient promotes the efficient and\nrapid extraction of photogenerated carriers. This graded heterojunction provides the essential\n2\nmaterial basis for the BPPU’s broadband response, large LDR, and fast response speed.\nFurthermore, the vapor-phase process ensures excellent device-to-device uniformity, which is\ncritical for enabling the subsequent circuit-level functionality based on differential detection.\n(2) Circuit-Architecture Innovation: The programmability and bipolar photoresponse of the BPPU are\nachieved through its back-to-back dual photodiode configuration with independent bias control\n(V , V ). By electrically tuning the biases applied to the two photodiodes, we can precisely and\nA B\nrapidly control the net photoresponse (both polarity and amplitude). This architecture leverages the\nsymmetry of two well-matched photodiodes to enable, at zero net bias: (a) Common-mode\nrejection of correlated background/noise; (b) Reduced effective capacitance, resulting in ultrafast\nresponse speed.\nIn contrast to the mechanisms referenced in the introduction (e.g., ion migration, ferroelectric effects),\nwhich modulate photoresponse by altering the intrinsic properties of the semiconductor material itself,\nthe BPPU employs a pair of stable, fixed-characteristic photodiodes. Its programmability is achieved\nthrough electrical control at the architectural level via external circuit biases. This approach avoids\nherent drawbacks associated with material-property switching, such as hysteresis, slow speed, or\nreliability degradation, thereby offering a more generalizable and robust pathway for fast, stable, and\nprecise programmable photoelectric computing.\nWe have supplemented the Introduction sections to more explicitly articulate this distinction (Page 4).\n“Here, we introduce a gradient composition engineering strategy that provides a protective layer for\noxidation suppression of Sn2+. By this approach, we fabricate stable lead-tin (Pb-Sn) alloyed perovskite\nfilms via fully vapor deposition process. And based on these advancements, we demonstrate a scalable\nbroadband perovskite bipolar programmable unit (BPPU). The core device comprises two sets of back-\nto-back cascaded perovskite photodiodes. This architecture enables rapid, stable, and precise control\nof photoresponse purely through circuit‑level biasing, avoiding trade‑offs in hysteresis, speed, or\nreliability. The uniform vapor-phase deposition ensures symmetric bipolar response tuning under low\nbias (±200 mV), fast response time of 33.0/37.4 ns and a large LDR of 230 dB. By integrating the\nBPPU into wafer-scale arrays, we achieve diverse in-sensor computing function such as adaptive\nbackground suppression, biomedical sensing and spatiotemporal trajectory encoding.”\n3\n2. The graded heterojunction design suppresses Sn2+ oxidation and creates a favorable band structure\nfor charge extraction. The discussion should address the trade-off that the PbI capping layer reduces\n2\nshort-wave infrared response, and analyze if this is acceptable for target applications like vein imaging.\nReply:\nWe fully agree that the PbI capping layer, while effectively suppressing Sn2+ oxidation and creating a\n2\nfavorable band structure, introduces a reduction in the short-wave infrared (SWIR) response beyond\n~900 nm compared to a uniform Pb-Sn perovskite of equivalent total thickness.\nThis trade-off, however, is acceptable and indeed beneficial for our target application of vein imaging.\nThe key physiological contrast for vein imaging relies on the characteristic absorption of hemoglobin\nwithin the 760–850 nm spectral range. Crucially, our optimized graded heterojunction maintains an\nexternal quantum efficiency (EQE) of 61.07% at 850 nm (Fig. 1h), ensuring sufficient sensitivity\nacross this critical window. This practical efficacy is directly demonstrated by our finger vein imaging\nexperiments, which successfully captured clear venous networks (Fig. 4d–f).\nThe overall benefits provided by the graded structure, including the improvement in operational\nstability, significant suppression of dark current, and optimized charge extraction efficiency, far\noutweigh the marginal loss in SWIR response beyond the primary spectral region of interest. Therefore,\nthis design compromise remains highly advantageous for building a stable and practical visible-to-NIR\nvision system.\nWe have revised the manuscript to elaborate on this point. In the relevant section, we now explicitly\naddress this trade-off, including the mention of hemoglobin's absorption characteristics to justify why\nthe maintained performance is fully adequate for vein imaging (Page 8):\n“The thickness of pre-covered PbI layer (Δd = 20–110 nm) is a critical parameter for the compromise\n2\nof device operational stability, carrier transport efficiency, and NIR sensitivity. The 80 nm PbI pre-\n2\ncovered layer provides an optimized NIR response. When the PbI thickness exceeds 80 nm, Pb-Sn\n2\nbalanced region which serves as the primary infrared absorber, is too short to preserve photo-response\nbeyond 850 nm. This attenuation is directly evidenced by a 33% responsivity decrease at 850 nm in\n4\nΔd = 110 nm devices (0.28 A W−1 versus 0.42 A W−1 for 80 nm devices, Fig. S13). Conversely, sub-\n80-nm pre-covered layers fail to adequately suppress oxidation-induced degradation, leading to\ndeteriorated response. With the optimized structure, the gradient Pb-Sn alloyed perovskite film\nachieves a zero-bias external quantum efficiency (EQE) of 61.07% at 850 nm (Fig. 1h). This\nwavelength is crucial for NIR applications such as vein imaging that rely on the characteristic\nabsorption of hemoglobin in the 760–850 nm spectral range. Although the PbI coating weakens the\n2\ndevice’s short-wave infrared response above 850 nm, the high sensitivity maintained within the key\nspectral window fully meets the physical requirements of the targeted biomedical applications. This\nstructure simultaneously satisfies essential intelligent vision system requirements including multi-\nwavelength adaptability, environmental stability, and rapid response capabilities.”\n3. Please provide the wavelengths of the background light and the light spot used in the background\nsuppression capability test (Fig. 2g-i), to confirm whether the suppression capability depends on the\nspectral difference between the spot and the background.\nReply:\nWe appreciate the reviewer’s attention to this experimental detail. In the background suppression tests\npresented in Fig. 2g–i, both the background illumination and the moving signal spot were produced\nusing sources of identical wavelength: an 860 nm LED array for the background and an 860 nm laser\nfor the spot. This clarification has been incorporated into the caption of Fig. 2 (Page 10):\n“Fig. 2 | Design & Performance of BPPU. … g, Background suppression capability of the extended\nBPPU under V = V = 0 V, measured under background illumination from an 860 nm LED array. h.\nA B\nResponse to a moving 860 nm laser spot (1mm spot size) with intensities of 5.62 nW, 1.01 nW and\n146 pW under dark background illumination. i, Response to the same moving laser spot under strong\nbackground (BG) illumination provided by an 860 nm LED array (42.18 mW), with spot intensities\n1.19 μW, 719 nW, and 530 nW. The colored shading represents the spatial responsivity profile across\nthe extended BPPU array.”\nThe result confirms that the background suppression capability of the BPPU arises primarily from the\ncircuit‑level principle of spatial differential sensing, rather than relying on any spectral difference\n5\nbetween the signal and the background.\n4. The BPPU currently demonstrates differential (edge detection) and programmable convolution\n(trajectory recognition) functions. Theoretically, can this architecture implement arbitrary filter kernels\n(e.g., Gaussian blur, Sobel operator, etc.)?\nReply:\nThank you for your insightful question. Our Extended BPPU Array architecture is capable of\nimplementing arbitrary linear filter kernels. Edge detection, as demonstrated, is indeed a specific\ninstance of a convolution kernel configuration. The fundamental mechanism enabling this versatility\nlies in our ability to program the responsivity of each individual BPPU within the array. By precisely\nadjusting the respective bias voltages (V , V ) of each unit, we can effectively map the desired weight\nA B\nvalues of any target convolution kernel.\nWe have added a corresponding brief discussion of the revised manuscript (Page 17):\n“Notably, in contrast to conventional imaging with separate post-computation, our in-sensor\ncomputing approach operates at 0 V, approaching nearly zero-power data processing. Furthermore, the\nbipolar response characteristics of the extended BPPU array, in principle, allow it to be programmed\nto perform arbitrary two-dimensional linear convolution operations, effectively functioning as a\nversatile image processing kernel for various in-sensor computational imaging effects.”\n5. Why were Gaussian and random walk noise chosen for the trajectory robustness tests? What specific\ninterference scenarios in real-world applications do they simulate respectively?\nReply:\nThank you for raising this important point regarding the choice of noise models in our trajectory\nrobustness tests. We selected Gaussian noise and random walk noise to simulate two distinct and\ncommon types of interference encountered in real-world applications. (1) Gaussian noise was used to\nmodel high-frequency, uncorrelated random disturbances, such as electronic readout noise in sensors\n6\nand circuits, as well as photon shot noise, which independently affect each measurement point. (2)\nRandom walk noise, in contrast, was employed to simulate low-frequency, time-correlated\ndisturbances. This includes effects like mechanical drift or vibration (e.g., from a moving platform or\ntarget) and slow baseline drift in sensors. Its cumulative nature introduces bias over time, thereby\ndistorting the expected motion trajectory.\nWe have incorporated this explanation into the revised manuscript to provide clearer justification for\nour experimental design (Page 20):\n“Robustness against noise is another main challenge for machine vision. We validate the system\nrigorous by examining its performance under perturbations. Specifically, we purposely introduced two\ndistinct types of noise into the real trajectories: Gaussian noise and random walk noise. These were\nselected to simulate uncorrelated and temporally correlated interference common in real-world\nscenarios, as shown in Fig. S28.\nBriefly, the noises are coupled to the motion target by:\n2\n𝑥(𝑡𝑖) = 𝑥0(𝑡𝑖)+𝛼 ∙𝒩𝑥(0,𝜎 )\n{ 2\n𝑦(𝑡𝑖) = 𝑦0(𝑡𝑖)+𝛼 ∙𝒩𝑦(0,𝜎 )\nfor gaussian noise, and\n𝑖\n𝛼 (𝑘) 2\n⎧𝑥(𝑡𝑖) = 𝑥0(𝑡𝑖)+ ∑ 𝒩𝑥 (0,𝜎 )\n𝑘=1\n10\n𝑖\n⎨ 𝛼 (𝑘) 2\n𝑦(𝑡𝑖) = 𝑦0(𝑡𝑖)+ ∑ 𝒩𝑦 (0,𝜎 )\nfor random walk noise, where⎩ and 1 0deno𝑘te= 1noise-free positions, is the noise level (\n= 4%, 8%, 12%, 16%, 20%), 𝑥0(𝑡𝑖) re 𝑦 p0re(s 𝑡 e𝑖)nts independent Gaussian varia 𝛼 bles with 0 mean an 𝛼 d\n2\nvariance, and indexes discrete time steps.\n𝒩(0,𝜎 )\n2\n𝜎 (𝜎 = 1) 𝑘\nFig. 5d summarizes the identification accuracy for signals subjected to single kind of noises. The\nGaussian noise in our experiments models common uncorrelated, high-frequency disturbances in real-\nworld scenarios, such as electronic readout noise in sensors and circuits as well as photon shot noise,\nwhich independently affects each measurement point. In this case, the system demonstrates exceptional\nresilience: test accuracy maintains 95.32% at 20% noise intensity, representing a marginal 4.68%\ndegradation from baseline. This robustness stems from the uncorrelated nature of gaussian noise. The\nnoise is selected to simulate cumulative, low-frequency interference, including mechanical drift or\nvibration and slow sensor baseline drift. Its accumulated effect introduces time-correlated deviations\nthat distort the intended motion trajectory, thereby testing the system’s robustness against shape errors.\nThese disturbances alter key shape features of the path and increase classification complexity.”\n6. There are minor grammatical and phrasing issues throughout the manuscript; careful professional\npolishing is recommended. For example, \"It enables to detect…\"\nI recommend that the editor consider this manuscript for publication in Nature Communications after\nthe authors have satisfactorily addressed the points above. These revisions will not alter the core\nconclusions of the work but will make it more complete and persuasive.\nReply:\nThank you for your valuable feedback on the language throughout the manuscript and for your\nsupportive recommendation subject to these revisions. We have conducted a thorough, professional\npolish of the entire text to enhance clarity, correctness, and overall readability. For instance, the\nphrasing “It enables to detect…” has been revised to “It enables the detection of…”. All similar\ninaccuracies have been carefully corrected, and the manuscript has undergone extensive language\nediting to ensure it meets the high standards expected for publication.\nIn this manuscript, the authors report the development of a sensor-computing network based on\ngradient Pb-Sn alloyed perovskites, demonstrating a 238 dB linear dynamic range (LDR) and a 33 ns\nresponse time for the photodiodes fabricated via vapor deposition. The photodiode is also integrated\ninto a wafer-scale imaging processor, showcasing low-power, high-resolution imaging, background\nsuppression, and biomedical sensing capabilities. This work is of significant importance for\nmachine vision and sensor computing applications. However, some aspects require further data support and\ndiscussion.\n1. The manuscript claims exceptional performance, but the comparison with existing works (especially\non LDR and response time) is insufficient. Provide a comprehensive benchmarking table comparing\nLDR, speed, detectivity, operating voltage, and wavelength range with recent perovskite, organic,\nand CMOS photodiodes.\nReply:\nThank you for your valuable suggestions. We have now included new Table S1 in the Supplementary\nInformation, providing a comprehensive comparison of key metrics between the single photodiode in\nthis work and recently reported advanced photodiodes. The comparison reveals that the combination\nof 230 dB LDR and 33 ns response speed achieved by the graded device in this work is among the best\nreported for broadband (visible–NIR) photodetectors, highlighting its unique performance advantages.\nWe have referenced this comparison table and used it to further clarify competitiveness of our work.\nIn manuscript (Page 10): “Our device demonstrates competitive advantages over recently reported\nbroadband (visible–NIR) photodetectors, as detailed in Table S1.”\nOperating LDR\nDevice structure Wavelength (nm) R (mA W−1) D* (Jones) Rise/fall time Year Ref.\nvoltage (V) (dB)\nThis\nITO/Spiro-TTB/MASn Pb /C /BCP/Ag 300–950 0 420 @ 850 nm 1.1×1012 230 33.0/37.4 ns 2026\nx 1-x 60\nWork\nPerovskite\nITO/PEDOT:PSS/(FASnI ) (MAPbI ) /\n3 0.5 3 0.4\n300–1000 −0.2 400 @ 900 nm 1.1×1012 167 6.9/9.1 μs 2017 1\nC /BCP/Ag\n0.975 0.025 0.65 0.35\n300–1100 0 400 @ 910 nm >1012 110 40/468 ns 2018 2\nI /PCBM/ZrAcac/Ag\n2 3 0.975 0.025 0.6\n300–1100 0 200@940 nm >1011 100 0.09/2.27 μs 2019 3\nPb I /PCBM/ZrAcac/metal\n5 0.35 3\nFTO/TiO /CsSnI /P3HT/Ag 350–1000 0 257 @ 850 nm 1.5×1011 0.35/1.6 ms 2020 4\n2 3\nITO/PTAA/Cs MA FA Pb Sn I /C\n0.05 0.45 0.5 0.5 0.5 3 6\n300–1050 0 530 @ 910 nm 2.07×1011 35 ns 2020 5\n/BCP/Cu\n0.85 0.15 0.5 0.5 3\n600–1000 0 530 @ 940 nm 6×1012 103 58.3/860 ns 2021 6\nCBM/ZrAcac/Ag\nITO/PTAA/TBA-\nAzo/C60/FA MA Cs Pb Sn I /BC 300–1050 0 350 @ 950 nm 2.21×1011 185 42.9 ns 2021 7\n0.5 0.45 0.05 0.5 0.5 3\nP/Cu\nITO/PEDOT:PSS/PEA FA SnI /C /B 390 @ 760 nm\n0.15 0.85 3 60\n450–850 −0.1 8.29×1011 109 0.78/1.31 μs 2022 8\nCP/Ag\nITO/PEDOT:PSS/FA MA Sn Pb I /C\n0.7 0.3 0.5 0.5 3\n450–900 0 510 @ 840 nm 1.2×1012 94/97 ns 2023 9\n/BCP/Ag\n60\nDevice structure Wavelength (nm) R (mA W−1) D* (Jones) Rise/fall time Year Ref.\nvoltage (V) (dB)\nITO/PTAA/Cs FA Pb Sn I /C /BC\n0.15 0.85 0.5 0.5 3 60\n325–980 0 520 @ 850 nm 5.34×1012 224 39.68 ns 2023 10\nP/Cu\nITO/PTAA/(FASnI ) (MAPbI ) /PCBM/ 22.78/20.35\n3 0.1 3 0.9\n350–840 0 530 @ 800 nm 7.09×1010 163.5 2023 11\nC /BCP/Ag μs\n0.5 0.5 3\n300–1000 0 410 @ 860 nm 5.32×1012 204 1.22/1.17 μs 2024 12\nCP/Ag\nITO/Cs FA GA Pb Sn (I Br )\n0.1 0.87 0.03 0.7 0.3 0.95 0.05 3\n400–1100 −3 340 @ 940 nm 3.7×1011 177 34.7/81.2 μs 2024 13\nsingle crystal/Ga\nITO/PEDOT:PSS/FA Cs Sn Pb I /P\n0.85 0.15 0.5 0.5 3\n320–1000 0 570 @ 940 nm 2×1013 222 0.57 μs 2025 14\nCBM/ZrAcac/Ag\nITO/PTAA/FA MA Sn Pb I /PCBM/\n0.7 0.3 0.5 0.5 3\n300–1000 nm 0 490 @ 830 nm 1.2×1012 174 14.2/17.1 ns 2025 15\nC /BCP/Ag\n0.5 0.5 2\n350–730 0 360 @ 650 nm 1.74×1013 146 8.30/39.19 μs 2025 16\nBCP/Ag\nFTO/PTAA/FA Cs Pb Sn I /PCBM/\n0.85 0.15 0.5 0.5 3\n300–1000 0 310 3.84×1011 171.4 2.9/45.7 μs 2025 17\nBCP/Au\nITO/PEDOT:PSS/Cs FA MA Sn Pb\n0.1 0.6 0.3 0.5 0.\n300–1000 0 580 @940 nm 1.6×1013 147 0.58/0.34 μs 2026 18\nI /C /BCP/Ag\n5 3 60\nITO/MeO-6PACz/\n300–1100 0 490 1.42×1011 173 0.38/0.86 ns 2026 19\nFA MA Sn Pb I /C /BCP/Ag\n0.7 0.3 0.5 0.5 3 60\nOrganic\nITO/ZnO\nx\n/PTB7-Th:Co1-4Cl/MoO\nx\n/Ag 400–1100 −2 530 @ 920 nm 3.31×1013 148 1.82 μs 2019 20\nDevice structure Wavelength (nm) R (mA W−1) D* (Jones) Rise/fall time Year Ref.\nvoltage (V) (dB)\nITO/PEDOT:PSS/PMBBDT:Y6/Al 300–900 5 >3×105 @ 800 nm 9.6×1010 124 79 μs 2021 21\nITO/ZnO/PTB7-Th:ITIC/MoO /Ag/\nx\n300–1000 −0.1 >430 @ 850 nm 9.73×1011 197 146.8 ns 2021 22\nPEIE/PTB7-Th:FOIC/MoO /Ag\nx\nITO/PEDOT:PSS/D18/Y6/PDINO/Al 300–1000 0 499 @ 805 nm 1.97×1014 83 15/14 μs 2021 23\nITO/ZnO/PF:IT-4F/MoO\nx\n/Ag 300–800 −2 360 @ 532 nm 3.39×1013 120.5 2022 24\nITO/ZnO/PBDB-T:BPPT-4F/MoO\nx\n/Ag 300–1000 −1 350 @ 870 nm 1.3×1013 200 2022 25\nITO/ZnO/PTB7-Th:COTIC-\n780–1070 −0.1 450 @ 1050 nm 1.29×1013 150 8/8 μs 2022 26\n4F:Y6/MoO /Ag\nx\nITO/ZnO/Y6/MoO\nx\n/Ag 400–1000 −3 169 2.74×1012 87 7.9/13.6 μs 2023 27\nITO/PEDOT:PSS/PolyTPD:2TT-\n400–900 −3 27 @ 830 nm 3×1011 111 83/95 μs 2023 28\noC6B:PCBM/Phen-NaDPO/Ag\nITO/PM6:3TT-FIC/Ag 450–1000 −1 360 @ 850 nm 1.45×1013 102 1.6/1.2 μs 2023 29\nITO/ZnO/PM7-D5:Y12/MoO\nx\n/Ag 300–1000 −2 427 @ 850 nm 3.3×1013 150 7.0/6.7 μs 2024 30\nITO/PEDOT:PSS/P3HT:F4TCNQ/P3HT/ 1.12×106 @ 1800\n500–1800 −10 1.1×1011 40 267/365 ms 2024 31\nAl nm\nITO/PEI-Zn/PBDTTT-OFT:N2200/Ag 300–900 −2 170 @ 730 nm 6.7×1011 3/8 μs 2024 32\nITO/ZnO/PTB7-Th:COTIC-4F/MoO\nx\n/Ag 300–1140 −5 520 @ 1100 nm 1.1×1013 135 0.6/0.5 μs 2024 33\nITO/ZnO/PBDT-TT:TbzIC/MoO\n3\n/Ag 300–1400 −4 370 @ 1100nm 1×1013 106 8.3/6.9 μs 2024 34\nITO/ZnO/PM6:PY-DTP-Ph/MoO\n3\n/Al 300–900 −0.1 292 @ 810 nm 5.4×1013 105 1.2/21.8 μs 2024 35\nITO/PEDOT:PSS/PBDB-T:PZF-V:PY-\n300–1000 −0.1 440 8×1012 145 2024 36\nIT/PFN:Br/Ag\nDevice structure Wavelength (nm) R (mA W−1) D* (Jones) Rise/fall time Year Ref.\nvoltage (V) (dB)\nITO/PEDOT:PSS/PM6:CH17/PDINO/Ag 400–900 0 530 @ 830 nm > 1012 130 91/102 ns 2024 37\nITO/ZnO/PDPPTDTPT:P4TOC-\n650–1070 −0.1 110 @ 960 nm 1.13×1012 125 1.36/0.60 μs 2025 38\nDCBT/MoO /Ag\nSPAD Image Sensor 108.1 2020 40\nSub-pixel architecture 132 2020 41\nSPAD Image Sensor 124 2021 42\nStacked Digital Pixel Sensor 127 2021 43\nSPAD Photon-Counting Image Sensor 124 2021 44\nStacked Digital Pixel Sensor 127 2022 45\nSPAD-based dual-mode module 198 2023 46\nF-DTI pixel architecture 120 2023 47\nSPAD 126 2024 48\nSPAD 120.4 2025 49\nSub-pixel architecture 129 2025 50\nCG-programmable QCG pixels 120 2025 51\nSPAD 131 2026 52\n13\n2. The LDR measurement method requires more explanation. How is noise floor defined and verified\n(integration time, bandwidth, instrument configuration)? Is the LDR measured at zero bias or across\nall biases? How exactly was the photocurrent measured at the lowest power level?\nReply:\nThe LDR measurement was performed based on the methodology outlined in the literature (\nNat.\nPhoton. 2019, 13, 1–4; Nat. Photon. 2025, 19, 1178–1188). We have provided point-by-point\nclarifications below and have incorporated a description of the experimental procedures into the\nrevised manuscript.\n(1) Noise Floor: The noise floor is defined as the standard deviation of the dark current measured\nunder complete darkness. This measurement was performed using a lock‑in amplifier (Sine\nScientific Instruments, OE2031) configured with a 24 dB/oct roll‑off and a time constant of TC =\n10 s, yielding an equivalent noise bandwidth (ENBW) of 5/(64 × TC) ≈ 0.0078 Hz. To verify\nthe accuracy of this noise floor, we further analyzed the current spectral density (Fig. R1),\nwhich\nillustrates the intrinsic noise distribution of the BPPU device.\n(2) Bias Condition for LDR Measurement: All LDR data reported in the manuscript were measured\nunder zero external bias.\n(3) Photocurrent Measurement at the Lowest Optical Power: We employed the principle of lock-in\namplification for the measurements. An intensity-modulated laser source was used, and the output\ncurrent signal from the BPPU was fed into a lock-in amplifier to directly measure the current\ncomponent in-phase with the modulation frequency. This method effectively suppresses\nbroadband 1/f noise and environmental interference. (Fig. R1).\nTo illustrate the low‑power measurement method and results more intuitively, we have supplemented\nthe current‑versus‑frequency spectrum in the Supplementary Information (Fig. S16). The above\nclarifications have been integrated into the revised Methods section, ensuring the reproducibility and\ntransparency of our LDR characterization. The updated methodological description reads as follows:\nIn manuscript (Page 24): “The electrical characterization of the photodiode and BPPU devices was\nconducted in a dark metal box to avoid interference from ambient light. Current-voltage characteristics\nwere measured using a source-measure unit (Keithley 2612A Source Meters).\nThe LDR measurement was referred to the methodology outlined in the literature42,43. The device was\nilluminated by a modulated laser and the resulting photocurrent was detected with a lock‑in amplifier\n(Sine Scientific Instruments, OE2031) under zero bias. The frequency spectral response was obtained\nby scanning the reference frequency and standardized according to the equivalent noise bandwidth\ndetermined by the lock-in amplifier’s filter order and time constant. During the experiment, the\nincident optical power was calibrated with an optical power meter (Daheng Optics, GCI-080302) and\nattenuated using a series of neutral density filters (Thorlabs).\nNoise current measurements were conducted at room temperature under dark condition, also utilizing\nthe lock-in amplifier. External quantum efficiency (EQE) spectra were acquired at zero bias using an\nEnlitech QE-C system. The response time was acquired by an oscilloscope (Tektronix, TDS2024C)\nthrough a trans-impedance amplifier.”\n15\n3. Although UPS/XPS data are referenced, the band diagram (Fig. 1g) is not quantitatively supported.\nInclude simulation or at least drift–diffusion discussion of how the graded junction improves carrier\nextraction and response speed.\nReply:\nWe sincerely appreciate the reviewer’s insightful observation regarding the basis for our band diagram\nin Fig. 1g. To address this, we have incorporated a more detailed drift-diffusion based analysis into the\ndiscussion section. We clarify that the continuous compositional gradient within the active layer leads\nto a corresponding continuous spatial tilting of both the Conduction Band Minimum (CBM) and\nValence Band Maximum (VBM). This gradient effectively creates a built-in quasi-electric field (or\nenergy gradient) that permeates the entire active region.\nUnder the influence of this built-in field, photo-generated electrons and holes undergo directional drift\ntransport. Electrons are actively propelled towards the lead-rich region, while holes are driven towards\nthe tin-rich region. This shift from diffusion-dominated to drift-dominated carrier transport signifies\nthat, once generated, photocarriers undergo immediate and sustained directional movement across the\nentire active layer, rather than relying solely on sluggish random diffusion processes or localized\nenergy level differences at interfaces. Consequently, this field-assisted drift markedly accelerates\ncharge separation and transport, substantially reducing carrier transit time within the device.\nFurthermore, the considerable reduction in carrier transport time directly leads to a significant\ncompression of carrier residence time within the active layer, thereby substantially lowering the\nprobability of bulk recombination. Beyond mitigating bulk losses, the gradient structure also\nprofoundly impacts interface recombination. By promoting the pre-separation and directed pushing of\ncarriers towards their respective transport layers before they even reach the interface, it reduces the\nreliance on perfectly aligned energy levels at these heterojunctions. Moreover, the gradient intrinsically\nsmooths the energy level transition between the perovskite and the transport layer. This effectively\ncircumvents the abrupt band offsets typically found at conventional interfaces, thereby further\nminimizing charge accumulation and mitigating interface recombination.\nThese analyses can be experimentally corroborated by Current–voltage characteristics (Fig. S4),\nMott-\nrevised the main text as follows (Page 7):\n“To verify the formation of compositional and band-structure gradient in the perovskite film, in-depth\nX-ray photoelectron spectroscopy (XPS) analysis is first employed, revealing Sn:Pb ratio evolves\ngradually from 0.05:0.95 at the surface to 0.4:0.6 in the bulk (Fig. S9). Ultraviolet photoelectron\nspectroscopy (UPS) measurement in Fig. S10 is then employed to reveal the band structure, giving\ndetail band alignment in Fig. 1g. It shows a type-II heterojunction between the Pb-Sn alloy region with\nband gap around 1.33 eV and Pb-rich surface layer with band gap around 1.50 eV. This continuous\ngradient results in a progressive spatial tilting of both the conduction band minimum (CBM) and\nvalence band maximum (VBM) across the entire active layer, effectively generating a built-in electric\nfield. The Mott-Schottky analysis in Fig. S11 furtherreveals an enhancement of built-in potential from\n0.58 V in homogeneous film to 0.66 V in the gradient film. This built-in field actively drives photo-\ngenerated electrons towards the lead-rich region (orange arrow) and holes towards the tin-rich region\n(blue arrow) via directional drift, thereby transitioning carrier transport from diffusion-dominated to\nefficient drift-dominated. As a result, acceleration of charge separation and transport, substantially\nshortening carrier transit and residence time within the active layer can be expected. The observation\nof faster rise and fall times in the photoresponse of the graded heterojunction (Fig. S12) provides\nevidence for the improved carrier transport kinetics.”\n4. Figure S7 shows that the Sn/Pb ratio varies with depth. Please explain the cause of this variation\nand discuss its impact on the material's optical and electronic properties, particularly in relation to\ncarrier mobility and band structure. How does this variation contribute to device performance?\nReply:\nThank you for your insightful questions regarding the Sn/Pb gradient. The compositional gradient\nobserved in our devices, particularly the variation of the Sn to Pb ratio with depth, indeed primarily\nstems from our meticulously designed two-step vapor deposition process. This process, along with\nsubsequent thermal treatments, is crucial for achieving this finely tuned gradient structure.\nFirst, during our initial vapor deposition step, we co-evaporate SnI and PbI onto the substrate. This\n2 2\n17\nprocess forms a relatively uniform SnI /PbI mixed layer at the bottom of the film. Subsequently, in\n2 2\nthe second vapor deposition step, we intentionally cease the deposition of SnI and instead deposit\n2\nonly pure PbI forming a thin PbI capping layer over the mixed layer created in the first step. At this\n2 2\npoint, through these two deposition steps, we obtain a distinctly layered with stepped precursor\nstructure: the upper layer is rich in PbI , while the lower layer is a mixture of SnI and PbI . However,\n2 2 2\nat this stage, the change in the Sn/Pb ratio is relatively abrupt, and the desired smooth gradient has not\nyet formed.\nWhat truly transforms this stepped structure into a smooth gradient is the subsequent reaction and\nthermal treatment process, the reaction with methylammonium iodide (MAI) vapor and the crucial\n180°C thermal annealing. Under elevated temperatures, thermally activated interlayer diffusion\nbecomes highly significant. Sn and Pb ions begin to migrate between the two layers. Owing to the\ninitial concentration differences and the intrinsic diffusion dynamics of these ions within the perovskite\nlattice, this process smooths out the initially abrupt compositional distribution. Within the limited\nannealing time and temperature, continuous ion exchange and diffusion ultimately establish a\ncontinuous gradient, leading to a Pb-rich surface region and a gradual increase in tin content with depth\ninto the film, thereby forming the Sn/Pb gradient distribution with a Pb-rich surface as shown in Fig\nS9.\nOptically, this meticulously crafted Pb/Sn gradient establishes a continuous bandgap variation across\nthe perovskite film in the vertical direction, ranging from approximately 1.33 eV at the bottom to 1.50\neV at the surface. Concomitantly, this gradual change in bandgap is inherently accompanied by a\nrefractive index gradient. As light enters the material from the air, this smooth transition in refractive\nindex effectively minimizes reflection losses at the interface, thereby ensuring efficient broadband\nabsorption from the visible to the near-infrared spectrum. These profound optical enhancements lay a\ncrucial foundation for subsequent efficient charge separation and collection.\nElectrically, as mentioned in the previous comments, the gradient bandgap profile creates a powerful\nbuilt-in electric field extending across the perovskite layer. This intrinsic electric field is critical for\nfacilitating highly efficient, drift-dominated transport of photogenerated carriers. It effectively guides\nelectrons and holes towards their respective selective transport layers, significantly accelerating their\nseparation and transport. This rapid carrier movement profoundly reduces the overall carrier transit\n18\ntime within the device, thereby substantially boosting the intrinsic mobility of the entire perovskite\nfilm.\nThe synergistic interplay of these optical and electrical improvements directly translates into enhanced\noverall device performance. Specifically, the gradient structure ensures a high EQE, particularly in the\nnear-infrared region, by optimizing light capture and utilization. Furthermore, the significantly\nimproved carrier transport underpins a remarkably faster device response. Crucially, the inherent\ndesign of this gradient features a dense Pb-rich surface layer (effectively acting as encapsulation),\nplays a vital role in mitigating the degradation of Sn2+ from exposure and oxidation, thereby ensuring\nthe device’s excellent long-term stability.\nIn the revision, we reorganized the discussion from page 6 to page 8 according to the following\nsequence to clarify the formation of graded Sn/Pb distribution and its merit on properties and device:\nParagraph 1 in page 6, descripts the deposition sequence to the formation of graded structure.\nParagraph 2 in page 6 shows the structure and component analysis by XRD, Absorption, and PL.\nParagraph 3 in page 6 proves the effective prevention of Sn2+ oxidation in the graded structure by PL,\nand XPS.\nParagraph 2 in page 7 verifies the Sn/Pb gradient and graded band structure in the film by XPS and\nUPS, and discuss its effect on charge transport to improve the device performance.\nParagraph 1 in page 8 shows the improvement on the device performance including responsive range,\nresponsivity and EQE.\nAll the revision are highlighted in the main text.\n5. The manuscript mentions good performance under different illumination conditions, but does not\naddress the performance under high light intensity backgrounds. Please provide data on the device's\nperformance under strong light backgrounds and discuss its stability, particularly focusing on dynamic\nrange and saturation behavior under these conditions.\nReply:\nnew Supplementary Information figures to address this directly.\n(1) Stability under strong light intensity: We evaluated the long-term operational stability of the device\nunder continuous illumination at an optical power corresponding to the upper limit of its linear\ndynamic range. Over a testing period of 600 hours, the device maintained a stable on/off ratio\nwithout significant performance degradation. These results demonstrate that the photodetector\nexhibits good operational stability even when working near its saturation intensity under strong\nlight background conditions. The relevant data is presented in the new Supplementary Fig. S8.\nFig. R2 Long‑term operational stability under varying optical intensities. Continuous on/off\nswitching tests of 600 hours were performed on a graded heterojunction device (Δd = 80 nm). The\noptical intensities were (a) 1.5 mW cm−2, (b) 12 mW cm−2, and (c) 140 mW cm−2. Measurements\n20\nwere conducted at zero bias using an 850 nm LED with a 4 s switching period (50% duty cycle).\nThe left and right panels in each row show enlarged segments from the beginning and end of the\ntest, respectively.\n(2) Performance under strong background light: We measured the dynamic range of one photodiode\nwith the BPPU device under different background light powers (Fig. R3). First, an important and\nwidespread scenario is to detect faint signal under strong background. Fig. R3 shows that the\nlowest detecting power increases as the background power increases. At 42.18 mW, the lowest\ndetecting power is 530 nW, which is 98 dB less than the background. There are three factor limiting\nthe lowest detecting power: ① The stability of the light source decreases as its power increases,\nintroducing noise into the photodiodes. ② Intense background illumination causes each sub-\nphotoelectric diode to generate a large amount of photocurrent. This current itself introduces\nsignificant electrical noise. ③ Under strong illumination conditions, an increase in temperature\ncan also lead to thermal noise. The combined noise effects collectively raise the overall noise floor\nof the device, thereby limiting the lower limit of the dynamic range. Second, under strong\nbackground, both photodiodes are in the \"on\" state. The non-linear series resistance will lead to\nnon-linear voltage distribution on both diodes. This will cause the decrease in photoresponse as\nshown in Fig. R3. However, it does not saturate even to a power of 140 mW, which means that the\nBPPU still work.\nFig. R3 The dynamic range of the BPPU device under different background light powers.\nIn the revised manuscript, we have expanded the discussion：\nlayer show superior operational stability than the homogeneous control sample, with on-off switching\ncharacteristics remaining virtually unchanged after long-term continuous operation exceeding 700\nhours (Fig. S7) and demonstrating remarkable photostability even under strong light irradiation (Fig.\nS8).”\nIn manuscript (Page 11): “Even under a 42.18 mW intense BG illumination, a target signal down to\n530 nW can be still successfully extracted from the strong BG (Fig. 2i), which corresponds to an\ninterference level 98 dB stronger than the target signal. This robust performance iscorroborated by the\ndynamic range measurements under strong background illumination (Fig. S18).”\nFig. R3 is appended as Fig. S18 and the discuss in Supplementary Information (Page S15):\n“Fig. S18 shows that the lowest detecting power increases as the background power increases. The\nlowest detecting limit depends on the stability of the light source, photoelectrical noise and thermal\nnoise. Under strong background, the photoresponse of one photodiode decreases while not saturate\neven to a power of 140 mW. The BPPU still works.”\n6. Please explain why the background current values in Figure 2i differ significantly among the three\nsets of tests, whereas the test deviations under different light intensities in Figure 2g are much smaller.\nReply:\nWe greatly appreciate pointing out the problem in Fig. 2i. We check our experimental record and find\nthat this should come from the instability and non-uniformity during the warm-up period of the high-\npower LED array. After warm-up, the intensity is stable and uniform, and the background current keeps\nless than 10 nA. The motion tracking under strong background illumination is re-measured in Fig. R4,\nas shown in the following:\nby an 860 nm LED array (42.18 mW), with spot intensities 1.19 μW, 719 nW, and 530 nW. The colored\nshading represents the spatial responsivity profile across the extended BPPU array.\n7. The current value corresponding to the light intensity of 2 mW/cm² in Figure 2e is approximately\n10 μA, whereas the zero-bias current in Figure S12 is much smaller than 0.1 μA. Please verify the\naccuracy and reliability of the data.\nReply:\nWe thank the reviewer for the detailed question. Fig. 2e and Fig. S12 demonstrate the performance of\nthe BPPU under different configurations. To avoid misunderstanding, we added specific measurement\nsetup in the inserts of each figure as shown in Fig. R5.\nFig. R5 a,The photocurrent response for each photodiode in BPPU with respect to power intensity at\n860 nm under 0 V. The red line is the linear fitting of the LDR. b, The current-voltage characteristics\n23\nof the BPPU under reverse bias and forward bias under 860 nm illumination. c. Background\nsuppression capability of the extended BPPU under V = V = 0 V, measured under background\nA B\nillumination from an 860 nm LED array.\nFirst, Fig. 2e measures the performance of separate sub-photodiode D1 and D2 in the BPPU as shown\nin Fig. R5a, in which one photodiode is illuminated while the other keeps dark using a mask. This\nmeasurement illustrates the high performance of each photodiode and the uniformity between D1 and\nD2.\nSecond, Fig. S12 measures the unit performance of BPPU as shown in Fig. R5b, in which both D1\nand D2 are illuminated by an LED Array to ensure illumination intensity on D1 and D2 is uniform.\nSince the D1 and D2 is in back-to-back series connection, the zero-bias photocurrent should be\ncanceled, and thus the measure current should much smaller than that in Fig. 2e.\nIt is through the above optimization of photodiode and the design of units that strong background\nillumination could be suppressed to less than 10 nA as shown in Fig. R5c.\nTo prevent similar confusion for readers, the above figures and caption are revised.\nIn the caption of Fig. 2e (Page 9): “e, The photocurrent response for each photodiode in BPPU with\nrespect to power intensity at 860 nm under 0 V. The red line is the linear fitting of the LDR. These\nLDR measurements were conducted by illuminating on a sub-diode within the BPPU to assess its\nintrinsic photoresponse performance.”\nIn the caption of Fig. S14 (originally Fig. S12, now renumbered as Fig. S14, Page S14): “Fig. S14\nBipolar I–V characteristics. The current–voltage characteristics of the BPPU under reverse bias and\nforward bias under 860 nm illumination. These curves were obtained under uniform illumination\nacross the entire BPPU, ensuring both sub-diodes were simultaneously illuminated. The minuscule net\ncurrent observed at 0 V highlights the inherent symmetry between the two sub-diodes and the effective\ncancellation of their photocurrents.”\n8. For biomedical imaging: What is the signal-to-noise ratio improvement from edge detection?\nHow\nand accuracy and contrast compare with conventional Sobel or Laplacian digital filters?\nWe thank the reviewer for the insightful question. Below we give detailed explanations.\n(1) Signal-to-noise ratio improvement: Edge detection does not improve traditional signal-to-noise\nratio (SNR), but it significantly enhances edge-specific SNR. We have conducted an evaluation\nusing the edge-specific SNR calculation method described in the referenced paper\n(Neurocomputing 2022, 503, 259–271): , where\n2\n∑(𝐼𝑖(𝑚𝑥,𝑛𝑦))\nrepresents the gray value of the ideal 𝑆gr𝑁o𝑅un=d t1ru0t𝑙h𝑜 v𝑔a1l0u∑e( a𝐼𝑑t (p𝑚i𝑥x,e𝑛l𝑦 )−𝐼𝑖(𝑚𝑥,𝑛𝑦) ) 2of an image\n𝐼(𝑖I(n𝑚 o𝑥u,r𝑛 e𝑦v)aluation, the ideal edge reference is obtained by applying convent(i𝑚on𝑥a,l𝑛 d𝑦i)gital filters to\nthe original image.), represents the gray value of the detected edge map at pixel of\nthe image. 𝐼𝑑 (𝑚𝑥,𝑛𝑦)\nThe BPPU achieves an edge-specific signal-to-noise ratio (SNR) of 16.7 dB for in-sensor\nfingerprint edge detection (Fig. R6a), marking a 101% improvement compared to the 8.3 dB of\nthe original image (Fig. 4a)\n(2) Accuracy analysis: We performed a pixel-by-pixel comparison between the hardware edge\ndetection results from BPPU and the edge localization results obtained by applying digital filters\nto the same original image. The coincidence rate between the BPPU output and the digital results\n(Fig. R6b) reached 95.5%, indicating a high level of agreement in edge localization. The slight\ndiscrepancies observed between the BPPU output and the digitally processed results primarily stem\nfrom inherent spatial site deviations due to continuous convolution in the analog domain versus\nconvolution on digitized discrete images, rather than performance flaws. This is a normal\nphenomenon under different computational paradigms.\n(3) Contrast analysis: We used the Root Mean Square (RMS) contrast metric to evaluate and compare\nthe contrast of edge detection results from different methods. The RMS contrast is a widely\naccepted metric that quantifies the overall luminance variation in an image. The RMS contrast is\ncalculated using the following formula: , where N denotes the total\n1 𝑁 2\nnumber of pixels in the image, represent𝐶s𝑟 𝑚th𝑠e =int√en𝑁s∑ity𝑖 ((𝐼g𝑖r−ay𝐼s)c̅ ale value) of the i-th pixel, and\nis the mean intensity across al\n𝐼\nl𝑖 pixels.\n𝐼𝑖\nwith higher contrast (0.111) compared to conventional Sobel (0.088) and Laplacian (0.065)\ndigital\nfilters (Fig. R6c, d). This improvement directly translates to clearer, more clinically useful edge\nrepresentations in biomedical imaging applications.\nFig. R6 Edge detection via different processing schemes. a, Direct in-sensor edge detection result\nobtained from the BPPU. b, Edge detection result computed from conventional BPPU imaging data.\nc, Edge detection using the Sobel operator ( + ) applied to conventional\n−1 −2 −1 −1 0 1\n[ 0 0 0 ] [−2 0 2]\n1 2 1 −1 0 1\nBPPU imaging data. d, Edge detection using the Laplacian operator ( ) applied to\n1 1 1\n[1 −8 1]\nconventional BPPU imaging data.\n1 1 1\nBased on the above analyses, we have correspondingly revised the main text and Supplementary\nInformation as follows:\nIn manuscript (Page 16): “Notably, the resulting discretized edge map shows a 101% improvement in\nedge-specific SNR, alongside 95.5% agreement with conventional digital processing outputs and\nhigher contrast compared to conventional Sobel or Laplacian digital filters (Fig. S23).”\n“Signal-to-noise ratio analysis: The edge-specific SNR calculation method described in the\nreferenced literature67: , where represents the gray\n2\n∑(𝐼𝑖(𝑚𝑥,𝑛𝑦))\nvalue of the ideal ground𝑆 𝑁tr𝑅uth= v1a0lu𝑙e𝑜 𝑔at1 0p∑ix(e𝐼𝑑l (𝑚𝑥,𝑛𝑦)−𝐼𝑖(𝑚 o𝑥,f𝑛 a𝑦)n) 2image (In𝐼 𝑖o(u𝑚r 𝑥e,v𝑛a𝑦lu)ation, the ideal edge\nreference is obtained by applying conventiona(l 𝑚di𝑥g,i𝑛ta𝑦l )filters to the original image.), represents the\ngray value of the detected edge map at pixel of the image. The BPPU a\n𝐼\nc𝑑hieves an edge-\nspecific signal-to-noise ratio (SNR) of 16.7 d(B𝑚 f𝑥o,r𝑛 𝑦in)-sensor fingerprint edge detection (Fig. 4b),\nmarking a 101% improvement compared to the 8.3 dB of the original image (Fig. 4a).\nAccuracy analysis: A pixel-by-pixel comparison revealed a 95.5% coincidence rate between the edge\ndetection results from the BPPU hardware and those from digital filters (Fig. S23b) applied to the\nsame image, confirming a high degree of agreement in edge localization.\nContrast analysis: The Root Mean Square (RMS) contrast metric used to evaluate and compare the\ncontrast of edge detection results from different methods. The RMS contrast is calculated using the\nfollowing formula: , where N denotes the total number of pixels in the image,\n1 𝑁 2\nrepresents the int𝐶en𝑟𝑚si𝑠ty= (g√ra𝑁y∑sc𝑖a(le𝐼𝑖 v−al𝐼u)̅e) of the i-th pixel, and is the mean intensity across all\n𝐼 p𝑖ixels. RMS contrast analysis confirms the superiority of our BPPU 𝐼𝑖 method (C RMS, BPPU = 0.111, Fig.\nS23a) over conventional Sobel (C = 0.088, Fig. S23c) and Laplacian (C = 0.065,\nRMS, Sobel RMS, Laplacian\nFig. S23d) filters in producing higher-contrast edge images.”\n9. For trajectory encoding: What is the temporal resolution and minimum detectable velocity?\nReply:\nWe thank the detailed question.\n(1) Temporal resolution: The system exhibits a temporal resolution of 33 ns. This value corresponds\ndirectly to the stated device response speed (Fig. 2f) and represents the minimum time interval\nrequired for the system to distinguish or respond to a motion event.\n(2) Maximum detectable velocity: We measured the response of the BPPU to the rapidly moving light\nspot. Specifically, with a center-to-center distance of 2.5 mm between the two sub-photodiodes,\nthe rapidly moving light spots generated positive and negative signals, as illustrated in Fig. R7.\nThe traverse time of the light spot driven by the galvanometer at its maximum speed was 48 μs,\nwhich corresponds to a calculated moving speed of 52.1 m s−1 (or 187 km h−1). This velocity\nexceeds the requirements for most trajectory tracking applications.\nIt is important to note that the measured speed is limited by our motion measurement platform,\nbut not the BPPU. Based on the bipolar switching response speed of 33.0 ns (Fig. 2f), an estimated\nspeed limit for the BPPU is 7.6×104 m s−1, which is more than 1000 times faster than the measured\nvalue.\nIt is important to note that the measured speed is limited by our motion measurement platform,\nbut not the BPPU. Based on the bipolar switching response speed of 33.0 ns (Fig. 2f), an estimated\nspeed limit for the BPPU is 7.6×104 m s−1, which is more than 1000 times faster than the measured\nvalue.\nFig. R7 The response of the BPPU to rapidly moving light spots. The spot motion was generated\nusing a galvanometer, with a maximum simulated trajectory velocity of 52.1 m s−1.\nThe relevant results are provided in the Supplementary Information and discuss in manuscript:\nIn manuscript (Page 22): “These results confirm the system's robust discrimination capability, even for\nperceptually similar motion patterns under challenging conditions. Fundamentally limited by a 33‑ns\ntemporal resolution, the BPPU-based system can directly encode extremely fast motion. The\ncorresponding theoretical maximum detectable velocity of 7.6×104 m s−1 (discussed in Fig. S30),\nallowing the system to capture and classify rapid trajectories that would otherwise be blurred or missed\nby standard imaging systems.”\nmoving light spots.With 2.5 mm between the two sub‑photodiodes, the observed 48 µs delay between\npositive and negative signals corresponds to a speed of 52.1 m s⁻1 (or 187 km h⁻1). This result—already\nsufficient for most tracking applications—was limited by the galvanometer’s speed, not by the device\nitself. The intrinsic bipolar switching time of the device is 33.0 ns (Fig. 2f). Based on this, the\ntheoretically detectable speed reaches 7.6×104 m s⁻1, far exceeding typical application requirements.”\nThis paper presents a graded Pb-Sn alloyed perovskite heterojunction photodiode fabricated from a full\nvapor deposition process, achieving broadband response from visible to infrared, an ultra-large linear\ndynamic range of 238 dB, and a fast response time of 33 ns. The authors further develop a wafer-scale\nin-sensor computing network, demonstrating its application in biomedical imaging and spatiotemporal\ntrajectory encoding. The work is highly compelling, showcasing significant advancements in material\ndesign, device performance, and system integration for intelligent machine vision. It is recommended\nthat the authors address the points raised below to further strengthen the manuscript.\n1. The manuscript contains several instances of non-standard unit formatting. For example, in line 151,\na space is missing between the numerical value and its unit.\nReply:\nThank you for your careful attention to the formatting details. We have thoroughly reviewed the\nmanuscript and corrected all unit formats to ensure a single space is present between numerical values\nand their units (e.g., “850 nm” instead of “850nm”).\n2. While XPS/UPS data confirm a Sn/Pb gradient in a localized area, the uniformity and reproducibility\nof this gradient across the entire wafer scale remain unverified. To robustly demonstrate the\ncontrollability of this deposition process for scalable manufacturing, please provide additional data.\nReply:\nThanks for raising the important point. To verify the uniformity and reproducibility, we perform XPS\nprofiling on 5 different positions across a wafer-scale sample and on samples from four different\nbatches in Fig. R8. The results show the same gradient characteristic across a full 4 inch wafer in Fig.\nR8a. The profiles shape slightly changes between batches, but the gradient keeps the same in Fig. R8b.\nIt supports the uniformity and reproducibility of our deposition technique in fabricating the gradient\nstructure.\nat five different positions across a wafer-scale sample. b, XPS profiles demonstrating the Sn/Pb\nelemental gradient obtained from samples of four different batches.\nThe Figures are appended as Fig. S20 in the revision, and description is revised in manuscript (Page\n14):\n“Quantitative verification of film uniformity was achieved by measuring PL peak positions across 17\npositions (Fig. 3c, Fig. S19), revealing a standard deviation of only 2.21 nm. To further confirm the\nreliability of our deposition technique, the uniformity and reproducibility of the Sn/Pb gradient\nstructure were assessed via XPS profiling, which shows high consistency over batches (Fig. S20).\nSuch exceptional homogeneity ensures high device-to-device consistency (Fig. S21).”\n3. The PL stability data indirectly suggest suppressed Sn2+ oxidation. To provide direct chemical\nevidence, I recommend comparing the Sn 3d XPS spectra, including depth profiling, of the\nhomogeneous and graded heterojunction films before and after aging. This would visually demonstrate\nthe effective suppression of Sn4+ formation in the graded structure.\nReply:\nWe thank the reviewer for the specialized question. First, it should be noted that the use of XPS for\ndepth profiling requires the use of ion bombardment for etching. One well-known side effect of ion\nbombardment is the reduction of high-valence state metal ions in perovskite. Although this effect does\nnot affect the analysis of different components such as Pb and Sn, it does have a serious impact on the\nanalysis of different valence states within the same component. This is the reason why we use PL but\nnot XPS to analysis the Sn2+ oxidation initially.\nFortunately, Thermo Fisher Scientific released a new XPS instrument equipped with state-of-the-art\nfemtosecond laser ablation (fs-LA) depth profiling system in Dec. 2025. This advanced technique\nenables ultra-fast evaporation by fs laser to avoid high-energy bombardment and heat accumulation\non the surface, thus preserving the intact valence state. As a result, reliable chemical state analysis of\norganic–inorganic halide perovskite-based devices by XPS can now be accurately monitored.\nWe were lucky enough to be able to book a trial session，and we conducted the experiments following\nthe reviewer’s suggestion, as shown in Fig. R9. Both homogeneous and graded structure thin films\nwere aged for 18 hours in an atmosphere of 30% O + 70% N . Due to the waiting period for the\n2 2\ninstallation and commissioning of the Thermo Fisher Scientific Hypulse XPS system (the first of its\nkind), all the samples were stored in conventional packaging for approximately one month before fs-\nLA XPS depth profiling was performed.\nfemtosecond laser ablation levels (A.L.) from the top surface. a, Homogenous structure perovskite. b,\nGraded heterojunction perovskite. Variation of the Sn4+ ratio across the c, homogenous structure film\nand the d, graded heterojunction structure film derived from fs-LA XPS profiles with different ablation\nlevels.\nThe Fig. R9 clearly demonstrates that after aging, the Sn4+ content in the homogeneous structure\nperovskite increased from ~20% to ~35% within the bulk, and the film surface was found to be highly\nsusceptible to oxidation. In contrast, the graded structure film exhibited no significant change in Sn4+\ncontent across the entire depth after aging. The result confirming the effective encapsulation and\nprotection of Sn2+ by the Pb-rich surface layer.\nBoth of them help to understand the protection effect of Pb-rich layer from different aspects.\nIn manuscript (Page 7): “The effective encapsulation and protection of Sn2+ oxidation was further\nconfirmed through femtosecond laser ablation XPS depth profiling of the aged samples (Fig. S6).”\n4. The 700-hour operational stability test shown in Fig. S6 is a key result. However, the critical\nparameters of the optical stimulus used for the \"on-off switching\" test are not specified. Please provide\nthese details. In addition, is there a difference in the durability of devices under different light intensity\nstimuli?\nReply:\nThank you for your valuable comment regarding the long-term operational stability test. We have\nsupplemented the necessary experimental details and additional data as follows:\n(1) Details of the operational stability test: The key parameters of the optical stimulus used in the 700-\nhour on–off switching test was operated at zero bias, and the periodic switching was driven by an\n850 nm LED with an irradiance of 100 μW cm-2 and a switching period of 4 s. This information\nhas been incorporated into the caption of Fig. S7 (originally Fig. S6, now renumbered as Fig. S7,\nPage S5).\n“Fig. S7 Long-term operational stability. Continuous on/off switching tests over 700 hours for\nthe photodiodes based on (a) the control perovskite film and (b) the Δd = 80 nm graded\nheterojunction film. Measurements were conducted at zero bias using an 850 nm LED with an\nirradiance of ~100 μW cm−2 and a 4 s switching period (50% duty cycle). The left and right panels\nin each row show enlarged segments from the beginning and end of the test, respectively.”\n(2) Durability under different optical intensities: In response to your question, we conducted additional\ndurability tests under higher irradiances (1.5 mW cm−2, 12 mW cm−2, and 140 mW cm−2) at the\nsame wavelength and switching period (Fig. R10). Over an extended testing period of more than\n400 hours, the devices maintained stable on/off ratios without significant degradation. These results\nindicate that the operational stability of the device is robust across a wide range of illumination\n34\nintensities relevant to practical application scenarios. The relevant results are provided in the\nSupplementary Information Fig. S8 (Page S6).\nFig. R10 Long‑term operational stability under varying optical intensities. Continuous on/off\nswitching tests of 600 hours were performed on a graded heterojunction device (Δd = 80 nm). The\noptical intensities were (a) 1.5 mW cm−2, (b) 12 mW cm−2, and (c) 140 mW cm−2. Measurements\nwere conducted at zero bias using an 850 nm LED with a 4 s switching period (50% duty cycle).\nThe left and right panels in each row show enlarged segments from the beginning and end of the\ntest, respectively.\n5. In Figure 2a, the labels for the material layers in the device structure are missing.\nReply:\noversight. Clear text labels for all functional layers in the device structure have now been added to the\nrevised Fig. 2a, as shown in the Fig. R11.\nFig. R11 Schematic structure of a single BPPU.\n6. To unequivocally verify that the noise reduction stems from correlated noise common-mode\nrejection in the back-to-back configuration—rather than inherently low noise in each individual\nphotodiode—please provide the independent noise current spectra for both sub-photodiodes (D1 and\nD2) measured at zero bias.\nReply:\nWe fully agree with the reviewer. To clearly demonstrate this common-mode rejection effect, we\nmeasured the dark current in the time domain for both individual photodiodes and the cascaded\nconfiguration, where it manifests as low-frequency noise and offset. These time-domain measurements\nvisually illustrate the significant reduction in average dark current from typically ±10 pA for each\nindividual photodiode to below ±2.5 pA for the back-to-back configuration (Fig. R12), confirming the\nself-cancellation of correlated leakage currents and correlated noise common-mode rejection.\nThe relevant sentence has been updated to incorporate the new evidence and improve clarity in\nmanuscript (Page 10):\n“Building upon this back-to-back cascading configuration, leakage currents are self-cancelled as\nshown in Fig. S15, suppressing the noise current to 7.44×10−14 A Hz−0.5 under 1 Hz as shown in Fig.\n2d.”\n7. The reported ultra-fast response time (33 ns) is remarkable. Please specify the intensity of the optical\npulse used in this measurement.\nReply:\nThank you for your comment on the response time measurement. The intensity of the optical pulse\nused for the response time characterization has been specifiedin the description of Fig. 2f (Page 9).\n“f, The bipolar switching photoresponse time of the BPPU, measured at 0 V bias under 660 nm laser\nillumination with a light intensity of 1 mW cm−2 and a modulation frequency of 1 MHz.”\n8. The authors’ explanation that the speed improvement arises from the reduced effective capacitance\nin the back-to-back structure is theoretically reliable. However, in addition to this theoretical\ninterpretation, the response speed of a single device should also be measured and compared with that\nof the composite structure to provide practical verification.\nWe appreciate the insightful question. We provided the response speed of a standalone single device\nin Fig. R13, which show rise/fall time of 91 ns/97 ns. In a series-connected back-to-back structure\nwhen only one of the two photodiodes is illuminated, the response speed is 38 ns/39 ns. This new\nmeasurement provides more direct and compelling evidence for the reduction in effective capacitance.\nIt clearly demonstrates that simply configuring the photodiodes in a back-to-back series connection\nsignificantly improves the response speed. We have updated the relevant section in the main text to\nrefer to this new comparative Fig. S17 and further elaborate on this experimental validation.\nFig. R13 Response time of a, single photodiode and b, back-to-back structure BPPU with only one\nphotodiode illuminated. The measurement was performed at 0 V bias using a 660 nm laser at an\nintensity of 1 mW cm−2 and a modulation frequency of 500 kHz.\nIn manuscript (Page 11): “The BPPU achieves ultrafast bipolar photoresponse speed of 33.0 ns rise\ntime and 37.4 ns fall time (Fig. 2f). It results from the cascaded architecture. The back-to-back\nconnected diodes’ equivalent capacitance ( ) reduces by 50% compared to single-\n𝐶1𝐶2\nphotodiode configurations. The comparative d𝐶at 𝑒 a 𝑞 i=n F𝐶1ig+.𝐶 2S17 provides direct experimental validation\nfor this capacitance reduction effect.”\n9. When the background illumination incident on the sensor array is not perfectly uniform (for example,\nwhen gradients or localized shadows are present), D1 and D2 will experience different light intensities.\nCould this lead to a degradation of the background-suppression effect, or even generate spurious\nsignals?\nReply:\nWe thank the reviewer for the constructive question. It is quite true as the reviewer point out the\nbackground can not be fully suppressed, but it can be significantly suppressed to a low level for easy\nfeature extraction and improve the recognition rate.\nFor example, the gradient can be still decreased by the difference operation (Fig.4 c). Especially, the\nnon-uniform effect is minimized if it only smoothly changes. On the contrary, large interference may\narise at the boundary of local shadows. Please note in real applications, most of the useful information\nlie inside the shadow area rather than on the boundary. For instance, in the imaging of vein in Fig. R14\n(Fig. 4d–f), due to different transmission length in the finger, there is a high illuminated area (indicated\nby yellow arrows) along the edge of the finger towards the inside. And all the palm can be regarded as\nshadow area. However, it does not affect the vein feature extraction. The BPPU successfully\ncompresses the saturated signal from the high illumination part. The local high boundary signal do not\naffect the shadow region. In addition, for more complicate background conditions or tasks, a\nsophisticated kernel beyond simple difference operation may be required. The ability to program the\nkernel is shown in Fig. 3f, which could meet the application in different scene.\nFig. R14 In-sensor imaging and processing. a, Photograph of a hand with an inset showing the\nimaging part in (b & c). b-c, Vein imaging via NIR (b) conventional imaging where the veins in shadow\nare fully blurred by the bright part and (c) edge detection, where the veins are clear in the same\ncondition of (b). The dashed lines outline the localized subcutaneous veins.\n39\n10. The manuscript reports an ultrahigh linear dynamic range of 238 dB together with a zero-bias EQE\nof ~61% at 850 nm, which is an excellent performance combination. To conclusively demonstrate that\nthe photoresponse remains linear across the entire dynamic range, and that the high EQE is not limited\nto a specific illumination level, please provide EQE curves measured under varying incident light\nintensities.\nReply:\nWe thank the reviewer for the detailed questions. To address your request for EQE curves measured\nunder varying incident light intensities, we have performed additional measurements. Fig. R15a in the\nrevised manuscript now presents full EQE spectra measured for incident optical powers ranging from\n~ 0.1 μW to ~ 1 μW (at 860 nm). Within this range, the EQE curves show negligible variation,\nconfirming the stability of the EQE at these illumination levels.\nHowever, obtaining full spectral EQE curves at significantly lower or higher powers was limited by\nthe capabilities of our Enlitech QE-C system. To thoroughly investigate the linearity of the\nphotoresponse across a much broader incident power range, we meticulously measured the\nphotocurrent as a function of incident optical power at 860 nm, as shown in Fig. R15b. From this data,\nwe calculated the EQE across the entire investigated power range.\nFig. R15 Dependence of EQE on incident light intensity. a, EQE spectra measured over a range of\nincident optical powers (~0.1 μW to ~1 μW). b, Photocurrent (left axis) and the extracted EQE (right\naxis) plotted against incident optical power at 860 nm.\nit does deviate from linearity at higher incident optical powers, leading to a decrease in both\nresponsivity and EQE. This non-linear phenomenon was not fully accounted for in our initial\ncalculation of the linear dynamic range.\nBased on this more accurate characterization of the device’s response and the precise definition of\nresponsivity within the linear operating regime, we have re-evaluated the linear dynamic range.\nConsequently, we have revised the reported linear dynamic range from 238 dB to 230 dB in the updated\nmanuscript, and the corresponding data in Fig. 2e has been updated accordingly. We believe these\nadditional data and the revised dynamic range provide a more accurate and comprehensive\nunderstanding of our device’s performance.\n41"}, {"round": 2, "reviewer_comments": {"reviewer_1": "The authors have addressed my concerns and this paper can be accepted by Nature Communications now.", "reviewer_2": "The revisions have effectively addressed my concerns. I am satisfied with the revised manuscript and recommend it for\npublication in Nature Communications.", "reviewer_3": "The authors have addressed all my concerns, I recommend this paper to be accepted by Nature Communications now."}, "author_response": ""}]

Decision letter