mirror of
https://github.com/saymrwulf/onnxruntime.git
synced 2026-05-15 20:50:42 +00:00
On Windows, clang-format has a bug when AlignTrailingComments.Kind is set to `Leave` (https://clang.llvm.org/docs/ClangFormatStyleOptions.html#aligntrailingcomments), where it will keep adding indentation to comments after each formatting runs. This PR changes to always align comments so we do not hit the bug. As a consequence of the options change we need to reformat some of the files. Note that this option is aligned with the rest of the repository.
46 lines
1.1 KiB
C++
46 lines
1.1 KiB
C++
//-----------------------------------------------------------------------------
|
|
//
|
|
// Copyright (c) Microsoft Corporation. All rights reserved.
|
|
//
|
|
//-----------------------------------------------------------------------------
|
|
|
|
#pragma once
|
|
|
|
#include <winrt/Windows.Media.h>
|
|
#include <winrt/Windows.Graphics.Imaging.h>
|
|
|
|
enum OutputBindingStrategy {
|
|
Bound,
|
|
Unbound,
|
|
Empty
|
|
};
|
|
enum EvaluationStrategy {
|
|
Async,
|
|
Sync
|
|
};
|
|
enum ModelInputOutputType {
|
|
Image,
|
|
Tensor
|
|
};
|
|
enum InputImageSource {
|
|
FromVideoFrame,
|
|
FromImageFeatureValue,
|
|
FromCPUResource,
|
|
FromGPUResource
|
|
};
|
|
enum VideoFrameSource {
|
|
FromSoftwareBitmap,
|
|
FromDirect3DSurface,
|
|
FromUnsupportedD3DSurface
|
|
};
|
|
|
|
namespace ImageTestHelper {
|
|
wgi::BitmapPixelFormat GetPixelFormat(const std::wstring& inputPixelFormat);
|
|
|
|
winml::TensorFloat LoadInputImageFromCPU(wgi::SoftwareBitmap softwareBitmap, const std::wstring& modelPixelFormat);
|
|
|
|
winml::TensorFloat LoadInputImageFromGPU(wgi::SoftwareBitmap softwareBitmap, const std::wstring& modelPixelFormat);
|
|
|
|
bool VerifyHelper(wm::VideoFrame actual, wm::VideoFrame expected);
|
|
|
|
} // namespace ImageTestHelper
|