-
Notifications
You must be signed in to change notification settings - Fork 0
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
Integrate scripts #7
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
PR Type: Enhancement
PR Summary: This pull request introduces scripts for finding concepts in a model using Layer-wise Relevance Propagation (LRP) and a dataset of boards. It adds two main files: find_concepts.py
and helpers.py
under the src/lczerolens/xai
directory. The find_concepts.py
script is designed to identify and analyze concepts within a given model using a specific dataset, leveraging the LRP technique for interpretability. The helpers.py
file provides support functionalities such as a dynamic sampler for data loading and a modified feature visualization class to aid in the analysis and visualization of the identified concepts.
Decision: Comment
📝 Type: 'Enhancement' - not supported yet.
- Sourcery currently only approves 'Typo fix' PRs.
✅ Issue addressed: this change correctly addresses the issue or implements the desired feature.
No details provided.
📝 Complexity: the changes are too large or complex for Sourcery to approve.
- Unsupported files: the diff contains files that Sourcery does not currently support during reviews.
General suggestions:
- Ensure that all new classes and methods have comprehensive docstrings to improve code readability and maintainability.
- Consider implementing error handling and validation checks where assumptions about the input or the state of the system are made, to enhance the robustness of the scripts.
- It might be beneficial to include unit tests for the new functionalities introduced in this pull request to ensure their correctness and prevent future regressions.
- Review the use of type hints throughout the new code to ensure consistency and clarity, particularly in method signatures.
Thanks for using Sourcery. We offer it for free for open source projects and would be very grateful if you could help us grow. If you like it, would you consider sharing Sourcery on your favourite social media? ✨
from zennit.composites import Composite, NameMapComposite | ||
|
||
|
||
class DynamicSampler(Sampler[int]): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
suggestion (llm): The DynamicSampler
class is a good addition for flexibility in sampling indices. However, consider adding type hints for the set_indices
method to maintain consistency and clarity in the codebase.
No description provided.