finn.core.rtlsim_exec (module)

finn.core.rtlsim_exec.rtlsim_exec(model, execution_context, pre_hook=None, post_hook=None)

Use PyVerilator to execute given model with stitched IP. The execution context contains the input values. Hook functions can be optionally specified to observe/alter the state of the circuit, receiving the PyVerilator sim object as their first argument: - pre_hook : hook function to be called before sim start (after reset) - post_hook : hook function to be called after sim end