mirror of
https://github.com/pytorch/pytorch.git
synced 2025-10-20 12:54:11 +08:00
Optimization Blocklist will be used in a future diff (D40315730) to make the rewrite to transfer input/output backends optional Differential Revision: [D40315729](https://our.internmc.facebook.com/intern/diff/D40315729/) Pull Request resolved: https://github.com/pytorch/pytorch/pull/87431 Approved by: https://github.com/mcr229, https://github.com/digantdesai
22 lines
820 B
C++
22 lines
820 B
C++
#pragma once
|
|
|
|
#include <torch/csrc/jit/api/module.h>
|
|
#include <torch/csrc/jit/ir/ir.h>
|
|
#include <torch/csrc/jit/passes/mobile_optimizer_type.h>
|
|
|
|
namespace torch {
|
|
namespace jit {
|
|
|
|
TORCH_API void transformConv1dToConv2d(std::shared_ptr<Graph>& graph);
|
|
TORCH_API void transformConv1dToConv2d(script::Module& module);
|
|
TORCH_API void insertPrePackedOps(std::shared_ptr<Graph>& graph);
|
|
TORCH_API void insertPrePackedOps(script::Module& module);
|
|
TORCH_API void fusePrePackedLinearConvWithClamp(script::Module& module);
|
|
TORCH_API void FoldPrePackingOps(script::Module& module);
|
|
TORCH_API script::Module optimizeForMobile(
|
|
const script::Module& module,
|
|
const std::set<MobileOptimizerType>& optimization_blocklist = {},
|
|
const std::vector<std::string>& preserved_methods = {});
|
|
} // namespace jit
|
|
} // namespace torch
|