Skip to content

Register hailo library with .hef download counting#2223

Open
evandhoffman wants to merge 3 commits into
huggingface:mainfrom
evandhoffman:register-hailo-library
Open

Register hailo library with .hef download counting#2223
evandhoffman wants to merge 3 commits into
huggingface:mainfrom
evandhoffman:register-hailo-library

Conversation

@evandhoffman

@evandhoffman evandhoffman commented Jun 8, 2026

Copy link
Copy Markdown

Adds a hailo library entry to model-libraries.ts so that HEF (Hailo Executable Format) files hosted on the Hub get counted toward download stats.

Why

Hailo makes the Hailo-8 / Hailo-15 PCIe AI accelerators (commonly seen as M.2 add-ons for the Raspberry Pi 5 AI Kit and other edge platforms). Models targeting these chips are compiled to .hef binaries via Hailo's Dataflow Compiler; the HEF is the actual deployment artifact, similar in role to a TensorRT engine or a CoreML .mlpackage.

Hailo's own model zoo is hosted on GitHub today, but third-party projects are starting to publish HEFs on the Hub alongside their source weights — e.g. k10z/birdvision-efficientnet-s (a fine-tuned EfficientNet-V2-S for bird species classification compiled to Hailo-8). These repos currently show no download counts because the Hub's default query files (config.json, config.yaml, etc.) aren't matched.

What this does

Registers hailo with countDownloads: path_extension:"hef", matching the pattern used for other accelerator-binary libraries (e.g. HoloMotion using path_extension:"onnx").

hailo: {
    prettyLabel: "Hailo",
    repoName: "hailort",
    repoUrl: "https://github.com/hailo-ai/hailort",
    countDownloads: `path_extension:"hef"`,
    snippets: snippets.hailo,
    filter: false,
},

repoUrl points at the public hailort runtime — the end-user dependency that actually loads HEFs at inference time.

Snippet is a minimal Hub-aware load pattern (hf_hub_download + HEF + VDevice) with a pointer to the hailort repo for the full inference API.

Pre-merge checklist

Adds a library entry for Hailo, mapping its proprietary HEF (Hailo
Executable Format) files as the download-count query target. HEFs are
the architecture-specific INT8 binaries that run on Hailo-8 and
Hailo-15 AI accelerators; they're shipped alongside ONNX or PyTorch
source weights but are the actual deployment artifact.

Example model repos hosting HEFs:
- k10z/birdvision-efficientnet-s
- (Hailo's official Hailo Model Zoo publishes them outside HF today,
  but third-party projects are starting to host on the Hub.)

The repoUrl points at the public hailort runtime which is the
end-user dependency.
@evandhoffman

Copy link
Copy Markdown
Author

Updated to match the integration guide more precisely after reviewing it:

  • Added filter: false (per "set filter to false")
  • Added a Python loader snippet in model-libraries-snippets.ts referencing the typical hailo_platform API (VDevice, HEF, create_infer_model)
  • Confirmed at least one model already declares library_name: hailo: k10z/birdvision-efficientnet-s

@Wauplin

Wauplin commented Jun 9, 2026

Copy link
Copy Markdown
Contributor

Hi @evandhoffman thanks for the PR and details. From what I can see in https://huggingface.co/models?other=hailo:

I feel that if hef is a file format we don't have a good way of counting them. If hailo is indeed a library, it's best to split these files to separate repos so we don't double-count or under-count download (i.e. have a .onnx repo and a .hef repo, both with there own counter). Alternative is to add both .hef and .onnx to download counter rule for hailo but that would be relevant only if hailo really support .onnx (which is not the case I think)

@julien-c

Copy link
Copy Markdown
Member

cc @danbev for viz btw

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants