Decoupled and runtime-writable thresholds (#244)
* [CustomOp] groundwork for decoupled Thresholding op * [Thresholding] more decoupled mode preparation - new attributes for "weight" (really threshold) datatype + n_steps - move thres datatype into acc minimization function and call in convert_to_hls - other helper functions * [Refactor] add make_weight_file for Thresholding layer + wire up * [Threshold] first attempt at Thresholding_Stream_Batch * [Threshold] wire up more decoupled functionality, add test test does not yet pass for multi-PE * [Threshold] use 2 layers of slicers, all decoupled cppsim passes now * [Threshold] more decoupled fixes, most rtlsim tests pass * [Threshold] add unroll to decoupled thresholding, remove unused vars * [ConvertToHLS] allow specifying mem_mode in InferThresholdingLayer * [Threshold] expose interfaces for runtime weight writing * [Test] add runtime threshold test not yet passing * [Threshold] use std::less_equal also for decoupled * [Threshold] use flipped PE axis for decoupled-more rtl thresholds * [Test] runtime threshold reading works * [Test] runtime writable thresholds test working * [ConvertToHLS] fix threshold shape
Showing
- src/finn/custom_op/fpgadataflow/templates.py 53 additions, 0 deletionssrc/finn/custom_op/fpgadataflow/templates.py
- src/finn/custom_op/fpgadataflow/thresholding_batch.py 458 additions, 102 deletionssrc/finn/custom_op/fpgadataflow/thresholding_batch.py
- src/finn/transformation/fpgadataflow/convert_to_hls_layers.py 9 additions, 0 deletions...finn/transformation/fpgadataflow/convert_to_hls_layers.py
- tests/fpgadataflow/test_fpgadataflow_thresholding.py 115 additions, 4 deletionstests/fpgadataflow/test_fpgadataflow_thresholding.py
Loading
Please register or sign in to comment