(A) Illustration of population Ca imaging from the visual cortex in a head-fixed awake mouse on a spherical treadmill during viewing of three types of visual stimuli: square or sine wave grating, natural movie, and dark screen. For clarity, the head fixation was omitted from the drawing. Inset: Two-photon microscopic image of a typical field of view from neurons bolus-loaded with Oregon Green Bapta-1 AM (OGB- 1) dye in layer 2/3 of V1. Regions of interest (ROIs, yellow) are overlaid on the image. (B) Inferred spike probability for two representative neurons during visual stimulation with sine-wave gratings (see (E)). Spike probability was inferred from calcium sensitive dye fluorescent signals using a spike inference algorithm (Methods). Spike probability was then thresholded (dashed red line) to a level of 3 SDs above 0, and converted to 1 (active) or 0 (inactive). (C) Raster plot of activity (moving gratings) constructed using the thresholded spike probability. Each row represents a single neuron, and each mark represents the inferred spiking activity of that neuron, i.e., the thresholded spike probability with value 1 (active). (D) “Network activity” (black) is the sum of all spiking neurons in a time bin (250 ms), i.e., the thresholded inferred spike probability summed over all recorded neurons in that time bin. A threshold (dashed red line) at median network activity defined the start and end of a “neuronal avalanche” as the time points of crossing this threshold. The avalanche size (gray) is the integrated network activity for the avalanche duration, i.e., the time between threshold crossings. (E) For the data in (B) to (D), moving gratings (100% contrast, 0.035 cycles per degree, two cycles per second) drifting in eight different directions in random order were presented for 5 s, followed by 5 s of mean luminescence gray screen.