Imported from https://github.com/WarrenGreen/srcnn