Comments (5)
If you have a huge model or combination of models, then it throws a recursion error. Would it be possible to implement a dependency graph without recursion? @VainF
from torch-pruning.
If you have a huge model or combination of models, then it throws a recursion error. Would it be possible to implement a dependency graph without recursion? @VainF
Hi @vinayak-sharan , thank you for your advice. I will try to re-implement it in the next version.
from torch-pruning.
HI @VainF - Just checking if you have any update for this issue. Thanks!
from torch-pruning.
This is not a bug with the cod per say. The recursion depth for python is 990 calls, it is set to avoid stackoverflow.
File "../../Torch-Pruning/torch_pruning/dependency.py", line 397, in _fix_denpendency_graph
_fix_denpendency_graph(dep.broken_node, dep.handler, new_indices)
[Previous line repeated 990 more times]
As you can see it got the RecursionError after 990 calls of _fix_dependency_graph
You can try and change the recursion depth for your python or alter the pruning percentage (pruning of 50% of the smallest weights is the reason why so many indices are being chosen for pruning , which leads to stackoverflow).
from torch-pruning.
Hi everyone, the non-recursive implementation of dependency graph has been uploaded. I will keep the issue open for further discussion!
from torch-pruning.
Related Issues (20)
- Prune Swin Transfomer:Could not find image processor class in the image processor config or the model config.
- Pruned Yolov8 model not loading? HOT 3
- detecting unwrapped parameters HOT 1
- AttributeError: Can't get attribute '__main__' on <module 'builtins' (built-in)>
- Error when pruning a group with GLU Layer HOT 4
- Improve Iterative Pruning: Verify Pruning Status Before Training HOT 1
- The QRcode of WeChat group has expired, could anyone please share a new one? HOT 1
- Yolov8 upgrade ultralytics version HOT 2
- Cannot calculate importance score for a single group HOT 1
- What is 'N' in "Iห = N ยท I / P{TopN(I )}" HOT 1
- Yolov8 pruning with Taylor criteria
- Add hooks to a module (make sure the hooks are removed), cannot deepcopy OBB model HOT 1
- How to make tracer account for arbitrary restrictions such as making a particular dim divisible by 4? HOT 1
- Hi i have already sparsity the gamma of layerNorm in Segformer. Can I use the methode to prune the model ?
- Clarification around MetaPruner
- How can I get the mask of the pruned model when I apply the soft pruning?
- loss stop reducing after pruning.
- Can the process of structural pruning be rolled back?
- The parameters and computation decreased, but FPS was worse than the baseline model HOT 2
- AttributeError: partially initialized module 'torch_pruning' has no attribute 'DependencyGraph' HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. ๐๐๐
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google โค๏ธ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from torch-pruning.