Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/finn/transformation/fpgadataflow/insert_dwc.py
Original file line number Diff line number Diff line change
Expand Up @@ -95,16 +95,16 @@ def apply(self, model):
in_idx = idx
assert in_idx is not None, "Malformed model"
n1_in_shape = n1.get_folded_input_shape(in_idx)
dwc_out_width = n1.get_instream_width(in_idx)
else:
# use default folded input shape
n1_in_shape = n1.get_folded_input_shape()
dwc_out_width = n1.get_instream_width()

if n0_out_shape[-1] != n1_in_shape[-1]:
graph_modified = True
# determine dwc inwidth
dwc_in_width = n0.get_outstream_width()
# determine dwc outwidth
dwc_out_width = n1.get_instream_width()
node_optype = "StreamingDataWidthConverter"

# determine shape for dwc
Expand Down
1 change: 1 addition & 0 deletions src/finn/transformation/fpgadataflow/set_folding.py
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,7 @@ def apply(self, model):
simd_ops = [
"DownSampler_hls",
"FMPadding_hls",
"FMPadding_rtl",
"FMPadding_Pixel_hls",
"ConvolutionInputGenerator_hls",
"ConvolutionInputGenerator_rtl",
Expand Down
3 changes: 3 additions & 0 deletions src/finn/transformation/streamline/reorder.py
Original file line number Diff line number Diff line change
Expand Up @@ -631,6 +631,9 @@ def apply(self, model):
prod0 = model.find_producer(in0)
if prod0 is None:
continue
# Ignore if producer is fork
if model.is_fork_node(prod0):
continue

if prod0.op_type in ["Mul", "Add", "Div"]:
# check if second input of producer is an initializer
Expand Down