Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

[Streamline] Allow AbsorbSignBiasIntoMultiThreshold to absorb any bias#1173

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Open
iksnagreb wants to merge6 commits intoXilinx:dev
base:dev
Choose a base branch
Loading
fromiksnagreb:feature/absorb-bias-into-multithreshold
Open
Changes from1 commit
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
NextNext commit
[Streamline] Allow AbsorbSignBiasIntoMultiThreshold to absorb any bias
Note: Keep the name indicating only handling signed-bias but adjust thedatatype inference after absorbing the bias to handle signed bias aswell as outputs.
  • Loading branch information
@iksnagreb
iksnagreb committedAug 28, 2024
commit323cd9f1d0808d0ee80b49dba2f12bbb51d89376
9 changes: 8 additions & 1 deletionsrc/finn/transformation/streamline/absorb.py
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -80,7 +80,14 @@ def apply(self, model):
steps = T.shape[-1]
new_min = bias
new_max = steps + bias
odt = DataType.get_smallest_possible(steps).name.replace("UINT", "INT")

# Allows the signedness to change depending on the new
# output range [new_min,new_max]
if abs(new_min) > abs(new_max):
odt = DataType.get_smallest_possible(new_min).name
else:
odt = DataType.get_smallest_possible(new_max).name

odt = DataType[odt]
assert odt.allowed(new_max) and odt.allowed(
new_min
Expand Down

[8]ページ先頭

©2009-2025 Movatter.jp