OpenViSTAI · Agents · Blockchain · Crypto
Menu
AI Models

Pytorch Hed

pytorch-hed is a Python and PyTorch reimplementation of Holistically-Nested Edge Detection that processes an input image and writes an edge-detection result to an output image.

Independent OpenViST project profile, based on linked sources.

Pytorch Hed — OpenViST project profile in AI Models.
OpenViST project illustration. See the linked sources for product details.
Understand the project

Practical overview

When it fits

Use it when a local command-line step for HED-style edge detection is useful and you can work with a Python and PyTorch repository.

Who it is for

  • Developers adding edge-map generation to image-processing workflows.
  • Computer-vision practitioners seeking an edge-detection preprocessing step.

Documented uses

  • Generate an edge map from an image using the BSDS500 model.
  • Use detected image boundaries as an intermediate input to a larger vision workflow.
Before you choose

Requirements & limits

The repository is public and lists GPL-3.0 as its license.

  • The documented command selects the BSDS500 model and names input and output image paths.
  • The implementation uses official weights but reports a lower BSDS500 ODS than the official Caffe version.
  • The README asks users to cite the HED paper, observe the authors' licensing terms, and acknowledge this implementation.

Check current requirements in the official documentation. Source-based guidance does not mean OpenViST has run or independently tested this project.

Source-based practical guide

Run the documented BSDS500 image command

Process one image with the BSDS500 model and specify an output image path.

Before you start

  • A local copy of the repository and its documented Python entry point, run.py.
  • An input image at the path provided to --in.

Steps

  1. Choose the input image path and the desired output image path.

  2. Run: python run.py --model bsds500 --in ./images/sample.png --out ./out.png

Expected outcome

The command requests edge detection on the input image and writes the result to the specified output path.

Guide limitations

  • The implementation is not entirely true to the original Caffe version; its stated BSDS500 ODS is 0.774 versus 0.780 for the official version.
Evidence and transparency

Sources & review

Source record details
Source availability
Active
Sources checked
11 November 2026
Original website title
sniklaus/pytorch-hed · Official homepage title · retained in its source language