include_optional_kernels.h#

namespace ONNX_LIGHT_NAMESPACE
namespace onnx_backend_test
namespace kernel
class Optional#
#include <include_optional_kernels.h>

Wraps a single tensor input into an optional-of-tensor value. The output’s element type, shape and bytes are an exact copy of input.

Public Functions

inline explicit Optional(const KernelContext &ctx)#
Tensor operator()(const Tensor &input) const#
void operator()(const Tensor &input, Tensor &output) const#

Public Static Functions

static inline constexpr bool CanRunInPlace() noexcept#

Output is a byte-for-byte copy of input, so storage may safely be shared with the input buffer.

Private Members

KernelContext ctx_#