Skip to content
Snippets Groups Projects
Commit 92dbabd4 authored by Yaman Umuroglu's avatar Yaman Umuroglu
Browse files

[Analysis] use node.name as returned dict key, comment on unique names

parent d2a36378
No related branches found
No related tags found
No related merge requests found
......@@ -32,6 +32,10 @@ from finn.util.fpgadataflow import is_fpgadataflow_node
def 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}."""
cycle_dict = {}
......@@ -39,6 +43,6 @@ def exp_cycles_per_layer(model):
if is_fpgadataflow_node(node) is True:
op_type = node.op_type
inst = registry.custom_op[op_type](node)
cycle_dict[str(node)] = inst.get_exp_cycles()
cycle_dict[node.name] = inst.get_exp_cycles()
return cycle_dict
......@@ -35,6 +35,9 @@ from finn.util.fpgadataflow import is_fpgadataflow_node
def hls_synth_res_estimation(model):
"""Extracts the FPGA resource results from the Vivado HLS synthesis estimates.
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}."""
......
......@@ -36,6 +36,9 @@ from finn.custom_op.registry import getCustomOp
def 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}."""
......
......@@ -32,6 +32,9 @@ from finn.util.fpgadataflow import is_fpgadataflow_node
def 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}."""
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment