code: def setup(app):
      # Hook to allow for automatic generation of API docs
      # before doc deployment begins.
      app.connect("builder-inited", generate_apidocs)
  
imports: import subprocess
  import os
  import sys
  from recommonmark.parser import CommonMarkParser
  import sphinx_nameko_theme
  from niftynet.utilities.versioning import get_niftynet_version
label_desc: Use image node_id 2 for calling a global function with example usage: setup(app) without return types