diff --git a/enhance.py b/enhance.py index becb851..f5d1dba 100755 --- a/enhance.py +++ b/enhance.py @@ -384,6 +384,7 @@ class Model(object): def load_model(self): if not os.path.exists(self.get_filename(absolute=True)): if args.train: return {}, {} + print(self.get_filename()) error("Model file with pre-trained convolution layers not found. Download it here...", "https://github.com/alexjc/neural-enhance/releases/download/v%s/%s"%(__version__, self.get_filename())) print(' - Loaded file `{}` with trained model.'.format(self.get_filename())) diff --git a/images/car.jpg b/images/car.jpg new file mode 100644 index 0000000..2205fb3 Binary files /dev/null and b/images/car.jpg differ diff --git a/images/person.jpg b/images/person.jpg new file mode 100644 index 0000000..52e2629 Binary files /dev/null and b/images/person.jpg differ diff --git a/libgpuarray b/libgpuarray new file mode 160000 index 0000000..9cec614 --- /dev/null +++ b/libgpuarray @@ -0,0 +1 @@ +Subproject commit 9cec61435c11cf2ffcf7c480c2d524772585c47f diff --git a/pyvenv/Scripts/Activate.ps1 b/pyvenv/Scripts/Activate.ps1 new file mode 100644 index 0000000..c1e8fba --- /dev/null +++ b/pyvenv/Scripts/Activate.ps1 @@ -0,0 +1,51 @@ +function global:deactivate ([switch]$NonDestructive) { + # Revert to original values + if (Test-Path function:_OLD_VIRTUAL_PROMPT) { + copy-item function:_OLD_VIRTUAL_PROMPT function:prompt + remove-item function:_OLD_VIRTUAL_PROMPT + } + + if (Test-Path env:_OLD_VIRTUAL_PYTHONHOME) { + copy-item env:_OLD_VIRTUAL_PYTHONHOME env:PYTHONHOME + remove-item env:_OLD_VIRTUAL_PYTHONHOME + } + + if (Test-Path env:_OLD_VIRTUAL_PATH) { + copy-item env:_OLD_VIRTUAL_PATH env:PATH + remove-item env:_OLD_VIRTUAL_PATH + } + + if (Test-Path env:VIRTUAL_ENV) { + remove-item env:VIRTUAL_ENV + } + + if (!$NonDestructive) { + # Self destruct! + remove-item function:deactivate + } +} + +deactivate -nondestructive + +$env:VIRTUAL_ENV="D:\Programming\Workspace\Neural enhance\neural-enhance\pyvenv" + +if (! $env:VIRTUAL_ENV_DISABLE_PROMPT) { + # Set the prompt to include the env name + # Make sure _OLD_VIRTUAL_PROMPT is global + function global:_OLD_VIRTUAL_PROMPT {""} + copy-item function:prompt function:_OLD_VIRTUAL_PROMPT + function global:prompt { + Write-Host -NoNewline -ForegroundColor Green '(pyvenv) ' + _OLD_VIRTUAL_PROMPT + } +} + +# Clear PYTHONHOME +if (Test-Path env:PYTHONHOME) { + copy-item env:PYTHONHOME env:_OLD_VIRTUAL_PYTHONHOME + remove-item env:PYTHONHOME +} + +# Add the venv to the PATH +copy-item env:PATH env:_OLD_VIRTUAL_PATH +$env:PATH = "$env:VIRTUAL_ENV\Scripts;$env:PATH" diff --git a/pyvenv/Scripts/activate b/pyvenv/Scripts/activate new file mode 100644 index 0000000..37959cb --- /dev/null +++ b/pyvenv/Scripts/activate @@ -0,0 +1,76 @@ +# This file must be used with "source bin/activate" *from bash* +# you cannot run it directly + +deactivate () { + # reset old environment variables + if [ -n "${_OLD_VIRTUAL_PATH:-}" ] ; then + PATH="${_OLD_VIRTUAL_PATH:-}" + export PATH + unset _OLD_VIRTUAL_PATH + fi + if [ -n "${_OLD_VIRTUAL_PYTHONHOME:-}" ] ; then + PYTHONHOME="${_OLD_VIRTUAL_PYTHONHOME:-}" + export PYTHONHOME + unset _OLD_VIRTUAL_PYTHONHOME + fi + + # This should detect bash and zsh, which have a hash command that must + # be called to get it to forget past commands. Without forgetting + # past commands the $PATH changes we made may not be respected + if [ -n "${BASH:-}" -o -n "${ZSH_VERSION:-}" ] ; then + hash -r + fi + + if [ -n "${_OLD_VIRTUAL_PS1:-}" ] ; then + PS1="${_OLD_VIRTUAL_PS1:-}" + export PS1 + unset _OLD_VIRTUAL_PS1 + fi + + unset VIRTUAL_ENV + if [ ! "$1" = "nondestructive" ] ; then + # Self destruct! + unset -f deactivate + fi +} + +# unset irrelevant variables +deactivate nondestructive + +VIRTUAL_ENV="D:\Programming\Workspace\Neural enhance\neural-enhance\pyvenv" +export VIRTUAL_ENV + +_OLD_VIRTUAL_PATH="$PATH" +PATH="$VIRTUAL_ENV/Scripts:$PATH" +export PATH + +# unset PYTHONHOME if set +# this will fail if PYTHONHOME is set to the empty string (which is bad anyway) +# could use `if (set -u; : $PYTHONHOME) ;` in bash +if [ -n "${PYTHONHOME:-}" ] ; then + _OLD_VIRTUAL_PYTHONHOME="${PYTHONHOME:-}" + unset PYTHONHOME +fi + +if [ -z "${VIRTUAL_ENV_DISABLE_PROMPT:-}" ] ; then + _OLD_VIRTUAL_PS1="${PS1:-}" + if [ "x(pyvenv) " != x ] ; then + PS1="(pyvenv) ${PS1:-}" + else + if [ "`basename \"$VIRTUAL_ENV\"`" = "__" ] ; then + # special case for Aspen magic directories + # see http://www.zetadev.com/software/aspen/ + PS1="[`basename \`dirname \"$VIRTUAL_ENV\"\``] $PS1" + else + PS1="(`basename \"$VIRTUAL_ENV\"`)$PS1" + fi + fi + export PS1 +fi + +# This should detect bash and zsh, which have a hash command that must +# be called to get it to forget past commands. Without forgetting +# past commands the $PATH changes we made may not be respected +if [ -n "${BASH:-}" -o -n "${ZSH_VERSION:-}" ] ; then + hash -r +fi diff --git a/pyvenv/Scripts/activate.bat b/pyvenv/Scripts/activate.bat new file mode 100644 index 0000000..c96840d --- /dev/null +++ b/pyvenv/Scripts/activate.bat @@ -0,0 +1,45 @@ +@echo off + +rem This file is UTF-8 encoded, so we need to update the current code page while executing it +for /f "tokens=2 delims=:" %%a in ('"%SystemRoot%\System32\chcp.com"') do ( + set "_OLD_CODEPAGE=%%a" +) +if defined _OLD_CODEPAGE ( + "%SystemRoot%\System32\chcp.com" 65001 > nul +) + +set "VIRTUAL_ENV=D:\Programming\Workspace\Neural enhance\neural-enhance\pyvenv" + +if not defined PROMPT ( + set "PROMPT=$P$G" +) + +if defined _OLD_VIRTUAL_PROMPT ( + set "PROMPT=%_OLD_VIRTUAL_PROMPT%" +) + +if defined _OLD_VIRTUAL_PYTHONHOME ( + set "PYTHONHOME=%_OLD_VIRTUAL_PYTHONHOME%" +) + +set "_OLD_VIRTUAL_PROMPT=%PROMPT%" +set "PROMPT=(pyvenv) %PROMPT%" + +if defined PYTHONHOME ( + set "_OLD_VIRTUAL_PYTHONHOME=%PYTHONHOME%" + set PYTHONHOME= +) + +if defined _OLD_VIRTUAL_PATH ( + set "PATH=%_OLD_VIRTUAL_PATH%" +) else ( + set "_OLD_VIRTUAL_PATH=%PATH%" +) + +set "PATH=%VIRTUAL_ENV%\Scripts;%PATH%" + +:END +if defined _OLD_CODEPAGE ( + "%SystemRoot%\System32\chcp.com" %_OLD_CODEPAGE% > nul + set "_OLD_CODEPAGE=" +) diff --git a/pyvenv/Scripts/deactivate.bat b/pyvenv/Scripts/deactivate.bat new file mode 100644 index 0000000..1205c61 --- /dev/null +++ b/pyvenv/Scripts/deactivate.bat @@ -0,0 +1,21 @@ +@echo off + +if defined _OLD_VIRTUAL_PROMPT ( + set "PROMPT=%_OLD_VIRTUAL_PROMPT%" +) +set _OLD_VIRTUAL_PROMPT= + +if defined _OLD_VIRTUAL_PYTHONHOME ( + set "PYTHONHOME=%_OLD_VIRTUAL_PYTHONHOME%" + set _OLD_VIRTUAL_PYTHONHOME= +) + +if defined _OLD_VIRTUAL_PATH ( + set "PATH=%_OLD_VIRTUAL_PATH%" +) + +set _OLD_VIRTUAL_PATH= + +set VIRTUAL_ENV= + +:END diff --git a/pyvenv/Scripts/easy_install-3.7.exe b/pyvenv/Scripts/easy_install-3.7.exe new file mode 100644 index 0000000..e42db6c Binary files /dev/null and b/pyvenv/Scripts/easy_install-3.7.exe differ diff --git a/pyvenv/Scripts/easy_install.exe b/pyvenv/Scripts/easy_install.exe new file mode 100644 index 0000000..e42db6c Binary files /dev/null and b/pyvenv/Scripts/easy_install.exe differ diff --git a/pyvenv/Scripts/pip.exe b/pyvenv/Scripts/pip.exe new file mode 100644 index 0000000..cfe2b16 Binary files /dev/null and b/pyvenv/Scripts/pip.exe differ diff --git a/pyvenv/Scripts/pip3.7.exe b/pyvenv/Scripts/pip3.7.exe new file mode 100644 index 0000000..cfe2b16 Binary files /dev/null and b/pyvenv/Scripts/pip3.7.exe differ diff --git a/pyvenv/Scripts/pip3.exe b/pyvenv/Scripts/pip3.exe new file mode 100644 index 0000000..cfe2b16 Binary files /dev/null and b/pyvenv/Scripts/pip3.exe differ diff --git a/pyvenv/Scripts/python.exe b/pyvenv/Scripts/python.exe new file mode 100644 index 0000000..89c00b0 Binary files /dev/null and b/pyvenv/Scripts/python.exe differ diff --git a/pyvenv/Scripts/pythonw.exe b/pyvenv/Scripts/pythonw.exe new file mode 100644 index 0000000..84b1f79 Binary files /dev/null and b/pyvenv/Scripts/pythonw.exe differ diff --git a/pyvenv/pyvenv.cfg b/pyvenv/pyvenv.cfg new file mode 100644 index 0000000..f636df2 --- /dev/null +++ b/pyvenv/pyvenv.cfg @@ -0,0 +1,3 @@ +home = C:\Python37 +include-system-site-packages = true +version = 3.7.2