1 | #pragma once |
---|---|
2 | |
3 | #include <torch/csrc/jit/api/module.h> |
4 | #include <torch/csrc/jit/ir/ir.h> |
5 | #include <torch/csrc/jit/passes/mobile_optimizer_type.h> |
6 | |
7 | namespace torch { |
8 | namespace jit { |
9 | |
10 | TORCH_API void transformConv1dToConv2d(std::shared_ptr<Graph>& graph); |
11 | TORCH_API void transformConv1dToConv2d(script::Module& module); |
12 | TORCH_API void insertPrePackedOps(std::shared_ptr<Graph>& graph); |
13 | TORCH_API void insertPrePackedOps(script::Module& module); |
14 | TORCH_API void fusePrePackedLinearConvWithClamp(script::Module& module); |
15 | TORCH_API void FoldPrePackingOps(script::Module& module); |
16 | TORCH_API script::Module optimizeForMobile( |
17 | const script::Module& module, |
18 | const std::set<MobileOptimizerType>& optimization_blocklist = {}, |
19 | const std::vector<std::string>& preserved_methods = {}); |
20 | } // namespace jit |
21 | } // namespace torch |
22 |