Gradio not founding acelerate

hi, im having a problem while trying to set up accelerate in gradio stable diffusion local install (because im using an amd gpu). i tryied to install accelerate whit the command: pip install accelerate and i set it up whit the following command: accelerate config and when i open the model in the gradio web host, it give me the following error: (Cannot initialize model with low cpu memory usage because accelerate was not found in the environment. Defaulting to low_cpu_mem_usage=False. It is strongly recommended to install accelerate for faster and less memory-intense model loading. You can do so with:
pip install accelerate

i tryied to check if accelerate is installed and it is and i have the following config:

  • Accelerate version: 0.15.0
  • Platform: Windows-10-10.0.22621-SP0
  • Python version: 3.10.6
  • Numpy version: 1.24.1
  • PyTorch version (GPU?): 1.13.1+cpu (False)
  • Accelerate default config:
    - compute_environment: LOCAL_MACHINE
    - distributed_type: NO
    - mixed_precision: fp16
    - use_cpu: False
    - dynamo_backend: ONNXRT
    - num_processes: 1
    - machine_rank: 0
    - num_machines: 1
    - gpu_ids: all
    - main_process_ip: None
    - main_process_port: None
    - rdzv_backend: static
    - same_network: True
    - main_training_function: main
    - deepspeed_config: {}
    - fsdp_config: {}
    - megatron_lm_config: {}
    - downcast_bf16: no
    - tpu_name: None
    - tpu_zone: None
    - command_file: None
    - commands: None

watching thru the script i think the problem is about this line:

accelerate_available = importlib.util.find_spec(“accelerate”) is not None
try:
_accelerate_version = importlib_metadata.version(“accelerate”)
logger.debug(f"Successfully imported accelerate version {_accelerate_version}")
except importlib_metadata.PackageNotFoundError:
_accelerate_available = False

thanks for the help

1 Like