Windows-Machine-Learning icon indicating copy to clipboard operation
Windows-Machine-Learning copied to clipboard

Add sample to showcase binding and inferencing on DX resources using ORT

Open nums11 opened this issue 3 years ago • 0 comments

This PR adds a sample that showcases how to bind and inference on DX resources using ORT.

3 images (cat, dog, hummingbird) are repeatedly displayed in an HWND and their corresponding resource is passed to ORT for evaluation using EfficentNet.

Important Files to look at:

  • DXResourceBinding.cpp

    • Main implementation file
  • ORTHelpers.cpp

    • Handles all ORT preprocessing and evaluation
    • CreateTensorValueFromD3DResource function demonstrates the main functionality of the sample.
  • D3D12Quad.cpp

    • Handles all D3D-related functionality
    • CopyTextureIntoCurrentBuffer is the conversion from a texture 2d into a resource dimension buffer

nums11 avatar Jun 01 '22 17:06 nums11