code: def resource_def(depdef, flag_vals):
      resdef, res_location = _resdef_for_dep(depdef, flag_vals)
      return resdef, res_location
  
imports: import os
  import re
  import logging
  import typing
  from guild import cli
  from guild import resolver
  from guild import resourcedef
  from guild import util
label_desc: Use image node_id 8 for calling a global function with example usage: resource_def(depdef, flag_vals) and returns: resdef,  res_location