svntax-dev commited on
Commit
4d2f977
·
verified ·
0 Parent(s):

initial commit

Browse files
Files changed (2) hide show
  1. .gitattributes +55 -0
  2. README.md +111 -0
.gitattributes ADDED
@@ -0,0 +1,55 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ *.7z filter=lfs diff=lfs merge=lfs -text
2
+ *.arrow filter=lfs diff=lfs merge=lfs -text
3
+ *.bin filter=lfs diff=lfs merge=lfs -text
4
+ *.bz2 filter=lfs diff=lfs merge=lfs -text
5
+ *.ckpt filter=lfs diff=lfs merge=lfs -text
6
+ *.ftz filter=lfs diff=lfs merge=lfs -text
7
+ *.gz filter=lfs diff=lfs merge=lfs -text
8
+ *.h5 filter=lfs diff=lfs merge=lfs -text
9
+ *.joblib filter=lfs diff=lfs merge=lfs -text
10
+ *.lfs.* filter=lfs diff=lfs merge=lfs -text
11
+ *.lz4 filter=lfs diff=lfs merge=lfs -text
12
+ *.mlmodel filter=lfs diff=lfs merge=lfs -text
13
+ *.model filter=lfs diff=lfs merge=lfs -text
14
+ *.msgpack filter=lfs diff=lfs merge=lfs -text
15
+ *.npy filter=lfs diff=lfs merge=lfs -text
16
+ *.npz filter=lfs diff=lfs merge=lfs -text
17
+ *.onnx filter=lfs diff=lfs merge=lfs -text
18
+ *.ot filter=lfs diff=lfs merge=lfs -text
19
+ *.parquet filter=lfs diff=lfs merge=lfs -text
20
+ *.pb filter=lfs diff=lfs merge=lfs -text
21
+ *.pickle filter=lfs diff=lfs merge=lfs -text
22
+ *.pkl filter=lfs diff=lfs merge=lfs -text
23
+ *.pt filter=lfs diff=lfs merge=lfs -text
24
+ *.pth filter=lfs diff=lfs merge=lfs -text
25
+ *.rar filter=lfs diff=lfs merge=lfs -text
26
+ *.safetensors filter=lfs diff=lfs merge=lfs -text
27
+ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
28
+ *.tar.* filter=lfs diff=lfs merge=lfs -text
29
+ *.tar filter=lfs diff=lfs merge=lfs -text
30
+ *.tflite filter=lfs diff=lfs merge=lfs -text
31
+ *.tgz filter=lfs diff=lfs merge=lfs -text
32
+ *.wasm filter=lfs diff=lfs merge=lfs -text
33
+ *.xz filter=lfs diff=lfs merge=lfs -text
34
+ *.zip filter=lfs diff=lfs merge=lfs -text
35
+ *.zst filter=lfs diff=lfs merge=lfs -text
36
+ *tfevents* filter=lfs diff=lfs merge=lfs -text
37
+ # Audio files - uncompressed
38
+ *.pcm filter=lfs diff=lfs merge=lfs -text
39
+ *.sam filter=lfs diff=lfs merge=lfs -text
40
+ *.raw filter=lfs diff=lfs merge=lfs -text
41
+ # Audio files - compressed
42
+ *.aac filter=lfs diff=lfs merge=lfs -text
43
+ *.flac filter=lfs diff=lfs merge=lfs -text
44
+ *.mp3 filter=lfs diff=lfs merge=lfs -text
45
+ *.ogg filter=lfs diff=lfs merge=lfs -text
46
+ *.wav filter=lfs diff=lfs merge=lfs -text
47
+ # Image files - uncompressed
48
+ *.bmp filter=lfs diff=lfs merge=lfs -text
49
+ *.gif filter=lfs diff=lfs merge=lfs -text
50
+ *.png filter=lfs diff=lfs merge=lfs -text
51
+ *.tiff filter=lfs diff=lfs merge=lfs -text
52
+ # Image files - compressed
53
+ *.jpg filter=lfs diff=lfs merge=lfs -text
54
+ *.jpeg filter=lfs diff=lfs merge=lfs -text
55
+ *.webp filter=lfs diff=lfs merge=lfs -text
README.md ADDED
@@ -0,0 +1,111 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ tags:
3
+ - text-to-image
4
+ - lora
5
+ - diffusers
6
+ - template:diffusion-lora
7
+ widget:
8
+ - output:
9
+ url: images/knight.png
10
+ text: >-
11
+ A pixel art sprite of a medieval knight wearing metal armor and a helmet
12
+ with a red plume, a sword in one hand and a shield in the other hand. The
13
+ background is white.
14
+ - output:
15
+ url: images/witch.png
16
+ text: >-
17
+ A pixel art image of a witch with long red hair and blue eyes, wearing a
18
+ purple hat and robes trimmed with white and light purple colors. White
19
+ background
20
+ - output:
21
+ url: images/butler.png
22
+ text: >-
23
+ A pixel art image of a man with light brown hair in a long ponytail. He is
24
+ wearing a butler outfit and leaning forward towards the viewer holding a
25
+ bowl of soup. The background is a fancy restaurant with dining tables in the
26
+ back, a chandelier, and a painting of a noblewoman on the left walls.
27
+ - output:
28
+ url: images/island_base.png
29
+ text: >-
30
+ A pixel art aerial shot of an island in the middle of the ocean. On the
31
+ right side of the island is a giant metal orb building with a satellite on
32
+ top of it.
33
+ - output:
34
+ url: images/sand_dunes_tower.png
35
+ text: >-
36
+ A pixel art scene of wide, vast sand dunes with a tall cylindrical tower in
37
+ the far background surrounded by a sandstorm. In the foreground is a
38
+ medieval carriage being pulled by a triceratops moving towards the tower.
39
+ - output:
40
+ url: images/stairs_darkness_eyes.png
41
+ text: >-
42
+ A pixel art image of a top-down view of stairs leading down into darkness.
43
+ In the background the darkness has several faint red eyes.
44
+ - output:
45
+ url: images/ddagger_grid.png
46
+ text: >-
47
+ A pixel art sprite of a short red dagger with a green poisoned tip on the
48
+ top right and a gray and brown hilt. There are 16 copies of the sprite in a
49
+ 4 by 4 grid. The background is white.
50
+ - output:
51
+ url: images/dshield.png
52
+ text: >-
53
+ A pixel art sprite of a rectangular orange shield with the head of a gray
54
+ dragon with its mouth open facing straight. The background is white.
55
+ - output:
56
+ url: images/skeleton_sprite.png
57
+ text: >-
58
+ A pixel art sprite of a skeleton warrior wearing a helmet with two horns,
59
+ holding an axe with both hands raised, facing right, white background
60
+ base_model: baidu/ERNIE-Image
61
+ instance_prompt: null
62
+ license: apache-2.0
63
+ ---
64
+ # pixel_assets_general_ernie_v1
65
+
66
+ <Gallery />
67
+
68
+ ## Model description
69
+
70
+ A pixel art LoRA for general-purpose game assets such as character sprites, creatures, items&#x2F;equipment, backgrounds, scenery, and icons.
71
+
72
+ ## How to use
73
+
74
+ You can use the default ERNIE-Image-Turbo workflow from ComfyUI, and no prompt enhancer needed. The sample images also have workflows.
75
+
76
+ ## How to get pixel-perfect images
77
+
78
+ Downscale by a factor of 4. So 512x512 images should downscale to 128x128, 1024x1024 to 256x256, and so on. Using k-centroid with something like [PixelOE](https:&#x2F;&#x2F;github.com&#x2F;KohakuBlueleaf&#x2F;PixelOE) works well.
79
+
80
+ See examples below:
81
+
82
+ | Raw output | K-centroid downscaled, then upscaled back 4x|
83
+ | ------------- | ------------- |
84
+ | ![knight](https:&#x2F;&#x2F;cdn-uploads.huggingface.co&#x2F;production&#x2F;uploads&#x2F;68dcbc0eb3e9381d15e2cbbc&#x2F;YzaDV03t2nse5CW_1zjmh.png) | ![knight_kcentroid](https:&#x2F;&#x2F;cdn-uploads.huggingface.co&#x2F;production&#x2F;uploads&#x2F;68dcbc0eb3e9381d15e2cbbc&#x2F;3Jz0HXEky8f0-qbPWOSaX.png) |
85
+ | ![witch](https:&#x2F;&#x2F;cdn-uploads.huggingface.co&#x2F;production&#x2F;uploads&#x2F;68dcbc0eb3e9381d15e2cbbc&#x2F;aVTiekoH43PH8ea-GBcuQ.png) | ![witch_kcentroid](https:&#x2F;&#x2F;cdn-uploads.huggingface.co&#x2F;production&#x2F;uploads&#x2F;68dcbc0eb3e9381d15e2cbbc&#x2F;lS8ult9Wy48BmKO0UmVFB.png) |
86
+ | ![butler](https:&#x2F;&#x2F;cdn-uploads.huggingface.co&#x2F;production&#x2F;uploads&#x2F;68dcbc0eb3e9381d15e2cbbc&#x2F;lH4MZ7Ej3idWetAqKpCJ7.png) | ![butler_kcentroid](https:&#x2F;&#x2F;cdn-uploads.huggingface.co&#x2F;production&#x2F;uploads&#x2F;68dcbc0eb3e9381d15e2cbbc&#x2F;F7vttfNn992sgTENoRCow.png) |
87
+ | ![island_base](https:&#x2F;&#x2F;cdn-uploads.huggingface.co&#x2F;production&#x2F;uploads&#x2F;68dcbc0eb3e9381d15e2cbbc&#x2F;pXhyysqvG6eLLNM5BGVSg.png) | ![island_base_kcentroid](https:&#x2F;&#x2F;cdn-uploads.huggingface.co&#x2F;production&#x2F;uploads&#x2F;68dcbc0eb3e9381d15e2cbbc&#x2F;lN2e8MkFf64Xv7cChLSp3.png) |
88
+ | ![sand_dunes_tower](https:&#x2F;&#x2F;cdn-uploads.huggingface.co&#x2F;production&#x2F;uploads&#x2F;68dcbc0eb3e9381d15e2cbbc&#x2F;y52scgX3_d9dVmcRTFCOr.png) | ![sand_dunes_tower_kcentroid](https:&#x2F;&#x2F;cdn-uploads.huggingface.co&#x2F;production&#x2F;uploads&#x2F;68dcbc0eb3e9381d15e2cbbc&#x2F;Box0VumA-MySo_GgI2rnM.png) |
89
+ | ![stairs_darkness_eyes](https:&#x2F;&#x2F;cdn-uploads.huggingface.co&#x2F;production&#x2F;uploads&#x2F;68dcbc0eb3e9381d15e2cbbc&#x2F;ISeSI_bUcjP76iF0uELRj.png) | ![stairs_darkness_eyes_kcentroid](https:&#x2F;&#x2F;cdn-uploads.huggingface.co&#x2F;production&#x2F;uploads&#x2F;68dcbc0eb3e9381d15e2cbbc&#x2F;B0XEbbezIYWZRh9m-rDCH.png)
90
+ | ![ddagger_grid](https:&#x2F;&#x2F;cdn-uploads.huggingface.co&#x2F;production&#x2F;uploads&#x2F;68dcbc0eb3e9381d15e2cbbc&#x2F;U4_aHp1fj2w3QsdgGXdaH.png) | ![ddagger_grid_kcentroid](https:&#x2F;&#x2F;cdn-uploads.huggingface.co&#x2F;production&#x2F;uploads&#x2F;68dcbc0eb3e9381d15e2cbbc&#x2F;JGpWpER4tSkzhfnR2XkON.png) |
91
+ | ![dshield](https:&#x2F;&#x2F;cdn-uploads.huggingface.co&#x2F;production&#x2F;uploads&#x2F;68dcbc0eb3e9381d15e2cbbc&#x2F;h77Zm-gbhfEwwrd3Nj7J7.png) | ![dshield_kcentroid](https:&#x2F;&#x2F;cdn-uploads.huggingface.co&#x2F;production&#x2F;uploads&#x2F;68dcbc0eb3e9381d15e2cbbc&#x2F;wRWXTBX1jvpX2eR52o1c-.png) |
92
+ | ![skeleton_sprite](https:&#x2F;&#x2F;cdn-uploads.huggingface.co&#x2F;production&#x2F;uploads&#x2F;68dcbc0eb3e9381d15e2cbbc&#x2F;zeyVs6sByyMdYJMedVWtq.png) | ![skeleton_sprite_kcentroid](https:&#x2F;&#x2F;cdn-uploads.huggingface.co&#x2F;production&#x2F;uploads&#x2F;68dcbc0eb3e9381d15e2cbbc&#x2F;h-MaleeTuU0klLP95Wo2j.png) |
93
+
94
+ ## Does this LoRA work with ERNIE-Image base?
95
+
96
+ Yes, but I don&#39;t recommend it. **The LoRA is meant to be used with the turbo model.** For some reason, outputs with the base model are very bad. The colors are way too bright or saturated, and there are more issues with anatomy. Maybe there&#39;s a problem with my settings.
97
+
98
+ ## Notes &amp; Issues
99
+
100
+ There are still some issues with certain prompts with the ERNIE turbo model.
101
+ - The model tends to make characters face forward or in a 3&#x2F;4 angle even if your prompt has a different view. This might just be a limit of the turbo model, though.
102
+ - If prompting for sprites, make sure to include &quot;white background&quot; somewhere, otherwise you&#39;ll sometimes get a detailed background.
103
+ - Since I trained this on a 4x upscaled pixel art dataset, if you want smaller sprites, just prompt for copies of a sprite in a 2x2 or 4x4 grid (see the sample images).
104
+ - The dataset this LoRA was trained on contains 512x512, 768x768, and 1024x1024 images, but you can change the resolution and still get decent images.
105
+
106
+
107
+
108
+ ## Download model
109
+
110
+
111
+ [Download](/svntax-dev/pixel_assets_general_ernie_v1/tree/main) them in the Files & versions tab.