code: def _remove_allpaths(hps, conditions):
      """Hacky way to recognize some kinds of false dependencies
      Better would be logic programming.
      """
      potential_conds = {}
      for k, v in list(hps.items()):
          if v["node"].name in ("randint", "categorical"):
              upper = v["node"].arg["upper"].obj
              potential_conds[k] = frozenset(
                  [EQ(k, ii) for ii in range(upper)]
              )
  
      for k, v in list(hps.items()):
          if len(v["conditions"]) > 1:
              all_conds = [
                  [c for c in cond if c is not True]
                  for cond in v["conditions"]
              ]
              all_conds = [cond for cond in all_conds if len(cond) >= 1]
              if len(all_conds) == 0:
                  v["conditions"] = set([conditions])
                  continue
  
              depvar = all_conds[0][0].name
  
              all_one_var = all(
                  len(cond) == 1 and cond[0].name == depvar
                  for cond in all_conds
              )
              if all_one_var:
                  conds = [cond[0] for cond in all_conds]
                  if frozenset(conds) == potential_conds[depvar]:
                      v["conditions"] = set([conditions])
                      continue
  
imports: from __future__ import absolute_import
  from builtins import str
  from builtins import zip
  from builtins import range
  from past.builtins import basestring
  from builtins import object
  from functools import partial, wraps
  from .base import DuplicateLabel
  from .pyll.base import Apply, Literal
  from .pyll import scope
  from .pyll import as_apply
label_desc: Use image node_id 16 for calling a global function with example usage: _remove_allpaths(hps, conditions) without return types