Imported from https://github.com/alexjc/neural-enhance