chop.passes.graph#

Summary of MaseGraph Analysis Passes#

MaseGraph graph analysis passes#

Pass Name

Usage Example

Summary

init_metadata_analysis_pass()

test_add_common_metadata

Initialize each node with the MaseMetadata, this needs to run first before adding any metadata

add_common_metadata_analysis_pass()

test_add_common_metadata

Add shared metadata required by downstream analysis and transform passes

add_software_metadata_analysis_pass()

test_add_software_metadata

Add software-specific metadata, such as sparsity. Details see the pass page

report_graph_analysis_pass()

test_report_graph

Generates a report for the graph analysis and prints out an over the model in a table.

report_node_meta_param_analysis_pass()

test_report_node_meta_param

Generate a report on the meta parameters of the nodes in the graph.

report_node_shape_analysis_pass()

test_report_node_shape

Generate a report on the shape of the nodes in the graph.

report_node_type_analysis_pass()

test_report_node_type

Generate a report on the type of the nodes in the graph.

profile_statistics_analysis_pass()

test_profile_statistics

Perform profile statistics analysis on the given graph

calculate_avg_bits_mg_analysis_pass()

calculate_avg_bits_mg_analysis_pass

Calculate, on average, how many bits are spent on weights and activations

add_natural_sparsity_metadata_analysis_pass()

test_calculate_natural_sparsity

Add natural sparsity metadata analysis pass to the given MaseGraph.

add_pruning_metadata_analysis_pass()

test_prune

This pass computes weight and activation sparsity based on pruning masks

hook_inspection_analysis_pass()

test_hook_inspection_analysis_pass

Provide hook information of the modules

verify_metadata_analysis_pass()

fill me

fill me

verify_common_metadata_analysis_pass()

fill me

fill me

verify_software_metadata_analysis_pass()

fill me

fill me

Summary of MaseGraph Transform Passes#

MaseGraph graph transform passes#

Pass Name

Usage Example

Summary

prune_transform_pass()

test_prune

Prune the given graph

prune_detach_hook_transform_pass()

test_prune_detach_hook

Remove all pruning hooks

quantize_transform_pass()

test_quantize

Apply quantization, check the further documentation below

summarize_quantization_analysis_pass()

test_quantize

Summarizes the quantization with respect to the original graph

conv_bn_fusion_transform_pass()

test_conv_bn_fusion

Perform Conv-BN fusion on the given graph

logicnets_fusion_transform_pass()

test_logicnets_fusion (DEV, Disabled)

Perform LogicNets fusion on the given graph (DEV, Disabled)

Summary of MaseGraph Interface Passes#

A summary of all MaseGraph interface passes#

Pass Name

Usage Example

Summary

load_mase_graph_interface_pass()

fill me

fill me

save_mase_graph_interface_pass()

fill me

fill me

save_node_meta_param_interface_pass()

fill me

fill me

load_node_meta_param_interface_pass()

fill me

fill me