Initial commit
@@ -0,0 +1,89 @@
|
||||
# Byte-compiled / optimized / DLL files
|
||||
__pycache__/
|
||||
*.py[cod]
|
||||
*$py.class
|
||||
|
||||
# C extensions
|
||||
*.so
|
||||
|
||||
# Distribution / packaging
|
||||
.Python
|
||||
env/
|
||||
build/
|
||||
develop-eggs/
|
||||
dist/
|
||||
downloads/
|
||||
eggs/
|
||||
.eggs/
|
||||
lib/
|
||||
lib64/
|
||||
parts/
|
||||
sdist/
|
||||
var/
|
||||
*.egg-info/
|
||||
.installed.cfg
|
||||
*.egg
|
||||
|
||||
# PyInstaller
|
||||
# Usually these files are written by a python script from a template
|
||||
# before PyInstaller builds the exe, so as to inject date/other infos into it.
|
||||
*.manifest
|
||||
*.spec
|
||||
|
||||
# Installer logs
|
||||
pip-log.txt
|
||||
pip-delete-this-directory.txt
|
||||
|
||||
# Unit test / coverage reports
|
||||
htmlcov/
|
||||
.tox/
|
||||
.coverage
|
||||
.coverage.*
|
||||
.cache
|
||||
nosetests.xml
|
||||
coverage.xml
|
||||
*,cover
|
||||
.hypothesis/
|
||||
|
||||
# Translations
|
||||
*.mo
|
||||
*.pot
|
||||
|
||||
# Django stuff:
|
||||
*.log
|
||||
local_settings.py
|
||||
|
||||
# Flask stuff:
|
||||
instance/
|
||||
.webassets-cache
|
||||
|
||||
# Scrapy stuff:
|
||||
.scrapy
|
||||
|
||||
# Sphinx documentation
|
||||
docs/_build/
|
||||
|
||||
# PyBuilder
|
||||
target/
|
||||
|
||||
# IPython Notebook
|
||||
.ipynb_checkpoints
|
||||
|
||||
# pyenv
|
||||
.python-version
|
||||
|
||||
# celery beat schedule file
|
||||
celerybeat-schedule
|
||||
|
||||
# dotenv
|
||||
.env
|
||||
|
||||
# virtualenv
|
||||
venv/
|
||||
ENV/
|
||||
|
||||
# Spyder project settings
|
||||
.spyderproject
|
||||
|
||||
# Rope project settings
|
||||
.ropeproject
|
||||
@@ -0,0 +1,21 @@
|
||||
MIT License
|
||||
|
||||
Copyright (c) 2016 Drake Levy
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
SOFTWARE.
|
||||
@@ -0,0 +1,35 @@
|
||||
# FSRCNN-Tensorflow
|
||||
TensorFlow implementation of the Fast Super-Resolution Convolutional Neural Network (FSRCNN). This implements two models, FSRCNN which is more accurate and FSRCNN-s which is faster (approaches real-time performance). Based on this [project](http://mmlab.ie.cuhk.edu.hk/projects/FSRCNN.html).
|
||||
|
||||
## Prerequisites
|
||||
* TensorFlow
|
||||
* Scipy version > 0.18 ('mode' option from scipy.misc.imread function)
|
||||
* h5py
|
||||
* PIL
|
||||
|
||||
## Usage
|
||||
For training , `python main.py`
|
||||
Can specify epochs, learning rate, `python main.py --epochs 10`
|
||||
<br>
|
||||
For testing, `python main.py --is_train False`
|
||||
|
||||
To use FSCRNN-s over FSCRNN , `python main.py --fast True`
|
||||
|
||||
Includes script expand_data.py which scales and rotates all the images in your training set to expand your dataset just like in the paper
|
||||
`python expand_data.py Train`
|
||||
|
||||
## Result
|
||||
After training 15,000 epochs, I got similar super-resolved image to reference paper. Training time takes 12 hours 16 minutes and 1.41 seconds. My desktop performance is Intel I7-6700 CPU, GTX970, and 16GB RAM. Result images are shown below.<br><br>
|
||||
Original butterfly image:
|
||||
<br>
|
||||
Bicubic interpolated image:
|
||||
<br>
|
||||
Super-resolved image:
|
||||

|
||||
|
||||
## References
|
||||
* [tegg89/SRCNN-Tensorflow](https://github.com/tegg89/SRCNN-Tensorflow)
|
||||
<br>
|
||||
* [liliumao/Tensorflow-srcnn](https://github.com/liliumao/Tensorflow-srcnn)
|
||||
<br>
|
||||
* [carpedm20/DCGAN-tensorflow](https://github.com/carpedm20/DCGAN-tensorflow)
|
||||
|
After Width: | Height: | Size: 703 KiB |
|
After Width: | Height: | Size: 1.2 MiB |
|
After Width: | Height: | Size: 257 KiB |
|
After Width: | Height: | Size: 297 KiB |
|
After Width: | Height: | Size: 265 KiB |
|
After Width: | Height: | Size: 223 KiB |
|
After Width: | Height: | Size: 530 KiB |
|
After Width: | Height: | Size: 297 KiB |
|
After Width: | Height: | Size: 768 KiB |
|
After Width: | Height: | Size: 768 KiB |
|
After Width: | Height: | Size: 1.1 MiB |
|
After Width: | Height: | Size: 768 KiB |
|
After Width: | Height: | Size: 1017 KiB |
|
After Width: | Height: | Size: 672 KiB |
|
After Width: | Height: | Size: 768 KiB |
|
After Width: | Height: | Size: 243 KiB |
|
After Width: | Height: | Size: 192 KiB |
|
After Width: | Height: | Size: 230 KiB |
|
After Width: | Height: | Size: 230 KiB |
|
After Width: | Height: | Size: 102 KiB |
|
After Width: | Height: | Size: 54 KiB |
|
After Width: | Height: | Size: 116 KiB |
|
After Width: | Height: | Size: 40 KiB |
|
After Width: | Height: | Size: 99 KiB |
|
After Width: | Height: | Size: 75 KiB |
|
After Width: | Height: | Size: 124 KiB |
|
After Width: | Height: | Size: 82 KiB |
|
After Width: | Height: | Size: 68 KiB |
|
After Width: | Height: | Size: 54 KiB |
|
After Width: | Height: | Size: 94 KiB |
|
After Width: | Height: | Size: 90 KiB |
|
After Width: | Height: | Size: 18 KiB |
|
After Width: | Height: | Size: 40 KiB |
|
After Width: | Height: | Size: 58 KiB |
|
After Width: | Height: | Size: 46 KiB |
|
After Width: | Height: | Size: 36 KiB |
|
After Width: | Height: | Size: 122 KiB |
|
After Width: | Height: | Size: 57 KiB |
|
After Width: | Height: | Size: 123 KiB |
|
After Width: | Height: | Size: 90 KiB |
|
After Width: | Height: | Size: 86 KiB |
|
After Width: | Height: | Size: 87 KiB |
|
After Width: | Height: | Size: 60 KiB |
|
After Width: | Height: | Size: 99 KiB |
|
After Width: | Height: | Size: 85 KiB |
|
After Width: | Height: | Size: 80 KiB |
|
After Width: | Height: | Size: 65 KiB |
|
After Width: | Height: | Size: 122 KiB |
|
After Width: | Height: | Size: 111 KiB |
|
After Width: | Height: | Size: 305 KiB |
|
After Width: | Height: | Size: 195 KiB |
|
After Width: | Height: | Size: 193 KiB |
|
After Width: | Height: | Size: 126 KiB |
|
After Width: | Height: | Size: 195 KiB |
|
After Width: | Height: | Size: 198 KiB |
|
After Width: | Height: | Size: 154 KiB |
|
After Width: | Height: | Size: 113 KiB |
|
After Width: | Height: | Size: 117 KiB |
|
After Width: | Height: | Size: 347 KiB |
|
After Width: | Height: | Size: 140 KiB |
|
After Width: | Height: | Size: 132 KiB |
|
After Width: | Height: | Size: 237 KiB |
|
After Width: | Height: | Size: 69 KiB |
|
After Width: | Height: | Size: 254 KiB |
|
After Width: | Height: | Size: 246 KiB |
|
After Width: | Height: | Size: 202 KiB |
|
After Width: | Height: | Size: 232 KiB |
|
After Width: | Height: | Size: 150 KiB |
|
After Width: | Height: | Size: 169 KiB |
|
After Width: | Height: | Size: 96 KiB |
|
After Width: | Height: | Size: 110 KiB |
|
After Width: | Height: | Size: 130 KiB |
|
After Width: | Height: | Size: 209 KiB |
|
After Width: | Height: | Size: 88 KiB |
|
After Width: | Height: | Size: 138 KiB |
|
After Width: | Height: | Size: 109 KiB |
|
After Width: | Height: | Size: 115 KiB |
|
After Width: | Height: | Size: 145 KiB |
|
After Width: | Height: | Size: 115 KiB |
|
After Width: | Height: | Size: 111 KiB |
|
After Width: | Height: | Size: 229 KiB |
|
After Width: | Height: | Size: 82 KiB |
|
After Width: | Height: | Size: 100 KiB |
|
After Width: | Height: | Size: 37 KiB |
|
After Width: | Height: | Size: 398 KiB |
|
After Width: | Height: | Size: 236 KiB |
|
After Width: | Height: | Size: 335 KiB |
|
After Width: | Height: | Size: 286 KiB |
|
After Width: | Height: | Size: 150 KiB |
|
After Width: | Height: | Size: 212 KiB |
|
After Width: | Height: | Size: 172 KiB |
|
After Width: | Height: | Size: 233 KiB |
|
After Width: | Height: | Size: 94 KiB |
|
After Width: | Height: | Size: 186 KiB |
|
After Width: | Height: | Size: 448 KiB |
|
After Width: | Height: | Size: 260 KiB |
|
After Width: | Height: | Size: 374 KiB |