






from .imports import is_tqdm_available


if is_tqdm_available():
 from tqdm.auto import tqdm as _tqdm

from ..state import PartialState







def   SCREAMING_SNAKE_CASE       (				snake_case_      :							bool = True  ,						*snake_case_      :							Any  ,						**snake_case_      :							str     ):
 if not is_tqdm_available():
  raise ImportError("Accelerate's `tqdm` module requires `tqdm` to be installed. Please run `pip install tqdm`."     )
 snake_case__				:   Union[str, Any]     =						False
 if main_process_only:
  snake_case__				:   Dict     =						PartialState().local_process_index == 0
 return _tqdm(*snake_case_  ,						**snake_case_  ,						disable=snake_case_     )











# tests directory-specific settings - this file is run automatically
# by pytest before any tests are run

import sys
import warnings
from os.path import abspath, dirname, join


# allow having multiple repository checkouts and not needing to remember to rerun
# 'pip install -e .[dev]' when switching between checkouts and running tests.
__lowerCamelCase      :    Dict   		=   abspath(join(dirname(dirname(__file__)), """src"""))
sys.path.insert(1, git_repo_path)

# silence FutureWarning warnings in tests since often we can't act on them until
# they become normal warnings - i.e. the tests still need to test the current functionality
warnings.simplefilter(action="""ignore""", category=FutureWarning)







def   SCREAMING_SNAKE_CASE       (				snake_case_      :							str     ):
	from diffusers.utils.testing_utils import pytest_addoption_shared

	pytest_addoption_shared(snake_case_     )







def   SCREAMING_SNAKE_CASE       (				snake_case_      :							Any     ):
	from diffusers.utils.testing_utils import pytest_terminal_summary_main

	snake_case__				:   Optional[int]     =						terminalreporter.config.getoption("--make-reports"     )
	if make_reports:
		pytest_terminal_summary_main(snake_case_  ,						id=snake_case_     )



