How to run a VGF file with ML SDK Scenario Runner and ML Emulation Layer for Vulkan®

1. Use the VGF Dump Tool to generate a Scenario Template. To run a scenario on the ML SDK Scenario Runner, you must have a scenario specification in the form of a JSON file:

$vgf_dump --input ${NAME}.vgf --output scenario.json --scenario-template

Note

For more information about VGF Library and the VGF Dump Tool, see: ML SDK VGF Library

  1. The generated scenario.json file contains placeholder names for input and output bindings for the scenario. You must replace these names with the actual input and output filenames that will be used when running the scenario. In the example scenario.json file generated in the preceding step:

    1. Replace the name TEMPLATE_PATH_TENSOR_INPUT_0 with the actual input file input-0.npy.

    2. Replace the name TEMPLATE_PATH_TENSOR_OUTPUT_0 with the actual output filename output-0.npy.

Note

For more information about the test description format, see: JSON Test Description Specification.

  1. Run the ML SDK Scenario Runner on the ML Emulation Layer for Vulkan®:

scenario-runner --scenario scenario.json

The output from the scenario is produced as a file named output-0.npy. The file is specified in scenario.json.

Note

For more information about building and running the ML SDK Scenario Runner, see: ML SDK Scenario Runner.

For more information about building and setting up the Emulation Layer, see: ML Emulation Layer for Vulkan®