Analysis - fpgadataflow

Analysis Passes (fpgadataflow)

finn.analysis.fpgadataflow.dataflow_performance

finn.analysis.fpgadataflow.dataflow_performance.dataflow_performance(model)

Extract key performance indicators from given model with dataflow nodes. Note that the latency (critical path) analysis is very pessimistic, it assumes no overlap between executions and simply sums the expected cycles for each node along the critical path.

Preconditions: - model consists of HLS/RTL nodes - model has cycle estimates annotated (see AnnotateCycles transformation) - nodes have unique names (see GiveUniqueNodeNames)

Returns: - max_cycles : number of cycles for slowest node - max_cycles_node_name : name of slowest node - critical_path_cycles : pessimistic expected latency from input to output

finn.analysis.fpgadataflow.exp_cycles_per_layer

finn.analysis.fpgadataflow.exp_cycles_per_layer.exp_cycles_per_layer(model)

Estimates the number of cycles per sample for dataflow layers in the given model. Ensure that all nodes have unique names (by calling the GiveUniqueNodeNames transformation) prior to calling this analysis pass to ensure all nodes are visible in the results.

Returns {node name : cycle estimation}.

finn.analysis.fpgadataflow.floorplan_params

finn.analysis.fpgadataflow.floorplan_params.floorplan_params(model)

Gathers SLR and partition IDs from nodes.

Returns {node name : {slr, device id, partition id, memory port}}.

finn.analysis.fpgadataflow.hls_synth_res_estimation

finn.analysis.fpgadataflow.hls_synth_res_estimation.hls_synth_res_estimation(model)

Extracts the FPGA resource results from the Vitis HLS synthesis estimates. Note that this analysis pass only works on nodes that have an HLS backend. Ensure that all nodes have unique names (by calling the GiveUniqueNodeNames transformation) prior to calling this analysis pass to ensure all nodes are visible in the results.

Returns {node name : resources_dict}.

finn.analysis.fpgadataflow.op_and_param_counts

finn.analysis.fpgadataflow.op_and_param_counts.aggregate_dict_keys(res_dict)
finn.analysis.fpgadataflow.op_and_param_counts.op_and_param_counts(model)

Return per-node and aggregate op counts per inference.

finn.analysis.fpgadataflow.post_synth_res

finn.analysis.fpgadataflow.post_synth_res.post_synth_res(model, override_synth_report_filename=None)

Extracts the FPGA resource results from the Vivado synthesis. Ensure that all nodes have unique names (by calling the GiveUniqueNodeNames transformation) prior to calling this analysis pass to ensure all nodes are visible in the results.

Returns {node name : resources_dict}.

finn.analysis.fpgadataflow.res_estimation

finn.analysis.fpgadataflow.res_estimation.res_estimation(model)

Estimates the resources needed for the given model. Ensure that all nodes have unique names (by calling the GiveUniqueNodeNames transformation) prior to calling this analysis pass to ensure all nodes are visible in the results.

Returns {node name : resource estimation}.

finn.analysis.fpgadataflow.res_estimation.res_estimation_complete(model)

Estimates the resources needed for the given model and all values for resource-related switches. Ensure that all nodes have unique names (by calling the GiveUniqueNodeNames transformation) prior to calling this analysis pass to ensure all nodes are visible in the results.

Returns {node name : [resource estimation(s)]}.