Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[hf-diffusers] Use the latest transformers for diffusers #1027

Merged

Conversation

yeounoh
Copy link
Contributor

@yeounoh yeounoh commented Dec 11, 2023

Description

Use the latest transformers for diffusers, after huggingface/transformers#27799

Tests

Local checkpointing test with the latest transformers

mid_block_only_cross_attention', 'attention_type'} was not found in config. Values will be initialized to default values.
Configuration saved in /tmp/sd-pokemon-model/checkpoint-1/unet_ema/config.json
Model weights saved in /tmp/sd-pokemon-model/checkpoint-1/unet_ema/diffusion_pytorch_model.safetensors
Configuration saved in /tmp/sd-pokemon-model/checkpoint-1/unet/config.json
Model weights saved in /tmp/sd-pokemon-model/checkpoint-1/unet/diffusion_pytorch_model.safetensors
12/11/2023 19:41:19 - INFO - accelerate.checkpointing - Optimizer state saved in /tmp/sd-pokemon-model/checkpoint-1/optimizer.bin
12/11/2023 19:41:19 - INFO - accelerate.checkpointing - Scheduler state saved in /tmp/sd-pokemon-model/checkpoint-1/scheduler.bin
12/11/2023 19:41:19 - INFO - accelerate.checkpointing - Sampler state for dataloader 0 saved in /tmp/sd-pokemon-model/checkpoint-1/sampler.bin
12/11/2023 19:41:19 - INFO - accelerate.checkpointing - Random states saved in /tmp/sd-pokemon-model/checkpoint-1/random_states_0.pkl
12/11/2023 19:41:19 - INFO - __main__ - Saved state to /tmp/sd-pokemon-model/checkpoint-1
Steps: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [01:24<00:00, 67.00s/it, lr=1e-5, step_loss=0.00456]{'requires_safety_checker', 'image_encoder'} was not found in config. Values will be initialized to default values.
                                                                                                                                                                                       `text_config_dict` is provided which will be used to initialize `CLIPTextConfig`. The value `text_config["id2label"]` will be overriden.                           | 0/7 [00:00<?, ?it/s]
`text_config_dict` is provided which will be used to initialize `CLIPTextConfig`. The value `text_config["bos_token_id"]` will be overriden.
`text_config_dict` is provided which will be used to initialize `CLIPTextConfig`. The value `text_config["eos_token_id"]` will be overriden.
Loaded safety_checker as StableDiffusionSafetyChecker from `safety_checker` subfolder of CompVis/stable-diffusion-v1-4.
                                                                                                                                                                                       Loaded feature_extractor as CLIPImageProcessor from `feature_extractor` subfolder of CompVis/stable-diffusion-v1-4.                                        | 1/7 [00:00<00:01,  3.48it/s]
{'timestep_spacing', 'prediction_type'} was not found in config. Values will be initialized to default values.
Loaded scheduler as PNDMScheduler from `scheduler` subfolder of CompVis/stable-diffusion-v1-4.
Loaded tokenizer as CLIPTokenizer from `tokenizer` subfolder of CompVis/stable-diffusion-v1-4.
Loading pipeline components...: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 7/7 [00:00<00:00, 19.33it/s]
Configuration saved in /tmp/sd-pokemon-model/vae/config.json
Model weights saved in /tmp/sd-pokemon-model/vae/diffusion_pytorch_model.safetensors
Configuration saved in /tmp/sd-pokemon-model/unet/config.json
Model weights saved in /tmp/sd-pokemon-model/unet/diffusion_pytorch_model.safetensors
Configuration saved in /tmp/sd-pokemon-model/scheduler/scheduler_config.json
Configuration saved in /tmp/sd-pokemon-model/model_index.json
Steps: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [01:41<00:00, 101.51s/it, lr=1e-5, step_loss=0.00456]

@yeounoh yeounoh self-assigned this Dec 11, 2023
@will-cromar will-cromar merged commit 3a3911f into GoogleCloudPlatform:master Dec 11, 2023
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants