Skip to content
This repository was archived by the owner on Jan 2, 2021. It is now read-only.

Commit 80d7b57

Browse files
committed
Prepare build scripts for merge and update README.
1 parent b706599 commit 80d7b57

File tree

3 files changed

+8
-8
lines changed

3 files changed

+8
-8
lines changed

README.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ Pre-trained models are provided in the GitHub releases. Training your own is a
6565
.. code:: bash
6666
6767
# Remove the model file as don't want to reload the data to fine-tune it.
68-
rm -f ne4x*.pkl.bz2
68+
rm -f ne?x*.pkl.bz2
6969
7070
# Pre-train the model using perceptual loss from paper [1] below.
7171
python3.4 enhance.py --train "data/*.jpg" --model custom --scales=2 --epochs=50 \
@@ -79,7 +79,7 @@ Pre-trained models are provided in the GitHub releases. Training your own is a
7979
--discriminator-size=64
8080
8181
# The newly trained model is output into this file...
82-
ls ne4x-custom-*.pkl.bz2
82+
ls ne?x-custom-*.pkl.bz2
8383
8484
8585
.. image:: docs/BankLobby_example.gif
@@ -109,14 +109,14 @@ Here's the simplest way you can call the script using ``docker``, assuming you'r
109109
alias enhance='function ne() { docker run --rm -v "$(pwd)/`dirname ${@:$#}`":/ne/input -it alexjc/neural-enhance ${@:1:$#-1} "input/`basename ${@:$#}`"; }; ne'
110110
111111
# Now run any of the examples above using this alias, without the `.py` extension.
112-
enhance --zoom=1 --model=small images/example.jpg
112+
enhance --zoom=1 --model=repair images/broken.jpg
113113
114114
**Multiple Images** — To enhance multiple images in a row (faster) from a folder or widlcard specification, make sure to quote the argument to the alias command:
115115

116116
.. code:: bash
117117
118118
# Process multiple images, make sure to quote the argument!
119-
enhance --zoom=2 --model=small "images/*.jpg"
119+
enhance --zoom=2 "images/*.jpg"
120120
121121
If you want to run on your NVIDIA GPU, you can instead change the alias to use the image ``alexjc/neural-enhance:gpu`` which comes with CUDA and CUDNN pre-installed. Then run it within `nvidia-docker <https://github.com/NVIDIA/nvidia-docker>`_ and it should use your physical hardware!
122122

docker-cpu.df

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,8 @@ RUN /opt/conda/bin/python3.5 -m pip install -q -r "requirements.txt"
2626
COPY enhance.py .
2727

2828
# Get a pre-trained neural networks, non-commercial & attribution.
29-
RUN wget -q "https://github.com/alexjc/neural-enhance/releases/download/v0.2/ne1x-small-0.2.pkl.bz2"
30-
RUN wget -q "https://github.com/alexjc/neural-enhance/releases/download/v0.2/ne2x-small-0.2.pkl.bz2"
29+
RUN wget -q "https://github.com/alexjc/neural-enhance/releases/download/v0.3/ne1x-photo-repair-0.3.pkl.bz2"
30+
RUN wget -q "https://github.com/alexjc/neural-enhance/releases/download/v0.3/ne2x-photo-default-0.3.pkl.bz2"
3131

3232
# Set an entrypoint to the main enhance.py script
3333
ENTRYPOINT ["/opt/conda/bin/python3.5", "enhance.py", "--device=cpu"]

docker-gpu.df

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,8 @@ RUN /opt/conda/bin/python3.5 -m pip install -q -r "requirements.txt"
2424
COPY enhance.py .
2525

2626
# Get a pre-trained neural networks, non-commercial & attribution.
27-
RUN wget -q "https://github.com/alexjc/neural-enhance/releases/download/v0.2/ne1x-small-0.2.pkl.bz2"
28-
RUN wget -q "https://github.com/alexjc/neural-enhance/releases/download/v0.2/ne2x-small-0.2.pkl.bz2"
27+
RUN wget -q "https://github.com/alexjc/neural-enhance/releases/download/v0.3/ne1x-photo-repair-0.3.pkl.bz2"
28+
RUN wget -q "https://github.com/alexjc/neural-enhance/releases/download/v0.3/ne2x-photo-default-0.3.pkl.bz2"
2929

3030
# Set an entrypoint to the main enhance.py script
3131
ENTRYPOINT ["/opt/conda/bin/python3.5", "enhance.py", "--device=gpu"]

0 commit comments

Comments
 (0)