Skip to main content

//clika-runtime/io.clika.runtime/ModelGraph

ModelGraph

[jvm]
class ModelGraph : AutoCloseable

A compiled, runnable graph (the consume half: load + run).

run BORROWS its inputs (they stay valid and stay the caller's) and returns caller-owned output tensors, one per graph output.

Functions

NameSummary
close[jvm]
open override fun close()
inputNames[jvm]
fun inputNames(): List<String>
The graph's input names, in binding order.
outputNames[jvm]
fun outputNames(): List<String>
The graph's output names, in binding order.
run[jvm]
fun run(inputs: List<Tensor>): List<Tensor>
Run the graph over inputs (positional, matching inputNames). Returns one caller-owned Tensor per output; release each when done. Entries are retained out of the result list, whose backing handle is freed here.