Skip to content
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bug(cost model): Weight reuse counts calculation #18

Open
anakin1028 opened this issue Mar 22, 2020 · 0 comments
Open

bug(cost model): Weight reuse counts calculation #18

anakin1028 opened this issue Mar 22, 2020 · 0 comments

Comments

@anakin1028
Copy link

anakin1028 commented Mar 22, 2020

For a simple model:
OX=10, OY=10, IC=1, OC=3, FX=3, FY=3
If the hw architecture has 9 PEs and each has capacity==3, that is one weight, one input, one output storage, and the arch has three memory hierarchies, the L1 SRAM buffer has 20 element capacity.

Than the tool will generate the following schedule:

OX 1:10
    OY 1:10
------------
------------
FY 1:3 # parallel
    FX 1:3 # parallel

The access counts in L1 are calculated in tool as follow:

12*12 (input) + 10*10 (output) + 10*10*9 (weight) = 1144

But this is not reasonable for weight to reload to L0, right? since this is already in L0, we don't need to reload it from SRAM again. In this case, the weight access count in SRAM should only be 9.

The reasonable case is when there are weight relevant dimensions(IC, OC, FX, FY) in L1, then the 10x10 multiplier is must.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant