pfnet / PaintsChainer

line drawing colorization using chainer
https://paintschainer.preferred.tech/
MIT License
3.77k stars 556 forks source link

added windows OS detection and cv2 detection #48

Closed abbychau closed 7 years ago

abbychau commented 7 years ago

47

abbychau commented 7 years ago

fix time logger fail to log on ret_result

taizan commented 7 years ago

Thanks for pull request. Can I ask why the code bellow is required?

if os.name == 'nt':
    WK_VER_ROOT = r'C:\Program Files (x86)\Windows Kits\10\Include\10.0.14393.0'
    WK_INCLUDE = WK_VER_ROOT + r'\ucrt'
    WK_LIB_UM = WK_VER_ROOT + r'\um'
    WK_LIB_UCRT64 = WK_VER_ROOT + r'\ucrt\x64'

if os.path.isdir(WK_INCLUDE):
    os.environ['INCLUDE'] = WK_INCLUDE
 else:
     print('Include Path for Windows Kit not exists: ' + WK_INCLUDE)

 if os.path.isdir(WK_LIB_UM) and os.path.isdir(WK_LIB_UCRT64):
     os.environ['LIB'] = WK_LIB_UM + ';' + WK_LIB_UCRT64
 else:
     print('Lib Path for Windows Kit not exists: ' + WK_LIB_UM + ';' + WK_LIB_UCRT64)
abbychau commented 7 years ago

It is for running NVCC on windows.

https://github.com/pfnet/PaintsChainer/issues/14 https://devtalk.nvidia.com/default/topic/969047/cuda-8-vs2015-corecrt-h-error/?offset=7

taizan commented 7 years ago

I merged it thanks