position = global_invocation_id.xy;
        let color = textureLoad(ourTexture, position, 0);
        let v = srgbLuminance(color.rgb);
        let bin = min(u32(v * numBins), lastBinIndex);
        atomicAdd(&bins[bin], 1u);
      }
    `,
  });

  const pipeline = device.createComputePipeline({
    label: 'histogram',
    layout: 'auto',
    compute: {
      module,
    },
  });

  const imgBitmap = await loadImageBitmap('resources/images/pexels-francesco-ungaro-96938-mid.jpg'); /* webgpufundamentals: url