zennit icon indicating copy to clipboard operation
zennit copied to clipboard

WIP: GradOutHook, MergedComposite and multi-hooks

Open chr5tphr opened this issue 2 years ago • 0 comments

  • support the use of multiple hooks by checking for tuples form Composites' module_map and registering all of them (multiple Hook instances only overwrite the results of another)
  • add HookBase as another layer of abstraction, above both Hook (which hooks over one full module) and GradOutHook (which hooks only the output of a function)
  • add GradOutHook, which can modify the gradient at the output of a module
  • add MultiComposite as a parent to MixedComposite
  • add MergedComposite, inheriting from MultiComposite, which merges rules returned from composites for a multi-hook setting rather than using the first hook that applies

Todo:

  • finish functionality
  • finish docstrings
  • extend documentation (How-To etc.)
  • write tests

chr5tphr avatar Apr 24 '23 17:04 chr5tphr