Skip to content

Input Gathering Tasks

Don Kackman edited this page Jan 5, 2025 · 4 revisions

Gathering Functions Documentation

Tasks that collect inputs to feed into workflows

Tasks

gather_images

  • Description: Gathers images from local files and/or URLs.
  • Arguments:
    • glob (optional): A pattern for matching local image files (e.g., "images/*.png").
    • urls: A list of URLs to download images from.
  • Returns: A list of loaded images.
  • Raises:
    • ValueError: If no images are found.

gather_inputs

  • Description: Gathers input arguments for passing to the next task. This is useful for declaring an array of prompts or other arguments to multiplex a pipeline over.
  • Arguments:
    • kwargs: A dictionary of input arguments.
  • Returns: The input arguments unchanged.

gather_videos

  • Description: Gathers videos from local files and/or URLs.
  • Arguments:
    • glob (optional): A pattern for matching local video files (e.g., "videos/*.mp4").
    • urls: A list of URLs to download videos from.
  • Returns: A list of loaded videos.
  • Raises:
    • ValueError: If no videos are found.

Notes

  • The gather_images and gather_videos functions utilize logging to provide detailed information about the loading process, including any errors encountered.
  • Ensure that the glob patterns and URLs provided are correct and accessible to avoid errors during the gathering process.
  • The gather_inputs function is a utility to pass arguments forward without modification, useful in task pipelines.

Clone this wiki locally