/
usr
/
local
/
lib64
/
python3.6
/
site-packages
/
torch
/
include
/
torch
/
csrc
/
jit
/
passes
/
/usr/local/lib64/python3.6/site-packages/torch/include/torch/csrc/jit/passes
mkdir
upload
Name
Size
Mode
Actions
quantization/
-
0755
rm
utils/
-
0755
rm
annotate_warns.h
192
0644
edit
dl
rm
bailout_graph.h
1129
0644
edit
dl
rm
batch_mm.h
163
0644
edit
dl
rm
canonicalize.h
492
0644
edit
dl
rm
canonicalize_graph_fuser_ops.h
177
0644
edit
dl
rm
clear_profiling.h
334
0644
edit
dl
rm
clear_undefinedness.h
889
0644
edit
dl
rm
common_subexpression_elimination.h
194
0644
edit
dl
rm
concat_opt.h
481
0644
edit
dl
rm
constant_pooling.h
177
0644
edit
dl
rm
constant_propagation.h
1287
0644
edit
dl
rm
create_autodiff_subgraphs.h
552
0644
edit
dl
rm
create_functional_graphs.h
323
0644
edit
dl
rm
cuda_graph_fuser.h
860
0644
edit
dl
rm
dead_code_elimination.h
1584
0644
edit
dl
rm
decompose_ops.h
168
0644
edit
dl
rm
erase_number_types.h
813
0644
edit
dl
rm
fixup_trace_scope_blocks.h
1673
0644
edit
dl
rm
fold_conv_bn.h
995
0644
edit
dl
rm
freeze_module.h
1236
0644
edit
dl
rm
frozen_conv_add_relu_fusion.h
233
0644
edit
dl
rm
frozen_conv_folding.h
872
0644
edit
dl
rm
frozen_graph_optimizations.h
435
0644
edit
dl
rm
frozen_ops_to_mkldnn.h
414
0644
edit
dl
rm
fuse_linear.h
526
0644
edit
dl
rm
fuse_relu.h
273
0644
edit
dl
rm
graph_fuser.h
1251
0644
edit
dl
rm
graph_rewrite_helper.h
1785
0644
edit
dl
rm
guard_elimination.h
390
0644
edit
dl
rm
hoist_conv_packed_params.h
211
0644
edit
dl
rm
inliner.h
199
0644
edit
dl
rm
inline_autodiff_subgraphs.h
275
0644
edit
dl
rm
inline_forked_closures.h
241
0644
edit
dl
rm
inline_fork_wait.h
547
0644
edit
dl
rm
inplace_check.h
168
0644
edit
dl
rm
insert_guards.h
453
0644
edit
dl
rm
integer_value_refinement.h
234
0644
edit
dl
rm
lift_closures.h
236
0644
edit
dl
rm
liveness.h
663
0644
edit
dl
rm
loop_unrolling.h
1006
0644
edit
dl
rm
lower_grad_of.h
348
0644
edit
dl
rm
lower_graph.h
750
0644
edit
dl
rm
lower_tuples.h
666
0644
edit
dl
rm
metal_rewrite.h
606
0644
edit
dl
rm
normalize_ops.h
536
0644
edit
dl
rm
onnx.h
967
0644
edit
dl
rm
pass_manager.h
4635
0644
edit
dl
rm
peephole.h
507
0644
edit
dl
rm
peephole_alias_sensitive.h
355
0644
edit
dl
rm
peephole_dict_idioms.h
1000
0644
edit
dl
rm
peephole_list_idioms.h
2003
0644
edit
dl
rm
peephole_non_tensor.h
342
0644
edit
dl
rm
prepack_folding.h
358
0644
edit
dl
rm
remove_dropout.h
280
0644
edit
dl
rm
remove_exceptions.h
954
0644
edit
dl
rm
remove_expands.h
175
0644
edit
dl
rm
remove_inplace_ops.h
296
0644
edit
dl
rm
remove_mutation.h
2674
0644
edit
dl
rm
remove_redundant_profiles.h
196
0644
edit
dl
rm
requires_grad_analysis.h
260
0644
edit
dl
rm
restore_mutation.h
1887
0644
edit
dl
rm
shape_analysis.h
463
0644
edit
dl
rm
specialize_autogradzero.h
656
0644
edit
dl
rm
subgraph_rewrite.h
4112
0644
edit
dl
rm
symbolic_shape_analysis.h
641
0644
edit
dl
rm
tensorexpr_fuser.h
2077
0644
edit
dl
rm
update_differentiable_graph_requires_grad.h
740
0644
edit
dl
rm
value_refinement_utils.h
2669
0644
edit
dl
rm
variadic_ops.h
993
0644
edit
dl
rm
vulkan_rewrite.h
576
0644
edit
dl
rm
xnnpack_rewrite.h
917
0644
edit
dl
rm
Edit:
/usr/local/lib64/python3.6/site-packages/torch/include/torch/csrc/jit/passes/tensorexpr_fuser.h
(2077B)
#pragma once #include <torch/csrc/WindowsTorchApiMacro.h> #include <torch/csrc/jit/passes/pass_manager.h> #include <memory> namespace torch { namespace jit { struct Graph; // Run TensorExpressions-based fuser. // // If shape checks are disabled it is the responsibilty of // the caller to ensure that the resultant subgraph is correctly // annotated with shapes by the time "getOperation" is called // on the node. TORCH_API void FuseTensorExprs( std::shared_ptr<Graph>& graph, size_t min_group_size = 2, bool disable_shape_checks = false); TORCH_API void setTensorExprFuserEnabled(bool val); TORCH_API bool tensorExprFuserEnabled(); TORCH_API bool setTexprReductionsEnabled(bool value); TORCH_API bool texprReductionsEnabled(); TORCH_API void RemoveProfileNodesAndSpecializeTypes( std::shared_ptr<Graph>& graph); TORCH_API void RemoveTensorTypeSpecializations(std::shared_ptr<Graph>& graph); TORCH_API void removeTensorTypeSpecializations(Block* block); using tensor_type_converter_t = c10::function_ref<TensorTypePtr(const TensorTypePtr& t)>; // inserts a TypeCheck pattern // // around the guarded node that has a Subgraph attribute, this inserts a pattern // // if TypeCheck(...): // guarded_node // else: // FallbackGraph(...) // // The TypeCheck includes the types of all Tensor inputs to the guarded_node, // as processed by the type_converter, a lambda // TensorTypePtr(const TensorTypePtr& t). This allows to erase irrelevant // aspects of the type. // // The Fallback graph will have the same subgraph as the guarded node (with the // expectation that the guarded_node's subgraph will then be optimized. TORCH_API void insertTypeGuard( Node* guarded_node, tensor_type_converter_t type_converter, c10::Symbol kind); TORCH_API bool usedOnlyInSize(Value* v); TORCH_API Value* broadcastSizes(at::ArrayRef<Value*> sizes, AliasDb* db); namespace tensorexpr { TORCH_API const OperatorSet& supported_eltwise_set(); TORCH_API bool isSupported(Node* node); } // namespace tensorexpr } // namespace jit } // namespace torch
Save
cmd:
run