Skip to main content

RAVEL

RAVEL (Rate-Aware Vectorized Engine for Low-latency) generates a specialized, hls4ml-compatible FPGA inference project. Aria 1.1.0 implements the qualified pair-parallel, two-row wide-stream profile for the CNN-for-Arianna model family; it is not a design-space explorer and it does not impose application-specific performance targets.

Install

Use a clean Python 3.11 environment on Linux for the fully qualified generation, C++ verification, and Vitis HLS workflow:

python -m pip install ravel-hls==1.1.0
ravel-hls doctor --json

For an editable source checkout, replace the install command with:

python -m pip install -c constraints/aria-reference.txt -e .

Do not co-install the retired HGQ distribution with hgq2; both own the hgq Python namespace and RAVEL rejects that conflict before generation.

Python API

import hls4ml
import keras
from hgq.layers import QConv2D, QDense
import ravel_hls as ravel

model = keras.models.load_model(
    "model.keras", custom_objects={"QConv2D": QConv2D, "QDense": QDense}
)
hls = hls4ml.utils.config_from_keras_model(
    model, granularity="name", backend="Vitis"
)
hls["Model"].update({"Strategy": "Latency", "ReuseFactor": 1})

config = {
    "Project": {"Name": "cnn_core", "OutputDir": "cnn_core"},
    "HLS": {
        "Backend": "Vitis",
        "IOType": "io_stream",
        "Part": "xcku5p-ffvb676-2-e",
        "ClockPeriod": 5.0,
        "Config": hls,
    },
    "Verification": {"Mode": "required", "Samples": 32, "Seed": 19},
    "Vitis": {"Run": False},
}

project = ravel.convert(model, config)
print(project.status)

Vitis.Run defaults to False. Set it to True to run vitis_hls -f build_prj.tcl after atomic project publication and automatically record the synthesis report. The default Vitis stages are reset and synthesis; CSim, CoSim, validation, export, and Vivado synthesis remain disabled unless their booleans under Vitis.Stages are enabled explicitly. The same operation can be requested later with project.build().

The concise project lifecycle is Project.open(path), project.refresh(model), project.build(), project.record(report_dir), and project.link(). The CLI command ravel-hls inspect PROJECT --json performs full source-integrity checking; add --fast when payload hashing should be skipped.

Parameter packages

Parameters stores portable generation-relevant inference state without generated HLS sources or executable Python objects:

parameters = ravel.Parameters.extract(model)
parameters.save("trained.ravelparams")

project = ravel.Project.open("cnn_core")
project.refresh(ravel.Parameters.load("trained.ravelparams"))

The deterministic archive contains JSON plus NPY arrays for kernel, bias, and learned K/I/F quantizer state. Static quantizer contracts and slot schemas are compatibility-checked before a complete staged regeneration. A parameter package is not encrypted; treat it as sensitive model IP.

Evidence boundary

Generation, correctness, model fidelity, source integrity, and vendor measurements are independent status axes. Qualification records measured II, latency, timing, resources, and RTL ports for one exact generation fingerprint; it does not compare those measurements with an application threshold. A high II or an estimated clock above the requested clock remains recorded evidence, not a failed RAVEL project.

See the executable CNN-for-Arianna reference, architecture, compatibility, and project format for the full contracts.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ravel_hls-1.1.0.tar.gz (37.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

ravel_hls-1.1.0-py3-none-any.whl (44.8 kB view details)

Uploaded Python 3

File details

Details for the file ravel_hls-1.1.0.tar.gz.

File metadata

  • Download URL: ravel_hls-1.1.0.tar.gz
  • Upload date:
  • Size: 37.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for ravel_hls-1.1.0.tar.gz
Algorithm Hash digest
SHA256 4c66bc4f519d10d88398461395c634889e401a7d4b93a9f2c40015977973a18a
MD5 63b4c39fcf6189f23166f19dab6d5628
BLAKE2b-256 1092eb7e73db6411fc1ab8ffbc4b1bb50c8b3759b5e3f6020864887038c3bca3

See more details on using hashes here.

Provenance

The following attestation bundles were made for ravel_hls-1.1.0.tar.gz:

Publisher: publish.yml on albertc9/RAVEL

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file ravel_hls-1.1.0-py3-none-any.whl.

File metadata

  • Download URL: ravel_hls-1.1.0-py3-none-any.whl
  • Upload date:
  • Size: 44.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for ravel_hls-1.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 da1c65dcdbb826c4fd331548131123c724d87521fa2cc6316824b0f60ee3b701
MD5 b8c8b281d90d70de3759235e75d5163b
BLAKE2b-256 582a5dfe24dccb0be299f88ac97bdbd14dc92f8da71aa3a32f13c7fd6e8d8fe7

See more details on using hashes here.

Provenance

The following attestation bundles were made for ravel_hls-1.1.0-py3-none-any.whl:

Publisher: publish.yml on albertc9/RAVEL

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page