Run this model with HF Jobs
Run alex4727/InstantDrag on Hugging Face's managed compute, monitor its progress, and retrieve the results when it's done.
Paste one of these prompts into your coding agent:
Fine-tune on my dataset
Use HF Jobs to fine-tune https://huggingface.co/alex4727/InstantDrag. Ask me which dataset to train on, then push the fine-tuned model to a new model repo. Run `hf jobs --help` first to learn the CLI.
Run batch inference
Use HF Jobs to run batch inference with https://huggingface.co/alex4727/InstantDrag on the inputs in a mounted HF Bucket. Ask me which Bucket to use, then write the outputs back to it and keep each input ID. Run `hf jobs --help` first to learn the CLI.
Instructions to use alex4727/InstantDrag with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusers
How to use alex4727/InstantDrag with Diffusers:
pip install -U diffusers transformers accelerate
import torch from diffusers import DiffusionPipeline from diffusers.utils import load_image # switch to "mps" for apple devices pipe = DiffusionPipeline.from_pretrained("alex4727/InstantDrag", dtype=torch.bfloat16, device_map="cuda") prompt = "Turn this cat into a dog" input_image = load_image("https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/cat.png") image = pipe(image=input_image, prompt=prompt).images[0] - Notebooks
- Google Colab
- Kaggle
Upload folder using huggingface_hub
Browse filesFiles changed (11)
- flowdiffusion/feature_extractor/preprocessor_config.jsonAdded+44
- flowdiffusion/model_index.jsonAdded+26
- flowdiffusion/safety_checker/config.jsonAdded+28
- flowdiffusion/safety_checker/model.safetensorsAdded+3
- flowdiffusion/scheduler/scheduler_config.jsonAdded+29
- flowdiffusion/unet/config.jsonAdded+68
- flowdiffusion/unet/diffusion_pytorch_model.safetensorsAdded+3
- flowdiffusion/vae/config.jsonAdded+38
- flowdiffusion/vae/diffusion_pytorch_model.safetensorsAdded+3
- flowgen_config2.safetensorsAdded+3
- flowgen_config3.safetensorsAdded+3
1234567891011121314151617181920212223242526272829303132333435363738394041424344{ "_valid_processor_keys": [ "images", "do_resize", "size", "resample", "do_center_crop", "crop_size", "do_rescale", "rescale_factor", "do_normalize", "image_mean", "image_std", "do_convert_rgb", "return_tensors", "data_format", "input_data_format" ], "crop_size": { "height": 224, "width": 224 }, "do_center_crop": true, "do_convert_rgb": true, "do_normalize": true, "do_rescale": true, "do_resize": true, "image_mean": [ 0.48145466, 0.4578275, 0.40821073 ], "image_processor_type": "CLIPImageProcessor", "image_std": [ 0.26862954, 0.26130258, 0.27577711 ], "resample": 3, "rescale_factor": 0.00392156862745098, "size": { "shortest_edge": 224 }}1234567891011121314151617181920212223242526{ "_class_name": "FlowDiffusionPipeline", "_diffusers_version": "0.30.1", "_name_or_path": "runwayml/stable-diffusion-v1-5", "feature_extractor": [ "transformers", "CLIPImageProcessor" ], "requires_safety_checker": false, "safety_checker": [ "stable_diffusion", "StableDiffusionSafetyChecker" ], "scheduler": [ "diffusers", "DPMSolverMultistepScheduler" ], "unet": [ "diffusers", "UNet2DConditionModel" ], "vae": [ "diffusers", "AutoencoderKL" ]}12345678910111213141516171819202122232425262728{ "_name_or_path": "/root/data2/huggingface_ckpts/hub/models--runwayml--stable-diffusion-v1-5/snapshots/1d0c4ebf6ff58a5caecab40fa1406526bca4b5b9/safety_checker", "architectures": [ "StableDiffusionSafetyChecker" ], "initializer_factor": 1.0, "logit_scale_init_value": 2.6592, "model_type": "clip", "projection_dim": 768, "text_config": { "dropout": 0.0, "hidden_size": 768, "intermediate_size": 3072, "model_type": "clip_text_model", "num_attention_heads": 12 }, "torch_dtype": "float32", "transformers_version": "4.39.3", "vision_config": { "dropout": 0.0, "hidden_size": 1024, "intermediate_size": 4096, "model_type": "clip_vision_model", "num_attention_heads": 16, "num_hidden_layers": 24, "patch_size": 14 }}123version https://git-lfs.github.com/spec/v1oid sha256:fb351a5ded815c3ff744968ad9c6b218d071b9d313d04f35e813b84b4c0ffde8size 12159796641234567891011121314151617181920212223242526272829{ "_class_name": "DPMSolverMultistepScheduler", "_diffusers_version": "0.30.1", "algorithm_type": "sde-dpmsolver++", "beta_end": 0.012, "beta_schedule": "scaled_linear", "beta_start": 0.00085, "clip_sample": false, "dynamic_thresholding_ratio": 0.995, "euler_at_final": false, "final_sigmas_type": "zero", "lambda_min_clipped": -Infinity, "lower_order_final": true, "num_train_timesteps": 1000, "prediction_type": "epsilon", "rescale_betas_zero_snr": false, "sample_max_value": 1.0, "set_alpha_to_one": false, "skip_prk_steps": true, "solver_order": 2, "solver_type": "midpoint", "steps_offset": 1, "thresholding": false, "timestep_spacing": "linspace", "trained_betas": null, "use_karras_sigmas": true, "use_lu_lambdas": false, "variance_type": null}1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768{ "_class_name": "UNet2DConditionModel", "_diffusers_version": "0.30.1", "_name_or_path": "/root/data2/drag_ckpts/Checkpoints-Diffusion/Diffusion-051/checkpoint-16000", "act_fn": "silu", "addition_embed_type": null, "addition_embed_type_num_heads": 64, "addition_time_embed_dim": null, "attention_head_dim": 8, "attention_type": "default", "block_out_channels": [ 320, 640, 1280, 1280 ], "center_input_sample": false, "class_embed_type": null, "class_embeddings_concat": false, "conv_in_kernel": 3, "conv_out_kernel": 3, "cross_attention_dim": 768, "cross_attention_norm": null, "down_block_types": [ "CrossAttnDownBlock2D", "CrossAttnDownBlock2D", "CrossAttnDownBlock2D", "DownBlock2D" ], "downsample_padding": 1, "dropout": 0.0, "dual_cross_attention": false, "encoder_hid_dim": null, "encoder_hid_dim_type": null, "flip_sin_to_cos": true, "freq_shift": 0, "in_channels": 10, "layers_per_block": 2, "mid_block_only_cross_attention": null, "mid_block_scale_factor": 1, "mid_block_type": "UNetMidBlock2DCrossAttn", "norm_eps": 1e-05, "norm_num_groups": 32, "num_attention_heads": null, "num_class_embeds": null, "only_cross_attention": false, "out_channels": 4, "projection_class_embeddings_input_dim": null, "resnet_out_scale_factor": 1.0, "resnet_skip_time_act": false, "resnet_time_scale_shift": "default", "reverse_transformer_layers_per_block": null, "sample_size": 64, "time_cond_proj_dim": null, "time_embedding_act_fn": null, "time_embedding_dim": null, "time_embedding_type": "positional", "timestep_post_act": null, "transformer_layers_per_block": 1, "up_block_types": [ "UpBlock2D", "CrossAttnUpBlock2D", "CrossAttnUpBlock2D", "CrossAttnUpBlock2D" ], "upcast_attention": false, "use_linear_projection": false}123version https://git-lfs.github.com/spec/v1oid sha256:2eb53a27b6f1fc73411620bce5aca5b04b6bfee38c23b1f31c35a9c302699fa5size 34382366721234567891011121314151617181920212223242526272829303132333435363738{ "_class_name": "AutoencoderKL", "_diffusers_version": "0.30.1", "_name_or_path": "runwayml/stable-diffusion-v1-5", "act_fn": "silu", "block_out_channels": [ 128, 256, 512, 512 ], "down_block_types": [ "DownEncoderBlock2D", "DownEncoderBlock2D", "DownEncoderBlock2D", "DownEncoderBlock2D" ], "force_upcast": true, "in_channels": 3, "latent_channels": 4, "latents_mean": null, "latents_std": null, "layers_per_block": 2, "mid_block_add_attention": true, "norm_num_groups": 32, "out_channels": 3, "sample_size": 512, "scaling_factor": 0.18215, "shift_factor": null, "up_block_types": [ "UpDecoderBlock2D", "UpDecoderBlock2D", "UpDecoderBlock2D", "UpDecoderBlock2D" ], "use_post_quant_conv": true, "use_quant_conv": true}123version https://git-lfs.github.com/spec/v1oid sha256:b4d2b5932bb4151e54e694fd31ccf51fca908223c9485bd56cd0e1d83ad94c49size 334643268123version https://git-lfs.github.com/spec/v1oid sha256:fb81adcdbf17abeb1381754e9607dd7dc1bbae2ea69c6caab1ae727df160ea24size 217684720123version https://git-lfs.github.com/spec/v1oid sha256:786fff9fedd826fe1ce1cf18dfb4a56c89e9ef4344cc2cfdb5ada8750b404246size 217684720flowdiffusion/feature_extractor/preprocessor_config.jsonAdded+44
flowdiffusion/model_index.jsonAdded+26
flowdiffusion/safety_checker/config.jsonAdded+28
flowdiffusion/safety_checker/model.safetensorsAdded+3
flowdiffusion/scheduler/scheduler_config.jsonAdded+29
flowdiffusion/unet/config.jsonAdded+68
flowdiffusion/unet/diffusion_pytorch_model.safetensorsAdded+3
flowdiffusion/vae/config.jsonAdded+38
flowdiffusion/vae/diffusion_pytorch_model.safetensorsAdded+3
flowgen_config2.safetensorsAdded+3
flowgen_config3.safetensorsAdded+3