Skip to content

Instantly share code, notes, and snippets.

@cosmic-cortex
Created April 29, 2020 06:28
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save cosmic-cortex/208458fd5525f36e19a8bca08b61d54c to your computer and use it in GitHub Desktop.
Save cosmic-cortex/208458fd5525f36e19a8bca08b61d54c to your computer and use it in GitHub Desktop.
class SaveOutput:
def __init__(self):
self.outputs = []
def __call__(self, module, module_in, module_out):
self.outputs.append(module_out)
def clear(self):
self.outputs = []
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment