Stable Diffusion ãæ¥ã¦ããã£ã¦ãã¨ã§è²§è ã® GPU ã§ããã¨ããã® Colaboratory ã§ãããã試ãããã®ã ãã©ãã¼ãããã¯ä¸ã§ Python ã®ã³ã¼ãããã¾ãã¾ããããªãã試è¡é¯èª¤ããã®ã¯å¾®å¦ã«ä½é¨ãæªãã
ã¡ãã£ã¨ããã¦ã§ããµã¼ãã¹ã¨ãã¦ç«ã¦ã¦å®è¡ã§ããã¨ããããã©ããªããªãã¯ã©ã¦ããµã¼ãã¹ã帯ã«çã襷ã«é·ãã¨ããæã㧠GPU ãæ°è»½ã«åããããã¨ããã¯ãªãããã â¦â¦ã¨æã£ãããColab ä¸ã« HTTP ãµã¼ããç«ã¦ããããã¨ãç¥ã£ãã®ã§ããã®æ¹æ³ã§ãã£ã¦ã¿ããã¨ã«ããã
ãã£ã¦ã¿ãã½ã¼ã¹ã¯ä»¥ä¸ã
GitHub - motemen/stablediffusion-server-on-colab
README ã«ãããã¼ãããã¯ãéã㦠Huggingface ã®ãã¼ã¯ã³ãåããGPU ãé¸æãã¦å®è¡ããã¨ãµã¼ããèµ·åããããµã¼ããèµ·åããåã®ã»ã«ã«è¡¨ç¤ºããã https://localhost:5000
ã®ãããªãªã³ã¯ãã¯ãªãã¯ããã¨ãç°¡åãªã¦ã§ãã¢ããªã±ã¼ã·ã§ã³ãèµ·åãã¦ãå
¥åãã prompt ããçæããç»åã表示ãã¦ããããç»åãã¯ãªãã¯ãã㨠prompt ããã¡ã¤ã«åã¨ããç»åããã¦ã³ãã¼ãã§ããã®ã§ãããããæ°ã«å
¥ã£ããã¤ã ãä¿åãã¦ããã°ããã
Colab ã® HTTP ãããã·æ©è½ã¯å½è©²ã®ãªã³ã¯ãã¯ãªãã¯ãããã¼ãããã¯ã®ã¦ã¼ã¶ã®ã¿ã«è¦ãããããã«ãã¦ãããããªã®ã§ãä¸ç¨æã«ãªãã¼ãããããããã·ãããä»ã®ã¦ã¼ã¶ã«è¦ããããã㨠403 ã«ãªã£ã¦ãã¾ãã®ã«æ³¨æããããªã£ã¦ãã¾ã£ãããport ãå¤ãã¦åå®è¡ããã¨ããããã§ãããæå ã§éçºãã¦ãã¨ãã« API ã ããµã¼ãã«ãããã·ãã¦ããçªç¶ 403 ã«ãªã£ã¦ãã¾ã£ã¦ããã£ãã
æ§è³ªä¸ããã¼ãããã¯ãéãã¦ãéãã使ãã¾ãããåãæ¥ãä½ã£ããã®ãªã®ã§ããã¼ãä¸ã®é²æ表示ãã¹ãããæ°ã®èª¿æ´æ©è½ãããã¯ã¤ãããã§ããã