Amphion icon indicating copy to clipboard operation
Amphion copied to clipboard

[Help]: Clarification on CPU Compatibility and Requirements. Does Cpu work here?

Open zhouruc16 opened this issue 1 year ago • 2 comments

Problem Overview

Hi team,

I would like to clarify if Amphion supports running on CPU-only systems. While testing the framework on a CPU machine, I encountered some issues that may indicate GPU dependency, but there is no clear mention of CPU requirements in the documentation or issues section. Questions Is Amphion designed to run on CPU-only hardware, or is a GPU mandatory for certain tasks or models? If CPU compatibility is supported: Are there any specific configurations or flags to enable CPU inference?

when I tried to use cpu, this error happened RuntimeError: Error while trying to find names to remove to save state dict, but found no suitable name to keep for saving amongst: {'model.head.istft.window'}. None is covering the entire storage.Refusing to save/load the model since you could be storing much more memory than needed. Please refer to https://huggingface.co/docs/safetensors/torch_shared_tensors for more information. Or open an issue.

zhouruc16 avatar Dec 17 '24 02:12 zhouruc16

Regarding Emilia pipeline (preprocessors/Emilia), the app does work for CPU. Details about usage & fix can be found here .

3manifold avatar Jan 13 '25 09:01 3manifold

I managed to resolve the RuntimeError with safetensors loading.

The issue was a duplicate line in models/tts/maskgct/gradio_demo.py: safetensors.torch.load_model(codec_decoder, codec_decoder_ckpt)

Simply removing one of the two identical lines fixed the problem.

BeRiriJ avatar May 29 '25 13:05 BeRiriJ