Author: Not specified | Language: python |
Description: Not specified | Timestamp: 2017-09-19 00:29:06 +0000 |
View raw paste | Reply |
- def powerrating_transformation(image,gama, constant = 1):
- height, width = image.shape
- new_image = image.copy()
- for h in range(0,height):
- for w in range(0,width):
- new_image[h,w] = constant * ((image[h,w]/255) ** gama) * 255
- return new_image
View raw paste | Reply |