PhotoMaker icon indicating copy to clipboard operation
PhotoMaker copied to clipboard

Max retries exceeded with url: /api/models/SG161222/RealVisXL_V3.0

Open zys1994 opened this issue 1 year ago • 5 comments

base_model_path = 'SG161222/RealVisXL_V3.0'
photomaker_path = 'checkpoints/photomaker-v1.bin'
device = "cuda"
save_path = "./outputs"

pipe = PhotoMakerStableDiffusionXLPipeline.from_pretrained(
    base_model_path,
    torch_dtype=torch.bfloat16,
    use_safetensors=True,
    variant="fp16",
#     local_files_only=True,
).to(device)

# Load PhotoMaker checkpoint
pipe.load_photomaker_adapter(
    os.path.dirname(photomaker_path),
    subfolder="",
    weight_name=os.path.basename(photomaker_path),
    trigger_word="img"
)

it cause a problem

requests.exceptions.ConnectionError: (MaxRetryError("HTTPSConnectionPool(host='huggingface.co', port=443): Max retries exceeded with url: /api/models/SG161222/RealVisXL_V3.0 (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7f6b3ff042e0>: Failed to establish a new connection: [Errno 101] Network is unreachable'))"), '(Request ID: bda2c78b-67e3-4d93-9fdf-5c1f8e735ff0)'

how to fix it?

zys1994 avatar Jan 18 '24 10:01 zys1994

requests.exceptions.ConnectTimeout: (MaxRetryError("HTTPSConnectionPool(host='huggingface.co', port=443): Max retries exceeded with url: /api/models/SG161222/RealVisXL_V3.0 (Caused by ConnectTimeoutError(<urllib3.connection.HTTPSConnection object at 0x0000025C16D90A60>, 'Connection to huggingface.co timed out. (connect timeout=None)'))"), '(Request ID: e981096f-a9cf-480b-821b-1a2f79b361d5)')

一样问题

monkeycc avatar Jan 18 '24 10:01 monkeycc

https://civitai.com/models/139562?modelVersionId=268861

Paper99 avatar Jan 19 '24 05:01 Paper99

https://civitai.com/models/139562?modelVersionId=268861

How to use the downloaded model?

zys1994 avatar Feb 26 '24 12:02 zys1994

Download this model and edit PhotoMakerStableDiffusionXLPipeline.from_pretrained to PhotoMakerStableDiffusionXLPipeline.from_single_file

Paper99 avatar Feb 28 '24 07:02 Paper99

https://huggingface.co/docs/diffusers/v0.26.3/en/api/loaders/single_file#diffusers.loaders.FromSingleFileMixin.from_single_file.example

Paper99 avatar Feb 28 '24 07:02 Paper99