Skip to content
| Marketplace
Sign in
Visual Studio Code>Programming Languages>Siliconize StudioNew to Visual Studio Code? Get it now.
Siliconize Studio

Siliconize Studio

Hussain Khan

|
1 install
| (0) | Free
Put trained ML models and Python functions on an FPGA: convert, check the hardware against the Python, see it as a schematic, and load it onto a board.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

Siliconize Studio

Put a trained model, or a plain Python function, on an FPGA without leaving VS Code. Siliconize Studio converts it to hardware, checks that the hardware still computes what the Python computes, shows you the circuit, and loads it onto your board when you press the button.

A Python function on the left; on the right the hardware it became, the verification results and the Load onto FPGA button

Where to find it. Click the Siliconize icon in the activity bar: the Hardware view lists your Python functions and model files, each with its actions. In any Python file the Prepare for FPGA button (a chip) sits in the editor's title bar; View hardware is in the menu next to it. The Siliconize entry in the status bar opens the sidebar.

What you get:

  • Models to hardware. Right-click an .onnx, .tflite, .keras, .h5 or .pt2 file and get an integer (int8) hardware version of it, with a report of how much accuracy the conversion cost.
  • Python to hardware. Compile | Simulate | View hardware | Prepare for FPGA above every function, errors at the line that caused them, and the generated Verilog beside your source.
  • Checked, not assumed. Every design is run against the Python it came from: as a compiler model, as RTL in a simulator, and as the synthesized netlist. The Load button stays disabled until all of it has passed.
  • A hardware view you can read. A schematic grouped by the Python lines it came from, the dataflow graph with its clock schedule, and the device grid showing where the design sits in the chip.
  • Nothing to set up. The extension keeps its own Python environment and installs the open-source siliconize compiler and tools into it.

All screenshots on this page are from the extension running in VS Code.

Put a trained model on an FPGA

1. Right-click the model file and choose Import model. Supported files: ONNX (.onnx), TensorFlow Lite (.tflite), Keras (.keras, .h5) and exported PyTorch programs (.pt2). The command is also in the Command Palette as Siliconize: Import model.

The Explorer context menu of iris.onnx with the Import model entry

You are asked for three things:

  • Calibration data: a .npy or .csv file of example inputs, one per row. They decide the integer scales of the hardware model, so use inputs like the ones the model will see.
  • Labels (optional): the correct answers for those rows. With labels the report shows real accuracy figures; without them it shows how often the integer model agrees with the original.
  • A name for the generated Python module (it is written next to the model file).

2. Read the report. The model is now an ordinary Python module of integer arithmetic that you can read, run and test. The report shows the accuracy of the original floating-point model, the accuracy of the integer model that becomes hardware, how often the two agree, and the layers that were converted.

The generated Python module beside the model import report: float accuracy, integer accuracy, agreement and the layer list

3. Press Prepare for FPGA. This builds the design for the board selected in the status bar, runs the verification, and opens the hardware view. Nothing is sent to a board. The results arrive in the side panel as they finish.

Three columns: the generated module, the import report, and the hardware view while the build and the verification run

4. Look at the hardware. The schematic is the model as it will exist in the chip, grouped by the Python lines it was made from: here the two dense layers, the final argmax, and the control logic. Each block says how many lookup tables (LUT), carry cells and flip-flops (FF) it costs. On the right: the board, the verification steps with a tick for each one that passed, and the Load onto FPGA button, which is enabled only now that the build and every verification step have passed.

The hardware view: the schematic of the model grouped by Python line, three verification ticks, and the Load onto FPGA button enabled

Double-click a block to open it. Inside the first layer are its four multipliers, the loop that sums each row, and the clamp, each still named after the Python expression it implements. Clicking a block jumps to its line in the source.

The first dense layer opened: four multiply blocks, the row loop and the clamp, with a breadcrumb back to the top

5. Press Load onto FPGA. You type the serial port of your board (ports are never scanned for), and the first time for each board and port you confirm the load.

The confirmation dialog: Load iris_fpga onto the board on this port? This is the first time for this board and port.

The design is loaded, and the same test vectors that were used in simulation are then sent through the board and compared with the Python model. The result is added to the verification list as a fourth tick. From here, Insert call snippet writes the Python code that calls your FPGA, and Try it lets you call it by hand.

The hardware view after loading: Done, 1512 of 1512 results matched, and a Board tick in the verification list

This last screenshot was taken with the built-in simulated board (type sim as the port), which runs the whole flow without hardware. It is a good way to try the extension before you connect a board.

Not every model fits every chip. The cell counts in the schematic and the utilization figures in the side panel tell you how large a design is before you load it.

Two kinds of file are refused on purpose. Pickle files (.pkl, .joblib, and scikit-learn, XGBoost or LightGBM models saved that way) are refused because opening a pickle can run arbitrary code. A .safetensors file is refused because it holds only weights, not the model that uses them.

From a Python function

The same flow works for hardware you write yourself. A function with typed arguments is a design:

from siliconize import UInt


def gcd(a: UInt[8], b: UInt[8]) -> UInt[8]:
    if a == 0:
        a = b
    if b == 0:
        b = a
    while a != b:
        if a > b:
            a -= b
        else:
            b -= a
    return a

CodeLens. Above every top-level function: Compile | Simulate | View hardware | Prepare for FPGA. After a compile, a summary joins them: size, latency in clock cycles, and whether the design meets the clock of the selected board. Hover over a line to see what the compiler proved about it: the hardware operation, its type and bit width, the range of values it can take, and its delay.

CodeLens above the gcd function with the summary 79 LUT, 0 DSP, 2 to 65538 cycles, 12 MHz met; a hover shows that the subtraction is a 9-bit signed value between -255 and 255

Compiling is always your decision. Nothing compiles while you type or when you save. An edit only marks the last result as stale.

Diagnostics. Whatever cannot become hardware is reported at the line that caused it, like any other problem in VS Code.

A compile error underlined in the source: operator Div is not supported

The Verilog beside the source. Siliconize: Open generated Verilog beside the source opens the generated Verilog-2001, read-only. Put the cursor on a Python line and the Verilog made from it is highlighted, and the other way round.

The Python source and the generated Verilog side by side; the cursor is on a Python line and the matching Verilog line is highlighted

Try it. A small panel to call the function with your own values, or with a batch of random ones, and compare the result with Python. It runs in simulation; once a design has been loaded from the hardware view, it can also call the FPGA.

The Try it panel: inputs a and b, a Call button, a Random batch button, and the result 1000 of 1000 calls matched the Python model

Prepare for FPGA then works exactly as for a model: build, verify, hardware view, Load onto FPGA.

The hardware view

One panel, three views of the same design. In all of them, clicking a part takes you to the Python line it came from, and moving the cursor in the source highlights the matching hardware.

Schematic

What will exist in the chip, after synthesis. Blocks are grouped by the Python line they were made from, so a design of thousands of cells still reads like your program. Double-click a block to go inside it (the breadcrumb leads back up), or press its + to expand it in place. Wires that belong together are drawn as one bus with its width. Select a block and use Focus to see only that block and what it connects to. The search box finds cells and nets by name, and the Group menu switches between grouping by Python source, by module, and a flat view.

The schematic of gcd: the while loop, the two subtractions and the control logic as blocks named after their Python lines, with bus widths on the wires

Dataflow / FSM

What the compiler understood, before synthesis: every operation with its type and Python line, and the schedule that says which operations run in which clock cycle. Loops are drawn as loops, with their iterations laid out along the cycle axis, so you can see where the latency of a design comes from.

The dataflow view of gcd: a schedule with one loop iteration per clock cycle, and below it the graph of comparisons, subtractions and multiplexers inside the while loop

Device

Where the design sits in the chip after place and route: logic cells, carry chains, block RAM, DSP and I/O on the real grid of the device, with the share of each resource that is used. This view needs a place-and-route tool for the device (see Requirements); without one the panel still shows the resource estimate.

The device view: the grid of the chip with the placed cells of gcd in one corner, and LUT, DSP and block RAM utilization bars

Themes

The view follows your VS Code color theme: light, dark and high contrast.

The schematic in a dark theme and the device view in a high-contrast theme

Requirements

  • VS Code 1.90 or newer.
  • Python 3.10 or newer on your computer. It is used only to create the extension's private environment.

That is all you install by hand. The first time you use a command, the extension offers to create a private virtual environment in its own storage and to install the siliconize package into it. It shows the exact commands first and runs nothing until you agree. Your own Python environments are not touched, and nothing needs administrator rights.

Optional tools. Siliconize: Toolchain check (doctor) lists every feature, whether it is ready, and what it needs. The open-source tools (a simulator, synthesis, place and route, board loaders) are installed into the private environment with one click from that panel.

The toolchain panel: a table of features, each ready or missing, with an install button for what can be installed

Vendor tools. The tools of the FPGA vendors are used when they are already installed and on your PATH. They are needed only for the devices that have no open-source flow, they cannot be installed from the extension, and the extension works without them.

Commands

All commands are in the Command Palette under Siliconize.

Command What it does
Compile Compiles the function at the cursor and shows its summary and diagnostics
Simulate Runs the generated design against the Python function in a simulator
Verify (equivalence chain) Runs every verification step: compiler model, RTL simulation, netlist simulation
View hardware Opens the hardware view (does not enable the Load button)
Switch hardware view (schematic, dataflow, device) Changes the tab of the hardware view
Open generated Verilog beside the source Shows the read-only Verilog with linked highlighting
Prepare for FPGA (build, verify, open the hardware view) The only way to enable the Load onto FPGA button
Import model Converts a model file to a Python module and shows the report
Insert call snippet Writes Python code that calls the design (your function is never edited)
Open the Try it panel Calls the design with your values, in simulation or on the FPGA
Select board Chooses the target board (also in the status bar)
Forget confirmed boards and ports Makes every board and port ask for confirmation again
Toolchain check (doctor) Shows what is installed and what each feature needs
Set up or repair the private Python environment Creates the environment again
Install or upgrade siliconize in the private environment Runs the upgrade (the command is shown first)
Restart the siliconize service Restarts the background compiler process
Show log Opens the Siliconize output channel
Clear diagnostics Removes the Siliconize problems from the Problems panel

Import model is also in the Explorer context menu of model files. There is no command, menu entry or CodeLens that loads a board.

Settings

Setting Default Meaning
siliconizeStudio.board empty The selected board (set it from the status bar)
siliconizeStudio.clockMHz null Target clock in MHz; null means the board's clock, or the compiler default
siliconizeStudio.strict false Treat compiler warnings as errors
siliconizeStudio.defaultHardwareView dataflow The view shown first by View hardware: schematic, dataflow or device
siliconizeStudio.codeLens.enabled true Show the CodeLens above functions
siliconizeStudio.extras ["sim", "synth"] Tool sets installed into the private environment: sim, synth, place, boards, all
siliconizeStudio.packageSource siliconize What pip installs: a package name, a requirement such as siliconize>=0.1, or the path of a local checkout or wheel
siliconizeStudio.pythonPath empty The Python 3.10+ used to create the private environment; empty means search the PATH
siliconizeStudio.serviceCommand [] Advanced: your own command that starts the service, instead of the private environment
siliconizeStudio.logProtocol false Log every message exchanged with the service in the output channel

Safety

An FPGA board is real hardware, so the extension is deliberately careful with it.

  • One way to the board. Nothing is loaded from a CodeLens, a command, a menu, a save or an import. The only path is the Load onto FPGA button inside the hardware view.
  • Verified first. The button is enabled only after Prepare for FPGA has built the design and every verification step has passed. A step that could not run counts as not passed. Editing the source disables the button again.
  • You name the port. Serial ports are never scanned or probed. You type the port, and it is remembered for that board.
  • Confirmation. The first load for each board and port asks you to confirm, and remembers the answer. Forget confirmed boards and ports resets this.
  • RAM, not flash. The button loads the design into the FPGA's configuration memory: it is gone after a power cycle, and what is stored in the board's flash is left as it was. Writing a board's flash is never done implicitly, and a flash write asks for confirmation every time: that answer is never remembered.
  • Checked on the board. After a load, the test vectors are run through the board and compared with the Python model. A mismatch is reported as an error, not as a success with a warning.

Privacy

Siliconize Studio has no telemetry and uses no cloud service. Your code and your models are compiled on your own computer by a local process that the extension starts. The network is used only when you agree to an install, which downloads packages with pip.

Links

  • siliconize: the compiler and its documentation (language reference, supported boards, machine-learning import)
  • Source code of this extension and notes for contributors
  • Report a problem
  • Changelog

License

Apache License 2.0. See LICENSE. Copyright 2026 Hussain Khan and contributors.

Disclaimer

Siliconize Studio and siliconize are provided "as is", without warranty of any kind. Passing verification is strong evidence, not a guarantee: tests cover a finite set of inputs, and tools have bugs. Loading a design onto hardware is at your own risk. Wrong pin assignments, I/O standards or voltages can damage a board, the circuits attached to it, or your computer, so check the constraints against your board's documentation before you load anything. Do not use generated designs where a failure could cause injury or damage without your own independent review and testing. The full text is in the siliconize disclaimer.

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
  • Your Privacy Choices
  • Consumer Health Privacy
© 2026 Microsoft