|
Mila
Deep Neural Network Library
|
Compile-time mapping from abstract TensorDataType to cuBLASLt runtime cudaDataType_t enums. More...
#include <cuda_runtime.h>#include <cublasLt.h>#include <cuda_fp16.h>#include <cuda_bf16.h>#include <cuda_fp8.h>#include <type_traits>import Dnn.TensorDataType;Namespaces | |
| namespace | Mila |
| Mila main API namespace. | |
Variables | |
| template<TensorDataType TDataType> | |
| constexpr cudaDataType_t | Mila::Dnn::Compute::Cuda::cuda_data_type_v = CudaDataTypeTraits<TDataType>::cuda_data_type |
| Convenience alias for accessing the cudaDataType_t mapping directly. | |
Compile-time mapping from abstract TensorDataType to cuBLASLt runtime cudaDataType_t enums.
Provides CudaDataTypeTraits<TDataType>::cuda_data_type for use in cuBLASLt plan builders. Complements TensorDataTypeMap (C++ device type) and lives as a partition of Compute.CudaTensorDataType so it shares the module's established import chain.
Only types that have a valid cudaDataType_t representation are specialised. Instantiating the primary template for an unsupported type produces a clear static assertion.
|
constexprexport |
Convenience alias for accessing the cudaDataType_t mapping directly.
Usage: constexpr cudaDataType_t dt = cuda_data_type_v<TensorDataType::BF16>; // dt == CUDA_R_BF16