exportToArduinoLibrary

fun <T : Any> exportToArduinoLibrary(model: T, outputPath: String, libraryName: String = model::class.simpleName ?: "SKaiNETModel"): ArduinoLibraryResult(source)

Exports a model to an Arduino library.

Return

ArduinoLibraryResult containing information about the generated library

Parameters

model

The model to export (preferably a ComputeGraph)

outputPath

Base path where the library directory will be created

libraryName

Name of the Arduino library (defaults to model class name)


fun <T : Any> exportToArduinoLibrary(model: T, forwardPass: (ExecutionContext) -> Unit, outputPath: String, libraryName: String = model::class.simpleName ?: "SKaiNETModel"): ArduinoLibraryResult(source)

Fallback overload for models without a direct adapter.

Provide a forwardPass that executes exactly one forward run of the model with example inputs. The facade will:

  1. Start a recording tape

  2. Execute forwardPass

  3. Convert the tape to a ComputeGraph

  4. Delegate to exportGraphToArduinoLibrary

Return

ArduinoLibraryResult containing information about the generated library

Parameters

model

The model to export

forwardPass

Lambda that executes one forward pass of the model

outputPath

Base path where the library directory will be created

libraryName

Name of the Arduino library (defaults to model class name)