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

[SWG] reflect hlslib restrictions in asserts

parent befc2c5c
No related branches found
No related tags found
No related merge requests found
......@@ -95,7 +95,8 @@ class ConvolutionInputGenerator(HLSCustomOp):
simd = self.get_nodeattr("SIMD")
pad = 0
ofm_dim = compute_conv_output_dim(ifm_dim, k, stride, pad)
assert k * k * ifm_ch % simd == 0, "SIMD must divide sliding window size"
assert ifm_ch % simd == 0, "SIMD must divide IFMChannels"
assert k % stride == 0, "stride must divide kernel size k"
wf = int((k * k * ifm_ch) // simd)
folded_oshape = (1, ofm_dim, ofm_dim, wf, simd)
return folded_oshape
......
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