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

[circle-opselector] Support --exclude-by-id option #14586

Open
dayo09 opened this issue Jan 23, 2025 · 2 comments
Open

[circle-opselector] Support --exclude-by-id option #14586

dayo09 opened this issue Jan 23, 2025 · 2 comments
Assignees

Comments

@dayo09
Copy link
Contributor

dayo09 commented Jan 23, 2025

What?

I found out some LM models are very big and includes too many unused outputs. However, our internal NPU backend compiler don't support 16+ outputs. To remove some unused outputs from LM Models, circle-opselector is very useful, but it doesn't support 'exclusion by id' functionality. I wish the function is supported.

I tried circle-opselector to remove those unused outputs by splitting numbers, like below.

num="1-59,61-81,83-185,187-207,209-311,313-333,335-437,439-2000" # to exclude 60, 82, 186, ...
circle-opselector --by_id "${num}" $PREFIX.circle $PREFIX.${num}.circle

If circle-opselector had --exclude_by_id(please, suggest me any better name for this option) option or so, it would be much easier.

circle-opselector --by_id "1-2000" --exclude_by_id "60,82,186,..." ...

I will assign myself to tackle this issue, if others agree with its necessity.

@dayo09 dayo09 self-assigned this Jan 23, 2025
@jinevening
Copy link
Contributor

I've heard that you're looking for a tool that selects outputs. Maybe we can make a new option like --output_id, which removes the current outputs and creates outputs for given node ids.

@dayo09
Copy link
Contributor Author

dayo09 commented Jan 24, 2025

@jinevening Thanks. Like you said, I tried to remove output nodes from the graph and it didn't work well.

To be specific, I look forward to these functionalities.

  • Remove node by id
  • Remove output by id
  • Find bridge node lists
    • bridge node here means the node whose removal disconnects the graph. (bottleneck node)
      • Where we usually select to divide the graph.

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

2 participants