Edge detection is not one result. Roberts and Sobel disagreed on 7,101,949 of 12,000,000 pixels on the landscape photo — 59.183%. Sobel and Laplacian differed on 7,079,312, or 58.994%, of the same frame.
Strength does not find more edges. Raising it from 1.0 to 3.0 left the share of non-zero pixels unchanged at 60.238% while the share clipped to 255 rose from 6.352% to 16.479%. One batch of 11 decoded files produced edge maps whose density ran from 0.556% to 78.945% under the same settings.
This page measures what the operator choice, the strength control and the threshold do across a folder of mixed files. For other one-in-one-out operations on the same twelve files, see the batch invert measurement, the batch grayscale measurement, the batch sharpen measurement and the batch equalize measurement. For a rectangle across a folder, the batch crop measurement covers padding; for a blur radius family, the batch blur measurement covers three filters. For flipping, start at the photo flipper.
Twelve files, 20,934,926 bytes on disk and 63,016,384 pixels across the 11 that decoded. Every readable file was reduced to one grayscale channel, then filtered with three operators: Roberts cross, Sobel-Feldman and a 3 by 3 Laplacian. Each output was clipped to the 0 to 255 range, written as an 8-bit grayscale PNG, reopened and measured against the decoded input. Eleven files times three operators equals 33 edge maps; one truncated file produced nothing.
This is the gap the tool pages leave unmeasured. Three operators are offered as if they were three labels on one control. On a real photo they produce substantially different maps. The table counts pixels where the clipped 8-bit outputs of two operators differ, on the same decoded bytes.
| File | Pixels | Sobel vs Roberts | Sobel vs Laplacian | Mean abs gap |
|---|---|---|---|---|
| photo_landscape.jpg | 12,000,000 | 7,101,949 (59.183%) | 7,079,312 (58.994%) | 28.506 |
| photo_portrait.jpg | 12,000,000 | 7,115,458 (59.295%) | 7,089,387 (59.078%) | 28.554 |
| photo_square.png | 9,000,000 | 6,959,149 (77.324%) | 6,953,081 (77.256%) | 37.911 |
| duplicate_photo.jpg | 12,000,000 | 7,115,458 (59.295%) | 7,089,387 (59.078%) | 28.554 |
| exif_orient6.jpg | 3,000,000 | 1,742,519 (58.084%) | 1,742,552 (58.085%) | 30.411 |
| screenshot.webp | 1,440,000 | 817,011 (56.737%) | 814,805 (56.584%) | 31.377 |
| logo_alpha.png | 960,000 | 8,324 (0.867%) | 8,744 (0.911%) | 1.423 |
| gray_16bit.png | 480,000 | 2,668 (0.556%) | 2,669 (0.556%) | 0.823 |
| gray_8bit.jpg | 12,000,000 | 7,108,511 (59.238%) | 7,083,447 (59.029%) | 28.613 |
| animation.gif | 120,000 | 504 (0.42%) | 996 (0.83%) | 1.064 |
| small_icon.png | 16,384 | 11,526 (70.349%) | 11,542 (70.447%) | 48.921 |
| broken.jpg | truncated, failed to decode; no output written | |||
Mean abs gap is the average absolute difference between the two 8-bit outputs on a 0 to 255 scale. The two byte-identical portrait JPEGs produced byte-identical maps, so their rows match.
Non-zero pixels in an edge map are a direct count of where the operator found a boundary. Under one fixed Sobel setting the share ran from 0.556% on gray_16bit.png to 78.945% on photo_square.png; dividing the second by the first gives 142.0 (78.945 ÷ 0.556), using the two JSON density values in the table below. The three operators kept their own ordering on almost every file.
| File | Pixels | Roberts | Sobel | Laplacian |
|---|---|---|---|---|
| photo_landscape.jpg | 12,000,000 | 53.956% | 60.238% | 54.495% |
| photo_portrait.jpg | 12,000,000 | 54.469% | 60.364% | 54.738% |
| photo_square.png | 9,000,000 | 69.441% | 78.945% | 71.109% |
| duplicate_photo.jpg | 12,000,000 | 54.469% | 60.364% | 54.738% |
| exif_orient6.jpg | 3,000,000 | 52.793% | 58.98% | 54.441% |
| screenshot.webp | 1,440,000 | 49.904% | 57.203% | 54.055% |
| logo_alpha.png | 960,000 | 0.456% | 0.911% | 0.735% |
| gray_16bit.png | 480,000 | 0.412% | 0.556% | 0.524% |
| gray_8bit.jpg | 12,000,000 | 54.48% | 60.315% | 54.663% |
| animation.gif | 120,000 | 0.417% | 0.833% | 0.83% |
| small_icon.png | 16,384 | 69.122% | 69.891% | 67.133% |
Sobel produced the highest density on every readable file. On the four flat or sparse files — the logo, the 16-bit grayscale, the GIF and the small icon — all three operators stayed below 1% except the icon, where all three crossed 67%. File content, not just file size, decides whether a batch gets a useful edge map.
The strength multiplier scales the response before it is clipped to 8 bits. On photo_landscape.jpg, moving from 1.0 to 3.0 left the non-zero share pinned at 60.238% on every step, because scaling a positive magnitude cannot turn a zero into a non-zero. What changed was clipping: the count of pixels at exactly 255 climbed from 6.352% to 16.479%.
| Strength | Non-zero pixels | Clipped at 255 | Changed vs 1.0 |
|---|---|---|---|
| 0.5 | 57.467% | 1.371% | 7,064,096 px |
| 1.0 | 60.238% | 6.352% | — |
| 1.5 | 60.238% | 10.023% | 6,466,337 px |
| 2.0 | 60.238% | 12.731% | 6,466,337 px |
| 3.0 | 60.238% | 16.479% | 6,466,337 px |
Measured on photo_landscape.jpg with the Sobel operator. 'Changed vs 1.0' counts pixels whose 8-bit value differs from the strength 1.0 output; the 0.5 row changes values downward rather than adding edges.
Binarising the response replaces the grayscale with a white-or-black line map. The share of white pixels falls steadily as the threshold rises on the same landscape photo: 36.317% at 8, 24.39% at 32 and 12.699% at 128. That is a separate decision from strength and it changes far more pixels than the strength control does.
| Threshold | White pixels | White share |
|---|---|---|
| 0 | 762,245 | 6.352% |
| 8 | 4,358,028 | 36.317% |
| 16 | 3,533,790 | 29.448% |
| 32 | 2,926,812 | 24.39% |
| 64 | 2,272,496 | 18.937% |
| 128 | 1,523,873 | 12.699% |
At threshold 0 the output is the clipped grayscale itself, so the 6.352% figure counts pixels already sitting at 255. From 8 upward the map is binary. A high threshold keeps only the strongest responses, which is the nearest measured equivalent to a clean line drawing.
An edge operator should answer zero on a region with no change. A 20 by 20 patch at the top-left corner of each photo was uniformly zero before filtering, and the Sobel response on that patch was exactly zero with zero non-zero pixels. The 16-bit grayscale is the exception: its patch ran from 0 to 255 and produced a maximum response of 876.002, which clips to a visible line even in what looks like a flat corner.
| File | Patch min | Patch max | Max Sobel response |
|---|---|---|---|
| photo_landscape.jpg | 0 | 0 | 0.0 |
| photo_portrait.jpg | 0 | 0 | 0.0 |
| photo_square.png | 0 | 0 | 0.0 |
| logo_alpha.png | 0 | 0 | 0.0 |
| gray_16bit.png | 0 | 255 | 876.002 |
| small_icon.png | 0 | 1 | 4.0 |
The sparse files explain the low density in section 3. The logo started with 3 distinct gray levels and ended with 3; the GIF started with 2 and ended with 2. The 16-bit grayscale started with 256 levels at the filter stage and ended with 192. The small icon gained six levels, going from 250 to 256.
Reducing each file to one grayscale channel before filtering is a lossy step for file properties, even though the filter itself is deterministic. Four properties changed across the batch.
| File | Before | After | Note |
|---|---|---|---|
| animation.gif | 6 frames, indexed | 1 frame, grayscale PNG | animation not preserved |
| gray_16bit.png | 16-bit, 65536 levels | 8-bit grayscale PNG | depth reduced before filtering |
| exif_orient6.jpg | orientation tag 6 | no tag | tag not carried into output |
| logo_alpha.png | RGBA with transparency | grayscale, no alpha | alpha dropped by channel conversion |
Eleven grayscale PNG outputs totalled 28,897,301 bytes against 20,934,926 bytes of input, or 1.38 times the source. The spread is wide: the landscape JPEG grew from 2,403,704 to 5,512,753 bytes, while the 16-bit grayscale PNG fell from 12,042 to 583 bytes and the six-frame GIF from 5,339 to 324.
Two independent full passes over the same files produced byte-identical maps for each operator. The Sobel outputs hashed to SHA-256 181121fad31310b740390609c2505d3adc7b8edfcd0ac0d06dc5a5eb95786bad on both runs, Roberts to a72128810772e317f93b93c4841edbb7f40ccc6c24b596bbcdb4c076db71189d and Laplacian to 9a3b8b505054e17d47eb10883fba3b9b36e5445c6542d46f8c492a0e41d2eef5. Determinism here means identical bytes, not that the three operators agree with each other: on the landscape photo they differed on close to 59% of pixels.
Apply a gradient or Laplacian kernel and keep the magnitude. There is no single result: on photo_landscape.jpg the Roberts and Sobel outputs differed on 7,101,949 of 12,000,000 pixels, 59.183%. Sobel and Laplacian differed on 7,079,312 pixels, 58.994%. The operator choice is the largest decision in the whole batch.
A pair of 3 by 3 kernels, one measuring horizontal change and one vertical change, combined as their magnitude. On this batch the Sobel output marked 60.238% of pixels as non-zero on photo_landscape.jpg, 78.945% on photo_square.png and 0.911% on the flat logo. The same kernel produced very different edge densities depending on the source.
Finding boundaries between regions. The batch shows where it has work to do: photo_square.png produced edges on 78.945% of pixels and small_icon.png on 69.891%, while gray_16bit.png produced them on 0.556% and the six-frame GIF on 0.833%. Sparse or nearly uniform files yield very few edge pixels under the same settings.
These outputs were written as single-channel 8-bit grayscale PNGs. Every readable input, including RGB JPEG, RGBA PNG, 16-bit grayscale PNG, WebP and indexed GIF, became that same kind of file. The edge result carries no colour and no alpha layer; the transparent logo's alpha was not preserved.
In this run 11 of 12 files decoded: JPEG, PNG, WebP and GIF all opened, and a truncated JPEG failed with 'image file is truncated (2 bytes not processed)'. The GIF had six frames but its edge output reopened with one. Format support on input is not format preservation on output.
Not from this path. Each source was converted to a single grayscale channel before the kernel ran, so the RGBA logo lost its alpha and the output was saved as an 8-bit grayscale PNG. A transparency requirement needs a different output stage than the one measured here.
The closest measured control is the threshold. On photo_landscape.jpg, binarising the Sobel response turned 36.317% of pixels white at a threshold of 8, 24.39% at 32 and 12.699% at 128. That is a black and white line map, not a styled stencil; the measured pipeline does no style rendering.
This page reports a local measurement rather than operating a download service, so there is no account or usage limit to describe. The numbers come from code run on this machine over 12 files; the method and the settings are written out above so you can reproduce them. Any pricing claim belongs to a specific service, not to these measurements.
No. On photo_landscape.jpg Sobel and Roberts differed on 59.183% of pixels, Sobel and Laplacian on 58.994%. On photo_square.png the Sobel to Roberts gap was 77.324%. They agreed much more closely on sparse files: 0.556% different on gray_16bit.png and 0.42% on the GIF. Choosing an operator is not a cosmetic setting.