waifu2x-caffe for Ubuntu. It's adapted from https://github.com/onishy/Waifu2x-Caffe-Linux .
See INSTALL-linux.md
.
å¶äœè : lltcggie
æ¬ãœããã¯ãç»åå€æãœãããŠã§ã¢ãwaifu2xãã®å€ææ©èœã®ã¿ãã CaffeãçšããŠæžãçŽããWindowsåãã«ãã«ããããœããã§ãã CPUã§å€æããããšãåºæ¥ãŸãããCUDA(ãããã¯cuDNN)ã䜿ããšCPUããé«éã«å€æããããšãåºæ¥ãŸãã
GUI supports English, Japanese, Simplified Chinese, Traditional Chinese, Korean, Turkish, and French.
ãœããã®ããŠã³ããŒãã¯ãã¡ãã®releasesããŒãžã®ãDownloadsãã®é ã§åºæ¥ãŸãã
ãã®ãœãããåäœãããã«ã¯æäœã§ã以äžã®ç°å¢ãå¿ èŠã§ãã
- OS : Windows Vista以é 64bit (32bitçšexeã¯ãããŸãã)
- ã¡ã¢ãª : 空ãã¡ã¢ãª1GBä»¥äž (ãã ããå€æããç»åãµã€ãºã«ãã)
- GPU : Compute Capability 2.0 以äžã®NVIDIA補GPU(CPUã§å€æããå Žåã¯äžèŠ)
- Visual C++ 2013 åé åžå¯èœããã±ãŒãžãã€ã³ã¹ããŒã«ãããŠããããš(å¿
é )
- äžèšããã±ãŒãžã¯ãã¡ã
ããŠã³ããŒã
ãã¿ã³ãæŒããåŸãvcredist_x64.exe
ãéžæããããŠã³ããŒãã»ã€ã³ã¹ããŒã«ãè¡ã£ãŠäžããã- èŠã€ãããªãå Žåã¯ããVisual C++ 2013 åé åžå¯èœããã±ãŒãžãã§æ€çŽ¢ããŠã¿ãŠäžããã
cuDNNã§å€æããå Žåã¯ããã«
- GPU : Compute Capability 3.0 以äžã®NVIDIA補GPU
èªåã®GPUã®Compute Capabilityãç¥ãããå Žåã¯ãã¡ãã®ããŒãžã§èª¿ã¹ãŠäžããã
cuDNNã¯NVIDIA補GPUã§ã®ã¿ã€ãããé«éãªæ©æ¢°åŠç¿åãã®ã©ã€ãã©ãªã§ãã cuDNNã䜿ããªããŠãCUDAã§å€æåºæ¥ãŸãããcuDNNã䜿ããšä»¥äžã®ãããªå©ç¹ããããŸãã
- 䜿çšããGPUã®çš®é¡ã«ãã£ãŠã¯ç»åãããé«éã«å€æããããšãåºæ¥ã
- VRAMã®äœ¿çšéãæžããããšãåºæ¥ã(æäœã§ãCUDAã®ååæªæºãåå²ãµã€ãºã倧ãããªãã»ã©å·®ãéããŠãã)
ãã®ãããªå©ç¹ãããcuDNNã§ãããã©ã€ã»ã³ã¹ã®é¢ä¿äžåäœã«å¿
èŠãªãã¡ã€ã«ãé
åžããããšãåºæ¥ãŸããã
ãªã®ã§ãcuDNNã䜿ããã人ã¯ãã¡ãã®ããŒãžã§Windowsåããã€ããª(v5.1 RC以é)ãããŠã³ããŒããã
ãcudnn64_6.dllããwaifu2x-caffeã®ãã©ã«ãã«å
¥ããŠäžããã
ãªãããœãããèµ·åããŠããæäžã«dllãå
¥ããå Žåã¯ãœãããèµ·åããªãããŠãã ããã
(cuDNNãããŠã³ããŒãããã«ã¯NVIDIA Developerãžã®ç»é²ãšCUDA Registered Developersãžã®ç»é²ãå¿
èŠã§ãã
CUDA Registered Developersã¯ãããã(ç°¡åãª)審æ»ãããã£ãœãã®ã§ç»é²ããŠãããã«cuDNNãããŠã³ããŒãåºæ¥ãããã§ã¯ãããŸããã)
äœè ã®ç°å¢ã§ã®åŠçé床ãVRAM䜿çšéã®èšæž¬çµæã¯ä»¥äžã®éãã§ãã
- GPU : GTX 980 Ti
- VRAM : 6GB
- åŠçå 容 : 1000*1000ã®PNG 4chç»åã§ãã€ãºé€å»ãšæ¡å€§ãJPEGãã€ãºé€å»ã¬ãã«1ãæ¡å€§ç2.00ãTTAã¢ãŒãæªäœ¿çš
- åŠçæéèšæž¬æ¹æ³ : CUIçã§10åã®å¹³ååŠçæéãèšæž¬ããã ãåãã«2åäºåã«åŠçãè¡ã(åæåã«ãããæéãå«ããªãããã«ãããã)
- VRAM䜿çšéèšç®æ¹æ³ : (GUIçã§åŠçäžã«äœ¿çšããæ倧VRAM) - (GUIçãèµ·åããåŸã®VRAM䜿çšé)
cuDNN RGBã¢ãã«
åå²ãµã€ãº | åŠçæé | VRAM䜿çšé(MB) |
---|---|---|
100 | 00:00:03.170 | 278 |
125 | 00:00:02.745 | 279 |
200 | 00:00:02.253 | 365 |
250 | 00:00:02.147 | 446 |
500 | 00:00:01.982 | 1110 |
CUDA RGBã¢ãã«
åå²ãµã€ãº | åŠçæé | VRAM䜿çšé(MB) |
---|---|---|
100 | 00:00:06.192 | 724 |
125 | 00:00:05.504 | 724 |
200 | 00:00:04.642 | 1556 |
250 | 00:00:04.436 | 2345 |
500 | èšæž¬äžèœ | èšæž¬äžèœ(6144以äž) |
cuDNN UpRGBã¢ãã«
åå²ãµã€ãº | åŠçæé | VRAM䜿çšé(MB) |
---|---|---|
100 | 00:00:02.831 | 328 |
125 | 00:00:02.573 | 329 |
200 | 00:00:02.261 | 461 |
250 | 00:00:02.150 | 578 |
500 | 00:00:01.991 | 1554 |
CUDA UpRGBã¢ãã«
åå²ãµã€ãº | åŠçæé | VRAM䜿çšé(MB) |
---|---|---|
100 | 00:00:03.669 | 788 |
125 | 00:00:03.382 | 787 |
200 | 00:00:02.965 | 1596 |
250 | 00:00:02.852 | 2345 |
500 | èšæž¬äžèœ | èšæž¬äžèœ(6144以äž) |
ãwaifu2x-caffe.exeãã¯GUIãœããã§ããããã«ã¯ãªãã¯ã§èµ·åããŸãã ãŸãã¯ãšã¯ã¹ãããŒã©ã§ãwaifu2x-caffe.exeãã«ãã¡ã€ã«ããã©ã«ãããã©ãã°&ããããã§æŸã蟌ããšãååèµ·åæã®èšå®ã§å€æãè¡ããŸãã ãã®å Žåãèšå®ã«ãã£ãŠã¯å€æã«æåãããèªåã§ãã€ã¢ãã°ãéããããŸãã ãŸããGUIã§ãã³ãã³ãã©ã€ã³ã«ãããªãã·ã§ã³èšå®ãè¡ãããšãåºæ¥ãŸãã 詳ããã¯ã³ãã³ãã©ã€ã³ãªãã·ã§ã³(å ±é)ãšã³ãã³ãã©ã€ã³ãªãã·ã§ã³(GUIç)ã®é ããèªã¿ãã ããã
èµ·ååŸããå ¥åãã¹ãæ¬ã«ç»åããã©ã«ãããã©ãã°&ããããã§æŸã蟌ããšãåºåãã¹ãæ¬ãèªåã§èšå®ãããŸãã åºåå ãå€ãããå Žåã¯ãåºåãã¹ãæ¬ãå€æŽããŠäžããã
奜ã¿ã«åãããŠå€æèšå®ãå€æŽããããšãåºæ¥ãŸãã
ãã¡ã€ã«ã®å
¥åºåã«é¢ããèšå®é
ç®çŸ€ã§ãã
å€æããããã¡ã€ã«ã®ãã¹ãæå®ããŸãã
ãã©ã«ããæå®ããå Žåã¯ããµããã©ã«ãå
ãå«ããããã©ã«ãå
ã®å€æããæ¡åŒµåããä»ããã¡ã€ã«ãå€æ察象ãšããŸãã
è€æ°ã®ãã¡ã€ã«ããã©ã«ãããã©ãã°ã§æå®ããããšãåºæ¥ãŸãã
ãã®å Žåã¯æ°ãããã©ã«ãã®äžã«ãã¡ã€ã«ããã©ã«ãæ§é ãç¶æãããŸãŸåºåãããŸãã
ïŒå
¥åãã¹æ¬ã«ã¯ã(Multi Files)ããšè¡šç€ºãããŸããåºåãã©ã«ãåã¯ããŠã¹ã§æŽãã§ãããã¡ã€ã«ããã©ã«ãåããçæãããŸãïŒ
åç
§ãã¿ã³ãæŒããŠãã¡ã€ã«ãéžæããå Žåãåäœã®ãã¡ã€ã«ããã©ã«ãããè€æ°ã®ãã¡ã€ã«ãéžæã§ããŸãã
å€æåŸã®ç»åãä¿åãããã¹ãæå®ããŸãã
ãå
¥åãã¹ã㧠ãã©ã«ããæå®ããå Žåã¯ãæå®ãããã©ã«ãã®äžã«å€æãããã¡ã€ã«ã(ãã©ã«ãæ§é ããã®ãŸãŸã§)ä¿åããŸããæå®ãããã©ã«ãããªãå Žåã¯èªåã§äœæããŸãã
ãå
¥åãã¹ãããã©ã«ãã®å Žåã®ããã©ã«ãå
ã®å€æããç»åã®æ¡åŒµåãæå®ããŸãã
ããã©ã«ãå€ã¯`png:jpg:jpeg:tif:tiff:bmp:tga`ã§ãã
ãŸããåºåãæåã¯`:`ã§ãã
倧æåå°æåã¯åºå¥ããŸããã
äŸ. png:jpg:jpeg:tif:tiff:bmp:tga
å€æåŸã®ç»åã®åœ¢åŒãæå®ããŸãã
ãåºåç»è³ªèšå®ããšãåºå深床ãããæ°ãã«èšå®ã§ããå€ã¯ããã§æå®ãã圢åŒã«ããç°ãªããŸãã
å€æåŸã®ç»åã®ç»è³ªãæå®ããŸãã
èšå®ã§ããå€ã¯æŽæ°ã§ãã
æå®ã§ããå€ã®ç¯å²ãšæå³ã¯ãåºåæ¡åŒµåãã§èšå®ãã圢åŒã«ããç°ãªããŸãã
* .jpg : å€ã®ç¯å²(0ïœ100) æ°åãé«ãã»ã©é«ç»è³ª
* .webp : å€ã®ç¯å²(1ïœ100) æ°åãé«ãã»ã©é«ç»è³ª 100ã ãšå¯éå§çž®
* .tga : å€ã®ç¯å²(0ïœ1) 0ãªãå§çž®ãªãã1ãªãRLEå§çž®
å€æåŸã®ç»åã®1ãã£ã³ãã«ãããã®ãããæ°ãæå®ããŸãã
æå®ã§ããå€ã¯ãåºåæ¡åŒµåãã§èšå®ãã圢åŒã«ããç°ãªããŸãã
ãã¡ã€ã«å€æã®åŠçæ¹æ³ãç»è³ªã«é¢ããèšå®é
ç®çŸ€ã§ãã
å€æã¢ãŒããæå®ããŸãã
* ãã€ãºé€å»ãšæ¡å€§ : ãã€ãºé€å»ãšæ¡å€§ãè¡ããŸã
* æ¡å€§ : æ¡å€§ãè¡ããŸã
* ãã€ãºé€å» : ãã€ãºé€å»ãè¡ããŸã
* ãã€ãºé€å»(èªåå€å¥)ãšæ¡å€§ : æ¡å€§ãè¡ããŸããå
¥åãJPEGç»åã®å Žåã®ã¿ãã€ãºé€å»ãè¡ããŸã
ãã€ãºé€å»ã¬ãã«ãæå®ããŸããã¬ãã«ã®é«ãã»ãããã匷åã«ãã€ãºãé€å»ããŸãããã®ã£ãºããšããçµµã«ãªãå¯èœæ§ããããŸãã
æ¡å€§åŸã®ãµã€ãºã®èšå®ãè¡ããŸãã
* æ¡å€§çã§æå® : ç»åãæå®ã®æ¡å€§çã§æ¡å€§ããŸã
* å€æåŸã®æšªå¹
ã§æå® : ç»åã®çžŠæšªæ¯ãç¶æãããŸãŸãæå®ããã暪å¹
ã«ãªãããã«æ¡å€§ããŸã(åäœã¯ãã¯ã»ã«)
* å€æåŸã®çžŠå¹
ã§æå® : ç»åã®çžŠæšªæ¯ãç¶æãããŸãŸãæå®ããã瞊å¹
ã«ãªãããã«æ¡å€§ããŸã(åäœã¯ãã¯ã»ã«)
* å€æåŸã®çžŠæšªå¹
ã§æå® : æå®ããã瞊暪å¹
ã«ãªãããã«æ¡å€§ããŸããã1920x1080ãã®ããã«æå®ããŸã(åäœã¯ãã¯ã»ã«)
2åãè¶
ããæ¡å€§çã®å Žåã(ãã€ãºãé€å»ããå Žåã¯æåã®1åã ãè¡ã)æå®ãããæ¡å€§çãè¶
ãããŸã§2åãã€æ¡å€§ãã2ã®çŽ¯ä¹åã§ãªãæ¡å€§çã®å Žåã¯æåŸã«çž®å°ãããšããåŠçãè¡ããŸãããã®ããå€æçµæãã®ã£ãºããšããçµµã«ãªãå¯èœæ§ããããŸãã
䜿çšããã¢ãã«ãæå®ããŸãã
å€æ察象ã®ç»åã«ãã£ãŠæé©ãªã¢ãã«ã¯ç°ãªãã®ã§ãæ§ã
ãªã¢ãã«ãè©ŠããŠã¿ãããšãããããããŸãã
* 2次å
ã€ã©ã¹ã(RGBã¢ãã«) : ç»åã®RGBãã¹ãŠãå€æãã2次å
ã€ã©ã¹ãçšã¢ãã«
* åçã»ã¢ãã¡(Photoã¢ãã«) : åçã»ã¢ãã¡çšã®ã¢ãã«
* 2次å
ã€ã©ã¹ã(UpRGBã¢ãã«) : 2次å
ã€ã©ã¹ã(RGBã¢ãã«)ããé«éãã€åç以äžã®ç»è³ªã§å€æããã¢ãã«ããã ãRGBã¢ãã«ããæ¶è²»ããã¡ã¢ãª(VRAM)ã®éãå€ãã®ã§ãå€æäžã«åŒ·å¶çµäºããå Žåã¯åå²ãµã€ãºã調ç¯ããããš
* åçã»ã¢ãã¡(UpPhotoã¢ãã«) : åçã»ã¢ãã¡(Photoã¢ãã«)ããé«éãã€åç以äžã®ç»è³ªã§å€æããã¢ãã«ããã ãPhotoã¢ãã«ããæ¶è²»ããã¡ã¢ãª(VRAM)ã®éãå€ãã®ã§ãå€æäžã«åŒ·å¶çµäºããå Žåã¯åå²ãµã€ãºã調ç¯ããããš
* 2次å
ã€ã©ã¹ã(Yã¢ãã«) : ç»åã®èŒåºŠã®ã¿ãå€æãã2次å
ã€ã©ã¹ãçšã¢ãã«
TTA(Test-Time Augmentation)ã¢ãŒãã䜿ããã©ãããæå®ããŸãã
TTAã¢ãŒãã䜿ããšå€æã8åé
ããªã代ããã«ãPSNR(ç»åã®è©äŸ¡ææ°ã®äžã€)ã0.15ãããäžããããã§ãã
ç»åå€æã®åŠçé床ã«åœ±é¿ããèšå®é
ç®çŸ€ã§ãã
å
éšã§åå²ããŠåŠçãè¡ãéã®å¹
ïŒãã¯ã»ã«åäœïŒãæå®ããŸãã
æé©ãª(åŠçãæéã§çµãã)æ°å€ã®æ±ºãæ¹ã¯ãåå²ãµã€ãºãã®é
ã§èª¬æããŸãã
ã-------ãã§åºåãããŠããäžã®æ¹ã¯å
¥åãããç»åã®çžŠæšªãµã€ãºã®çŽæ°ã
äžã®æ¹ã¯ãcrop_size_list.txtãããèªã¿åºããæ±çšçãªåå²ãµã€ãºã§ãã
åå²ãµã€ãºã倧ããããå ŽåãèŠæ±ãããã¡ã¢ãªã®é(GPUã䜿ãå Žåã¯VRAMã®é)ãPCã§äœ¿çšã§ããã¡ã¢ãªãè¶
ããŠãœããã匷å¶çµäºããã®ã§æ°ãã€ããŠãã ããã
åŠçé床ã«ãããªãã«åœ±é¿ããã®ã§ãåãç»åãµã€ãºã®ç»åããã©ã«ãæå®ã§å€§éã«å€æãããšãã¯ãæé©ãªåå²ãµã€ãºã調ã¹ãŠããå€æããããšãããããããŸãã
ããŸãå€æŽããæ©äŒããªããšæãããåäœèšå®ããŸãšããèšå®çŸ€ã§ãã
åç
§ãã¿ã³ããã©ãã°ã¢ã³ãããããã§å
¥åãã¡ã€ã«ãæå®ããéã«èªåã§å€æãéå§ããã®ãèšå®ãè¡ããŸãã
exeã«å
¥åãã¡ã€ã«ãåŒæ°ã§äžããå Žåã§ã¯ãã®é
ç®ã®èšå®å
容ã¯åœ±é¿ããŸããã
* èªåã§éå§ããªã : ãã¡ã€ã«ãå
¥åããŠãèªåã§å€æãéå§ããŸãã
* ãã¡ã€ã«ã1ã€ã§ãå
¥åãããéå§ : ãã¡ã€ã«ã1ã€ã§ãå
¥åãããèªåã§å€æãéå§ããŸã
* ãã©ã«ããããã¯è€æ°ãã¡ã€ã«ãå
¥åãããéå§ : ãã©ã«ããè€æ°ãã¡ã€ã«ãå
¥åãããèªåã§å€æãéå§ããŸããåäœã®ç»åãã¡ã€ã«ãå€æããã®ã¯å€æèšå®ã®èª¿ç¯ãè¡ããšãã ãã ããšããæã«ã©ãã
å€æãè¡ãããã»ããµãŒãæå®ããŸãã
* CUDA(䜿ãããcuDNN) : CUDA(GPU)ã䜿ã£ãŠå€æãè¡ããŸã(cuDNNã䜿ããå Žåã¯cuDNNã䜿ãããŸã)
* CPU : CPUã®ã¿ã䜿ã£ãŠå€æãè¡ããŸã
ãã®èšå®ãONã®å Žåãç»åã®æžã蟌ã¿å
ã«ååã®ãã¡ã€ã«ãååšããå Žåã¯å€æãè¡ããŸããã
exeã«å
¥åãã¡ã€ã«ãåŒæ°ã§äžããå Žåã§ã®åäœãèšå®ããŸãã
* èµ·åæã«å€æãã : èµ·åæã«èªåã§å€æãéå§ããŸã
* æåæã«çµäºãã : å€æçµäºæã«å€±æããŠããªããã°èªåã§çµäºããŸã
GPUãè€æ°æããå Žåã«äœ¿çšããããã€ã¹çªå·ãæå®ã§ããŸããCPUã¢ãŒãæãç¡å¹ãªããã€ã¹çªå·ãæå®ããå Žåã¯ç¡èŠãããŸãã
å
¥åã®åç
§ãã¿ã³ãæŒããéã«æåã«è¡šç€ºããããã©ã«ããããã§èšå®ãããã©ã«ãã«åºå®ããŸãã
å€æããç»åã®åºåå
ãã©ã«ããããã§èšå®ãããã©ã«ãã«åºå®ããŸãã
ãŸããåºåã®åç
§ãã¿ã³ãæŒããéã«æåã«è¡šç€ºããããã©ã«ããããã§èšå®ãããã©ã«ãã«åºå®ããŸãã
ãã®ä»ã®èšå®é
ç®çŸ€ã§ãã
UIã®èšèªãèšå®ããŸãã
ååèµ·åæã¯PCã®èšèªèšå®ãšåãèšèªãéžã°ããŸãã(ååšããªãå Žåã¯è±èªã«ãªããŸã)
ãcuDNNãã§ãã¯ããã¿ã³ãæŒããšcuDNNã䜿ããã調ã¹ãããšãåºæ¥ãŸãã
cuDNNã䜿ããªãå Žåã¯çç±ã衚瀺ãããŸãã
ãå®è¡ããã¿ã³ãæŒããšå€æãå§ãŸããŸãã éäžã§ãã£ã³ã»ã«ãããå Žåã¯ããã£ã³ã»ã«ããã¿ã³ãæŒããŸãã ãã ããå®éã«åæ¢ãããŸã§ã¿ã€ã ã©ã°ããããŸãã ããã°ã¬ã¹ããŒã¯è€æ°æã®ç»åãå€æŽããéã®é²è¡åºŠåãã瀺ããŠããŸãã ãã°ã«æ®ãäºæ³æéã衚瀺ãããŸãããããã¯åãçžŠå¹ ãæšªå¹ ã®è€æ°ãã¡ã€ã«ãåŠçãããšãã®äºæ³ã§ãã ãªã®ã§ããã¡ã€ã«ã®å€§ããããã©ãã©ãªå Žåã¯åœ¹ã«ç«ã¡ãŸããããåŠçããç»åã2æ以äžã®æã¯ãäžæããšãã衚瀺ãããŸããã
ãwaifu2x-caffe-cui.exeãã¯ã³ãã³ãã©ã€ã³ããŒã«ã§ãã
ã³ãã³ãããã³ãã
ãç«ã¡äžãã次ã®ããã«ã³ãã³ããæã¡èŸŒã¿ã䜿çšããŠäžããã
以äžã®ã³ãã³ãã¯ã䜿ãæ¹ãç»é¢ã«åºåããŸãã
waifu2x-caffe-cui.exe --help
以äžã®ã³ãã³ãã¯ãç»åå€æãå®è¡ããã³ãã³ãã®äŸã§ãã
waifu2x-caffe-cui.exe -i mywaifu.png -m noise_scale --scale_ratio 1.6 --noise_level 2
以äžãå®è¡ãããšãmywaifu(noise_scale)(Level2)(x1.600000).png
ã«å€æçµæãä¿åãããŸãã
ã³ãã³ããªã¹ããåã³ãã³ãã®è©³çŽ°ã¯ã³ãã³ãã©ã€ã³ãªãã·ã§ã³(å ±é)ãšã³ãã³ãã©ã€ã³ãªãã·ã§ã³(CUIç)ã®é ããèªã¿ãã ããã
æ¬ãœããã§ã¯ã以äžã®ãªãã·ã§ã³ãæå®ããããšãåºæ¥ãŸãã GUIçã§ã¯å ¥åãã¡ã€ã«ä»¥å€ã®ã³ãã³ãã©ã€ã³ãªãã·ã§ã³ãæå®ããŠèµ·åããå ŽåãçŸåšãªãã·ã§ã³ã®ãã¡ã€ã«ä¿åãè¡ããŸããã ãŸããGUIçã§ã¯æå®ãããªãã£ããªãã·ã§ã³ã¯ååçµäºæã®ãªãã·ã§ã³ã䜿çšãããŸãã
input_fileããã©ã«ãã®å Žåã®ããã©ã«ãå
ã®å€æããç»åã®æ¡åŒµåãæå®ããŸãã
ããã©ã«ãå€ã¯`png:jpg:jpeg:tif:tiff:bmp:tga`ã§ãã
ãŸããåºåãæåã¯`:`ã§ãã
äŸ. png:jpg:jpeg:tif:tiff:bmp:tga
input_fileããã©ã«ãã®å Žåã®ãåºåç»åã®æ¡åŒµåãæå®ããŸãã
ããã©ã«ãå€ã¯`png`ã§ãã
å€æã¢ãŒããæå®ããŸããæå®ããªãã£ãå Žåã¯`noise_scale`ãéžæãããŸãã
* noise : ãã€ãºé€å»ãè¡ããŸã (æ£ç¢ºã«ã¯ããã€ãºé€å»çšã®ã¢ãã«ãçšããŠç»åå€æãè¡ããŸã)
* scale : æ¡å€§ãè¡ããŸã (æ£ç¢ºã«ã¯ãæ¢åã¢ã«ãŽãªãºã ã§æ¡å€§ããåŸã«ãæ¡å€§ç»åè£å®çšã®ã¢ãã«ãçšããŠç»åå€æãè¡ããŸã)
* noise_scale : ãã€ãºé€å»ãšæ¡å€§ãè¡ããŸã (ãã€ãºé€å»ãè¡ã£ãåŸã«ãåŒãç¶ãæ¡å€§åŠçãè¡ããŸã)
* auto_scale : æ¡å€§ãè¡ããŸããå
¥åãJPEGç»åã®å Žåã®ã¿ãã€ãºé€å»ãè¡ããŸã
ç»åãäœåã«æ¡å€§ããããæå®ããŸããããã©ã«ãå€ã¯`2.0`ã§ããã2.0å以å€ãæå®ã§ããŸãã
scale_widthãscale_heightãæå®ãããå Žåããã¡ããåªå
ãããŸãã
2.0以å€ã®æ°å€ãæå®ãããšã次ã®ãããªåŠçãè¡ããŸãã
* ãŸããæå®ãããåçãå¿
èŠååã«ã«ããŒããããã«ã2åæ¡å€§ãç¹°ãè¿ãè¡ããŸãã
* 2ã®çŽ¯ä¹ä»¥å€ã®æ°å€ãæå®ãããŠããå Žåã¯ãæå®åçã«ãªãããã«æ¡å€§ããç»åãç·åœ¢ãã£ã«ã¿ã§çž®å°ããŸãã
ç»åã®çžŠæšªæ¯ãç¶æãããŸãŸãæå®ããã暪å¹
ã«ãªãããã«æ¡å€§ããŸã(åäœã¯ãã¯ã»ã«)ã
scale_heightãšåæã«æå®ãããšãæå®ããã瞊暪å¹
ã«ãªãããã«ç»åãæ¡å€§ããŸãã
ç»åã®çžŠæšªæ¯ãç¶æãããŸãŸãæå®ããã瞊å¹
ã«ãªãããã«æ¡å€§ããŸã(åäœã¯ãã¯ã»ã«)ã
scale_widthãšåæã«æå®ãããšãæå®ããã瞊暪å¹
ã«ãªãããã«ç»åãæ¡å€§ããŸãã
ãã€ãºé€å»ã¬ãã«ãæå®ããŸãããã€ãºé€å»çšã®ã¢ãã«ã¯ã¬ãã«0ïœ3ã®ã¿çšæãããŠããã®ã§ã
0 ã 1 ã 2 ã 3 ãæå®ããŠäžããã
ããã©ã«ãå€ã¯`0`ã§ãã
åŠçã«äœ¿ãããã»ããµãŒãæå®ããŸããããã©ã«ãå€ã¯`gpu`ã§ãã
* cpu : CPUã䜿ã£ãŠå€æãè¡ããŸãã
* gpu : CUDA(GPU)ã䜿ã£ãŠå€æãè¡ããŸããWindowsçã§ã®ã¿ãcuDNNã䜿ãããªãcuDNNã䜿ããŸãã
* cudnn : cuDNNã䜿ã£ãŠå€æãè¡ããŸãã
åå²ãµã€ãºãæå®ããŸããããã©ã«ãå€ã¯`128`ã§ãã
å€æåŸã®ç»åã®ç»è³ªãèšå®ããŸããããã©ã«ãå€ã¯`-1`ã§ã
æå®ã§ããå€ãšæå³ã¯ãåºåæ¡åŒµåãã§èšå®ãã圢åŒã«ããç°ãªããŸãã
-1ã®å Žåã¯ãåç»å圢åŒã®ããã©ã«ãå€ã䜿ãããŸãã
å€æåŸã®ç»åã®1ãã£ã³ãã«ãããã®ãããæ°ãæå®ããŸããããã©ã«ãå€ã¯`8`ã§ãã
æå®ã§ããå€ã¯ãåºåæ¡åŒµåãã§èšå®ãã圢åŒã«ããç°ãªããŸãã
mini-batchãµã€ãºãæå®ããŸããããã©ã«ãå€ã¯`1`ã§ãã
mini-batchãµã€ãºã¯ç»åããåå²ãµã€ãºãã§åå²ãããããã¯ãåæã«åŠçããæ°ã®ããšã§ããäŸãã°`2`ãæå®ããå Žåã2ãããã¯ãã€å€æããŠãããŸãã
mini-batchãµã€ãºã倧ãããããšåå²ãµã€ãºã倧ãããããšã®åæ§ã«GPUã®äœ¿çšçãé«ããªããŸãããèšæž¬ããæãã ãšåå²ãµã€ãºã倧ããããæ¹ãå¹æãé«ãã§ãã
(äŸãã°åå²ãµã€ãºã`64`ãmini-batchãµã€ãºã`4`ã«ãããããåå²ãµã€ãºã`128`ãmini-batchãµã€ãºã`1`ã«ããæ¹ãåŠçãéãçµãã)
åŠçã«äœ¿ãGPUããã€ã¹çªå·ãæå®ããŸããããã©ã«ãå€ã¯`0`ã§ãã
GPUããã€ã¹çªå·ã¯0ããå§ãŸãããšã«æ³šæããŠãã ããã
åŠçã«GPUã䜿ããªãå Žåã¯ç¡èŠãããŸãã
ãŸããååšããªãGPUããã€ã¹çªå·ãæå®ããå Žåã¯ããã©ã«ãã®GPUã§å®è¡ãããŸãã
`1`ãæå®ãããšTTAã¢ãŒãã䜿çšããŸããããã©ã«ãå€ã¯`0`ã§ãã
ãã®ãªãã·ã§ã³ãæå®ãããåŸã®å
šãŠã®ãªãã·ã§ã³ãç¡èŠããŸãã
ã¹ã¯ãªããã»ããããã¡ã€ã«çšã§ãã
GUIçã§ã¯ãªãã·ã§ã³æå®ã«åœãŠã¯ãŸããªãã£ãåŒæ°ã¯å ¥åãã¡ã€ã«ãšããŠèªèãããŸãã å ¥åãã¡ã€ã«ã¯ãã¡ã€ã«ããã©ã«ããè€æ°ããã¡ã€ã«ãšãã©ã«ãåæã«æå®ã§ããŸãã
å€æãããç»åãä¿åãããã©ã«ããžã®ãã¹ãèšå®ããŸãã
æå®ããããã©ã«ãã®äžã«å€æåŸã®ãã¡ã€ã«ãä¿åããŸãã
å€æåŸã®ãã¡ã€ã«ã®åœåèŠåã¯GUIã§å
¥åãã¡ã€ã«ãèšå®ããæã«èªåã§æ±ºå®ãããåºåãã¡ã€ã«åãšåãã§ãã
æå®ãããªãã£ãå Žåãã²ãšã€ç®ã®å
¥åãã¡ã€ã«ãšåããã©ã«ãã«ä¿åãããŸãã
`1`ãæå®ãããšèµ·åæã«èªåã§å€æãéå§ããŸãã
`1`ãæå®ãããšãèµ·åæã«èªåã§å€æããå Žåã«å€æãæåãããšèªåã§çµäºããŸãã
`1`ãæå®ãããšãç»åã®æžã蟌ã¿å
ã«ååã®ãã¡ã€ã«ãååšããå Žåã¯å€æãè¡ããŸããã
-y <upconv_7_anime_style_art_rgb|upconv_7_photo|anime_style_art_rgb|photo|anime_style_art_y>, --model_type <upconv_7_anime_style_art_rgb|upconv_7_photo|anime_style_art_rgb|photo|anime_style_art_y>
䜿çšããã¢ãã«ãæå®ããŸãã
GUIã§ã®èšå®é
ç®ãã¢ãã«ããšä»¥äžã®ããã«å¯Ÿå¿ããŠããŸãã
* upconv_7_anime_style_art_rgb : 2次å
ã€ã©ã¹ã(UpRGBã¢ãã«)
* upconv_7_photo : åçã»ã¢ãã¡(UpPhotoã¢ãã«)
* anime_style_art_rgb : 2次å
ã€ã©ã¹ã(RGBã¢ãã«)
* photo : åçã»ã¢ãã¡(Photoã¢ãã«)
* anime_style_art_y : 2次å
ã€ã©ã¹ã(Yã¢ãã«)
ããŒãžã§ã³æ
å ±ãåºåããçµäºããŸãã
䜿ãæ¹ã衚瀺ããçµäºããŸãã
æ軜ã«äœ¿ãæ¹ã確èªãããæãªã©ã«ã©ããã
(å¿
é ) å€æããç»åãžã®ãã¹
ãã©ã«ããæå®ããå Žåããã®ãã©ã«ã以äžã®ç»åãã¡ã€ã«ãå
šãŠå€æããŠoutput_fileã§æå®ãããã©ã«ããžåºåããŸãã
å€æãããç»åãä¿åãããã¡ã€ã«ãžã®ãã¹
(input_fileããã©ã«ãã®å Žå)å€æãããç»åãä¿åãããã©ã«ããžã®ãã¹
(input_fileãç»åãã¡ã€ã«ã®å Žå)æ¡åŒµå(æåŸã®.pngãªã©)ã¯å¿
ãå
¥åããããã«ããŠäžããã
æå®ããªãã£ãå Žåã¯èªåã§ãã¡ã€ã«åã決å®ãããã®ãã¡ã€ã«ã«ä¿åããŸãã
ãã¡ã€ã«åã®æ±ºå®ã«ãŒã«ã¯ã
`[å
ã®ç»åãã¡ã€ã«å]``(ã¢ãã«å)``(ã¢ãŒãå)``(ãã€ãºé€å»ã¬ãã«(ãã€ãºé€å»ã¢ãŒãã®å Žå))``(æ¡å€§ç(æ¡å€§ã¢ãŒãã®å Žå))``(åºåãããæ°(8ããã以å€ã®å Žå))``.åºåæ¡åŒµå`
ã®ããã«ãªã£ãŠããŸãã
ä¿åãããå Žæã¯ãåºæ¬çã«ã¯å
¥åç»åãšåããã£ã¬ã¯ããªã«ãªããŸãã
ã¢ãã«ãæ ŒçŽãããŠãããã£ã¬ã¯ããªãžã®ãã¹ãæå®ããŸããããã©ã«ãå€ã¯`models/upconv_7_anime_style_art_rgb`ã§ãã
æšæºã§ã¯ä»¥äžã®ã¢ãã«ãä»å±ããŠããŸãã
* `models/anime_style_art_rgb` : RGBãã¹ãŠãå€æãã2次å
ç»åçšã¢ãã«
* `models/anime_style_art` : èŒåºŠã®ã¿ãå€æãã2次å
ç»åçšã¢ãã«
* `models/photo` : RGBãã¹ãŠãå€æããåçãã¢ãã¡ç»åçšã¢ãã«
* `models/upconv_7_anime_style_art_rgb` : anime_style_art_rgbããé«éãã€åç以äžã®ç»è³ªã§å€æããã¢ãã«
* `models/upconv_7_photo` : photoããé«éãã€åç以äžã®ç»è³ªã§å€æããã¢ãã«
* `models/ukbench` : æ§åŒã®åççšã¢ãã«(æ¡å€§ããã¢ãã«ã®ã¿ä»å±ããŠããŸãããã€ãºé€å»ã¯åºæ¥ãŸãã)
åºæ¬çã«ã¯æå®ããªããŠã倧äžå€«ã§ããããã©ã«ã以å€ã®ã¢ãã«ãèªäœã®ã¢ãã«ã䜿çšããæãªã©ã«æå®ããŠäžããã
åå²ãµã€ãº(暪å¹
)ãæå®ããŸããèšå®ããªãã£ãå Žåã¯crop_sizeã®å€ã䜿çšãããŸãã
å
¥åããç»åã®æšªå¹
ã®çŽæ°ãæå®ãããšããé«éã«å€æã§ããå¯èœæ§ããããŸãã
åå²ãµã€ãº(瞊å¹
)ãæå®ããŸããèšå®ããªãã£ãå Žåã¯crop_sizeã®å€ã䜿çšãããŸãã
å
¥åããç»åã®çžŠå¹
ã®çŽæ°ãæå®ãããšããé«éã«å€æã§ããŸå¯èœæ§ããããŸãã
waifu2x-caffe(waifu2xãã§ãã)ã¯ç»åãå€æããæã ç»åãäžå®ã®ãµã€ãºæ¯ã«åå²ããŠäžã€ãã€å€æãè¡ããæåŸã«çµåããŠäžæã®ç»åã«æ»ãããšããåŠçãããŠããŸãã åå²ãµã€ãº(crop_size)ãšã¯ããã®ç»åãåå²ããéã®å¹ ïŒãã¯ã»ã«åäœïŒã®äºã§ãã
CUDAã§å€æäžã§ãGPUã䜿ãåããŠããªãïŒGPUã®äœ¿çšçã100%è¿ããŸã§ãã£ãŠããªãïŒå Žåã ãã®æ°å€ã倧ããããããšã§åŠçãæ©ãçµããå¯èœæ§ããããŸããïŒGPUã䜿ãåãããšãåºæ¥ãæ§ã«ãªãããïŒ GPU-Zãªã©ã§GPU Load(GPU䜿çšç)ãšMemory Used(VRAM䜿çšç)ãèŠãªãã調ç¯ããŠã¿ãŠäžããã ãŸãã以äžã®æ§ãªç¹æ§ãããã®ã§åèã«ããŠäžããã
- å¿ ãããæ°å€ã倧ãããã°å€§ããã»ã©éããªãããã§ã¯ç¡ã
- åå²ãµã€ãºãç»åã®çžŠæšªãµã€ãºã®çŽæ°ïŒãããã¯å²ã£ããšãã«äœããå°ãªãæ°ïŒã ãšãç¡é§ã«æŒç®ããéãæžã£ãŠéããªãã (ãã®æ¡ä»¶ã«ããŸãåœãŠã¯ãŸããªãæ°å€ãæéã«ãªãã±ãŒã¹ããããããïŒ)
- æ°å€ã2åã«ããå Žåãçè«äžã¯äœ¿çšããã¡ã¢ãªéã¯4åã«ãªã(å®éã¯3ïœ4åãšãã£ããšãã)ã®ã§ãœãããèœã¡ãªãããã«æ³šæãç¹ã«CUDAã¯cuDNNã«æ¯ã¹ãŠã¡ã¢ãªã®æ¶è²»éããšãŠãå€ãã®ã§æ°ãã€ããããš
æ¬ãœããã§ã¯ã¢ã«ãã¡ãã£ã³ãã«ä»ãç»åã®æ¡å€§ã察å¿ããŠããŸãã ããããã¢ã«ãã¡ãã£ã³ãã«ãåäœã§æ¡å€§ããåŠçã«ãªã£ãŠãããããã¢ã«ãã¡ãã£ã³ãã«ä»ãç»åã®æ¡å€§ã¯ç¡ãå Žåãšæ¯ã¹ãŠããã2åã®æéããããã®ã§æ³šæããŠãã ããã ãã ããã¢ã«ãã¡ãã£ã³ãã«ãåè²ã§æ§æãããŠããå Žåã¯ãªãã®å Žåãšã»ãŒåãæéã§æ¡å€§ã§ããŸãã
Language files format is JSON. If you create new language file, add language setting to 'lang/LangList.txt'. 'lang/LangList.txt' format is TSV(Tab-Separated Values).
- LangName : Language name
- LangID : Primary language See MSDN
- SubLangID : Sublanguage See MSDN
- FileName : Language file name
ex.
- Japanese LangID : 0x11(LANG_JAPANESE), SubLangID : 0x01(SUBLANG_JAPANESE_JAPAN)
- English(US) LangID : 0x09(LANG_ENGLISH), SubLangID : 0x01(SUBLANG_ENGLISH_US)
- English(UK) LangID : 0x09(LANG_ENGLISH), SubLangID : 0x02(SUBLANG_ENGLISH_UK)
æ¬ãœããã¯ç¡ä¿èšŒã§ãã å©çšè ã®å€æã®äžã«äœ¿çšããŠäžããã å¶äœè ã¯ãããªã矩åãè² ããªããã®ãšããŸãã
ãªãªãžãã«ã®waifu2xãåã³ã¢ãã«ã®å¶äœãè¡ããMITã©ã€ã»ã³ã¹ã®äžã§å ¬éããŠäžãã£ã ultraistããã ãªãªãžãã«ã®waifu2xãå ã«waifu2x-converterãäœæããŠäžãã£ã ã¢ããŒãŽãã(READMEãLICENSE.txtã®æžãæ¹ãOpenCVã®äœ¿ãæ¹çããªãåèã«ãããŠããã ããŸãã) ã«ãæè¬ããŸãã ãŸããã¡ãã»ãŒãžãè±èš³ããŠãã ãã£ã @paul70078 ãããã¡ãã»ãŒãžãäžåœèª(ç°¡äœå)ã«ç¿»èš³ããŠãã ãã£ã @yoonhakcher ãããäžåœèª(ç°¡äœå)èš³ã®ãã«ãªã¯ãšã¹ããäžãã£ã @mzhboy ããã ã¡ãã»ãŒãžãéåœèªã«ç¿»èš³ããŠãã ãã£ã @kenin0726 ãããéåœèªèš³ã®æ¹åãææ¡ããŠãã ãã£ã @aruhirin ããã ã¡ãã»ãŒãžãäžåœèª(ç¹äœå)ã«ç¿»èš³ããŠãã ãã£ã @lizardon1995 ããã@yoonhakcher ããããã«ã³èªèš³ã®ãã«ãªã¯ãšã¹ããäžãã£ã @Scharynche ããããã©ã³ã¹èªèš³ã®ãã«ãªã¯ãšã¹ããäžãã£ã @Serized ããã GUIçã®ã¢ã€ã³ã³ãæäŸããŠãã ãã£ã JYUNYAãã ã«æè¬ããŸãã