


'''simple docstring'''
import operator as op


UpperCamelCase__    					=      '''scaler.pt'''
UpperCamelCase__    					=      '''pytorch_model'''
UpperCamelCase__    					=      '''random_states'''
UpperCamelCase__    					=      '''optimizer'''
UpperCamelCase__    					=      '''scheduler'''
UpperCamelCase__    					=      '''pytorch_model.bin'''
UpperCamelCase__    					=      '''pytorch_model.bin.index.json'''
UpperCamelCase__    					=      '''model.safetensors'''
UpperCamelCase__    					=      '''model.safetensors.index.json'''
UpperCamelCase__    					=      '''1.10.2'''
UpperCamelCase__    					=      '''py38'''
UpperCamelCase__    					=      '''4.17.0'''
UpperCamelCase__    					=      ['''ml.p3.16xlarge''', '''ml.p3dn.24xlarge''', '''ml.p4dn.24xlarge''']
UpperCamelCase__    					=      ['''FULL_SHARD''', '''SHARD_GRAD_OP''', '''NO_SHARD''', '''HYBRID_SHARD''', '''HYBRID_SHARD_ZERO2''']
UpperCamelCase__    					=      ['''TRANSFORMER_BASED_WRAP''', '''SIZE_BASED_WRAP''', '''NO_WRAP''']
UpperCamelCase__    					=      ['''BACKWARD_PRE''', '''BACKWARD_POST''', '''NO_PREFETCH''']
UpperCamelCase__    					=      ['''FULL_STATE_DICT''', '''LOCAL_STATE_DICT''', '''SHARDED_STATE_DICT''']
UpperCamelCase__    					=      '''2.0.1'''
UpperCamelCase__    					=      ['''pdsh''', '''standard''', '''openmpi''', '''mvapich''']
UpperCamelCase__    					=      ['''default''', '''reduce-overhead''', '''max-autotune''']

UpperCamelCase__    					=      {'''>''': op.gt, '''>=''': op.ge, '''==''': op.eq, '''!=''': op.ne, '''<=''': op.le, '''<''': op.lt}

# These are the args for `torch.distributed.launch` for pytorch < 1.9
UpperCamelCase__    					=      [
    '''nnodes''',
    '''nproc_per_node''',
    '''rdzv_backend''',
    '''rdzv_endpoint''',
    '''rdzv_id''',
    '''rdzv_conf''',
    '''standalone''',
    '''max_restarts''',
    '''monitor_interval''',
    '''start_method''',
    '''role''',
    '''module''',
    '''m''',
    '''no_python''',
    '''run_path''',
    '''log_dir''',
    '''r''',
    '''redirects''',
    '''t''',
    '''tee''',
    '''node_rank''',
    '''master_addr''',
    '''master_port''',
]

UpperCamelCase__    					=      ['''DEEPSPEED''', '''MULTI_GPU''', '''FSDP''', '''MEGATRON_LM''']
UpperCamelCase__    					=      ['''DEEPSPEED''', '''MULTI_XPU''', '''FSDP''']




'''simple docstring'''
import unittest

from accelerate import debug_launcher
from accelerate.test_utils import require_cpu, test_ops, test_script




@require_cpu
class 			lowerCamelCase_   (	unittest.TestCase      ):






      def lowercase_							(					self				:    Tuple ):


          '''simple docstring'''


          debug_launcher(test_script.main )






      def lowercase_							(					self				:    List[str] ):


          '''simple docstring'''


          debug_launcher(test_ops.main )
