nod-ai / SHARK

SHARK - High Performance Machine Learning Distribution
Apache License 2.0
1.41k stars 168 forks source link

shark_sd_20230209_511 Generate Image Error #999

Open bard-regard opened 1 year ago

bard-regard commented 1 year ago

System:

CPU: Intel Core i7 4700k
Memory: 16GB 2133MHz
GPU: AMD Radeon 6700 XT 12GB
OS: Windows 10 - 10.0. 19045 Build 19045
CMD: Powershell APP (from store) (non-admin & admin)
SHARK: shark_sd_20230209_511

UI / Prompt

Model: stabilityai/stable-diffusion-2-1
(default...)
Prompt: cyberpunk forest by Salvador Dali
Negative Prompt: trees, green
Seed: -1
Device: AMD Radeon RX 6700 XT => vulkan://0
stdout - Click me ``` No vmfb found. Compiling and saving to D:\stable-diffusion\shark\clip64_512_512_fp16_stabilityai_stable_diffusion_2_1_base_vulkan-00000000-0300-0000-0000-000000000000.vmfb Using target triple -iree-vulkan-target-triple=rdna2-unknown-windows from command line args Saved vmfb in D:\stable-diffusion\shark\clip64_512_512_fp16_stabilityai_stable_diffusion_2_1_base_vulkan-00000000-0300-0000-0000-000000000000.vmfb. Downloading (…)tokenizer/vocab.json: 100%|████████████████████████████████████████| 1.06M/1.06M [00:00<00:00, 1.70MB/s] huggingface_hub\file_download.py:129: UserWarning: `huggingface_hub` cache-system uses symlinks by default to efficiently store duplicated files but your machine does not support them in C:\Users\BardzyBear\.cache\huggingface\hub. Caching files will still work but in a degraded version that might require more space on your disk. This warning can be disabled by setting the `HF_HUB_DISABLE_SYMLINKS_WARNING` environment variable. For more details, see https://huggingface.co/docs/huggingface_hub/how-to-cache#limitations. To support symlinks on Windows, you either need to activate Developer Mode or to run Python as an administrator. In order to see activate developer mode, see this article: https://docs.microsoft.com/en-us/windows/apps/get-started/enable-your-device-for-development Downloading (…)tokenizer/merges.txt: 100%|██████████████████████████████████████████| 525k/525k [00:00<00:00, 1.32MB/s] Downloading (…)cial_tokens_map.json: 100%|█████████████████████████████████████████████| 460/460 [00:00<00:00, 465kB/s] Downloading (…)okenizer_config.json: 100%|█████████████████████████████████████████████| 824/824 [00:00<00:00, 832kB/s] Downloading artifacts for model unet64_512_512_fp16_stabilityai_stable_diffusion_2_1_base... 100%|█████████████████████████████████████████████████████████████████████████████████| 156/156 [00:00<00:00, 1.12kB/s] 100%|██████████████████████████████████████████████████████████████████████████████| 64.3k/64.3k [00:00<00:00, 193kB/s] 100%|█████████████████████████████████████████████████████████████████████████████████| 640/640 [00:00<00:00, 51.0kB/s] 100%|████████████████████████████████████████████████████████████████████████████████| 289k/289k [00:00<00:00, 544kB/s] 100%|█████████████████████████████████████████████████████████████████████████████| 1.61G/1.61G [00:51<00:00, 33.8MB/s] No vmfb found. Compiling and saving to D:\stable-diffusion\shark\unet64_512_512_fp16_stabilityai_stable_diffusion_2_1_base_vulkan-00000000-0300-0000-0000-000000000000.vmfb Using target triple -iree-vulkan-target-triple=rdna2-unknown-windows from command line args Saved vmfb in D:\stable-diffusion\shark\unet64_512_512_fp16_stabilityai_stable_diffusion_2_1_base_vulkan-00000000-0300-0000-0000-000000000000.vmfb. 50it [00:16, 3.00it/s] 0%| | 0/1 [00:03.197:8:18, .197:11:20, .197:13:27, .197:14:15, .197:22:12, .197:41:20, .197:38:11, .197:43:29, .197:44:17, .197:52:12, .197:68:13, .197:71:20, .197:72:12, .197:75:29, .197:76:17, .197:84:12, .197:95:12, .197:101:16, .197:118:12, .197:143:18, .197:111:12, .197:144:14, .197:145:15, .197:131:12, .197:147:12, .197:155:12, .197:159:13, .197:163:29, .197:164:17, .197:172:12, .197:188:13, .197:191:20, .197:193:29, .197:194:17, .197:202:12, .197:218:13, .197:221:20, .197:222:13, .197:226:29, .197:227:17, .197:235:13, .197:251:13, .197:254:20, .197:256:29, .197:257:17, .197:265:13, .197:281:13, .197:284:20, .197:285:13, .197:289:29, .197:290:17, .197:298:13, .197:314:13, .197:317:20, .197:319:29, .197:320:17, .197:328:13, .197:344:13, .197:347:20, .197:348:13, .197:352:29, .197:353:17, .197:361:13, .197:377:13, .197:380:21, .197:382:30, .197:383:18, .197:391:13, .197:407:13, .197:410:21, .197:411:13, .197:416:21, .197:413:25, .197:418:30, .197:419:18, .197:427:13, .197:443:14, .197:446:21, .197:448:30, .197:449:18, .197:457:13, .197:473:14, .197:476:21, .197:477:13, .197:480:30, .197:481:18, .197:489:13, .197:505:14, .197:508:21, .197:510:30, .197:511:18, .197:519:13, .197:535:14, .197:538:21, .197:539:13, .197:542:30, .197:543:18, .197:551:13, .197:567:14, .197:570:21, .197:572:30, .197:573:18, .197:581:13, .197:597:14, .197:600:21, .197:601:13, .197:606:21, .197:603:27, .197:608:30, .197:609:18, .197:617:13, .197:633:14, .197:636:21, .197:638:30, .197:639:18, .197:647:13, .197:666:21, .197:663:14, .197:669:21, .197:670:13, .197:673:30, .197:674:18, .197:682:13, .197:698:14, .197:701:21, .197:703:30, .197:704:18, .197:712:13, .197:728:14, .197:731:21, .197:732:13, .197:735:30, .197:736:18, .197:744:13, .197:760:14, .197:763:21, .197:765:30, .197:766:18, .197:774:13, .197:790:14, .197:793:21, .197:794:13, .197:799:21, .197:796:27, .197:801:30, .197:802:18, .197:810:13, .197:826:14, .197:829:21, .197:831:30, .197:832:18, .197:840:13, .197:859:21, .197:856:14, .197:862:21, .197:863:13, .197:866:30, .197:867:18, .197:875:13, .197:891:14, .197:894:21, .197:896:30, .197:897:18, .197:905:13, .197:921:14, .197:924:21, .197:925:13, .197:928:30, .197:929:18, .197:937:13, .197:953:14, .197:956:21, .197:958:30, .197:959:18, .197:967:13, .197:983:14, .197:986:21, .197:987:13, .197:990:30, .197:991:18, .197:999:13, .197:1015:14, .197:1018:21 ] ```
bard-regard commented 1 year ago

Will try 492 _'with --clear_all & new folder'_ as mentioned in markdown

bard-regard commented 1 year ago

492 works! N.B #492 runs 1.22it/s and #511 runs 3-4it/s *all run at 1.3it/s I wonder if there is any release between the two which has this performance boost and also works?

bard-regard commented 1 year ago

Being quite new to all of this I tried setting 492 to use the 784x784 resolution and adjusted steps to 80 & cfg scale to 8.8. The exe started downloading extra files, I think for the resolution. It seems to be stuck for at least 20m after this line. Maybe larger images do take much longer to setup env; I'm not sure. Looking at the releases, I might try 506 next as thats a nice bug fix. For now, I'm coming off.

...
torch\storage.py:899: UserWarning: TypedStorage is deprecated. It will be removed in the future and UntypedStorage will be the only storage class. This should only matter to you if you are using storages directly.  To access UntypedStorage directly, use tensor.untyped_storage() instead of tensor.storage()
  storage = cls(wrap_storage=untyped_storage)
torch\fx\node.py:244: UserWarning: Trying to prepend a node to itself. This behavior has no effect on the graph.
  warnings.warn("Trying to prepend a node to itself. This behavior has no effect on the graph.")
No vmfb found. Compiling and saving to D:\stable-diffusion\shark\492\unet1_64_784_784_fp16_stabilityai_stable_diffusion_2_1_vulkan-00000000-0300-0000-0000-000000000000.vmfb
Using target triple -iree-vulkan-target-triple=rdna2-unknown-windows from command line args
bard-regard commented 1 year ago

v.506

Also, the only working scheduler is SharkEulerDiscrete, everything else produces this brown picture with a mild texture N.B Looks like this might be related to a .yaml file, mentioned on reddit

Brown textured image ![homeless_man__h_1364257762_230212_104202](https://user-images.githubusercontent.com/29786941/218306553-f93cae2b-86b6-484c-be10-82bb37344c3c.png)