code: def used_objs(
      self,
      targets: Optional["TargetType"] = None,
      with_deps: bool = False,
      remote: Optional[str] = None,
      force: bool = False,
      recursive: bool = False,
      jobs: Optional[int] = None,
      push: bool = False,
  ) -> "ObjectContainer":
      used: "ObjectContainer" = defaultdict(set)
      pairs = self.collect_targets(
          targets, recursive=recursive, with_deps=with_deps
      )
      for stage, filter_info in pairs:
          for odb, objs in stage.get_used_objs(
              remote=remote,
              force=force,
              jobs=jobs,
              filter_info=filter_info,
              push=push,
          ).items():
              used[odb].update(objs)
      return used
  
imports: import logging
  import time
  from collections import defaultdict
  from functools import partial
  from itertools import chain
  from typing import TYPE_CHECKING, Any, Callable, Dict, Iterable, Iterator, List, NamedTuple, Optional, Set, Tuple, Union
  from funcy.debug import format_time
  from dvc.dependency import ParamsDependency
  from dvc.fs import LocalFileSystem
  from dvc.fs.callbacks import DEFAULT_CALLBACK
  from dvc.log import logger
  from dvc.utils.objects import cached_property
label_desc: Use image node_id 27 for calling the Index obj's underlying member method code with example usage: obj.used_objs(targets, with_deps, remote, force, recursive, jobs, push) and returns: used