Tensor Comprehensions
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
halide_utils.h
Go to the documentation of this file.
1 
16 #pragma once
17 
18 #include <chrono>
19 #include <string>
20 #include <unordered_set>
21 #include <vector>
22 
23 #include "tc/core/tc2halide.h"
25 #include "tc/core/utils/dlpack.h"
26 
27 namespace tc {
28 
33 std::map<std::string, int> computeParamValueMap(
34  const tc2halide::HalideComponents& components,
35  const std::vector<const DLTensor*>& inputsDLT);
36 
42 std::vector<dlutils::DLTensorUPtr> inferOutputTensorInfo(
43  const tc2halide::HalideComponents& halide,
44  const std::vector<const DLTensor*>& inputsDLT);
45 
47 std::string halideCodegenC(const Halide::Internal::Stmt& s);
48 
49 } // namespace tc
std::map< std::string, int > computeParamValueMap(const tc2halide::HalideComponents &components, const std::vector< const DLTensor * > &inputsDLT)
Definition: tc2halide.h:29
std::vector< dlutils::DLTensorUPtr > inferOutputTensorInfo(const tc2halide::HalideComponents &halide, const std::vector< const DLTensor * > &inputsDLT)
std::string halideCodegenC(const Halide::Internal::Stmt &s)
Just generates a C function body from a Halide stmt. Exposed for testing.