Text-to-Image
Diffusers
Safetensors
English
wanghaofan commited on
Commit
f0185a8
1 Parent(s): e017855

Upload 2 files

Browse files
Files changed (3) hide show
  1. .gitattributes +1 -0
  2. README.md +65 -0
  3. examples/0.png +3 -0
.gitattributes CHANGED
@@ -33,3 +33,4 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
33
  *.zip filter=lfs diff=lfs merge=lfs -text
34
  *.zst filter=lfs diff=lfs merge=lfs -text
35
  *tfevents* filter=lfs diff=lfs merge=lfs -text
 
 
33
  *.zip filter=lfs diff=lfs merge=lfs -text
34
  *.zst filter=lfs diff=lfs merge=lfs -text
35
  *tfevents* filter=lfs diff=lfs merge=lfs -text
36
+ examples/0.png filter=lfs diff=lfs merge=lfs -text
README.md CHANGED
@@ -1,3 +1,68 @@
1
  ---
2
  license: apache-2.0
 
 
 
 
3
  ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  ---
2
  license: apache-2.0
3
+ language:
4
+ - en
5
+ library_name: diffusers
6
+ pipeline_tag: text-to-image
7
  ---
8
+
9
+ # InstantID Model Card
10
+
11
+ <div align="center">
12
+
13
+ [**Project Page**](https://instantid.github.io/) **|** [**Paper**](https://arxiv.org/abs/2401.07519) **|** [**Code**](https://github.com/InstantID/InstantID) **|** [🤗 **Gradio demo**](https://huggingface.co/spaces/InstantX/InstantID)
14
+
15
+
16
+ </div>
17
+
18
+ ## Introduction
19
+
20
+ InstantID is a new state-of-the-art tuning-free method to achieve ID-Preserving generation with only single image.
21
+
22
+ <div align="center">
23
+ ![results](./examples/0.png)
24
+ </div>
25
+
26
+
27
+ ## Usage
28
+
29
+ You can directly download the model in this repository.
30
+ You also can download the model in python script:
31
+
32
+ ```python
33
+ from huggingface_hub import hf_hub_download
34
+ hf_hub_download(repo_id="InstantX/InstantID", local_dir="./checkpoints")
35
+ ```
36
+
37
+
38
+ ```python
39
+
40
+ import cv2
41
+ from insightface.app import FaceAnalysis
42
+ import torch
43
+
44
+ app = FaceAnalysis(name="buffalo_l", providers=['CUDAExecutionProvider', 'CPUExecutionProvider'])
45
+ app.prepare(ctx_id=0, det_size=(640, 640))
46
+
47
+ image = cv2.imread("person.jpg")
48
+ faces = app.get(image)
49
+
50
+ faceid_embeds = torch.from_numpy(faces[0].normed_embedding).unsqueeze(0)
51
+ ```
52
+
53
+ For more details, please follow the instructions in our [GitHub repository](https://github.com/InstantID/InstantID).
54
+
55
+
56
+ ## Disclaimer
57
+
58
+ This project is released under Apache License and aims to positively impact the field of AI-driven image generation. Users are granted the freedom to create images using this tool, but they are obligated to comply with local laws and utilize it responsibly. The developers will not assume any responsibility for potential misuse by users.
59
+
60
+ ## Citation
61
+ ```bibtex
62
+ @article{wang2024instantid,
63
+ title={InstantID: Zero-shot Identity-Preserving Generation in Seconds},
64
+ author={Wang, Qixun and Bai, Xu and Wang, Haofan and Qin, Zekui and Chen, Anthony},
65
+ journal={arXiv preprint arXiv:2401.07519},
66
+ year={2024}
67
+ }
68
+ ```
examples/0.png ADDED

Git LFS Details

  • SHA256: b02e16d938c007409c19783d494737230fe7eb890ac60b08267f0f46b9f17f6e
  • Pointer size: 132 Bytes
  • Size of remote file: 8.71 MB