Skip to content

Instantly share code, notes, and snippets.

@soumya997
Last active March 30, 2020 04:47
Show Gist options
  • Select an option

  • Save soumya997/db318c31774ce9e72baa60fad6b49cd1 to your computer and use it in GitHub Desktop.

Select an option

Save soumya997/db318c31774ce9e72baa60fad6b49cd1 to your computer and use it in GitHub Desktop.
make_train_data('Sunflower',FLOWER_SUNFLOWER_DIR) #####Loading Sunflower Data
fix_img = cv2.cvtColor(X[0],cv2.COLOR_BGR2RGB) ###########CONVERTING BGR COLOR SPACE INTO RGB COLOR SPACE #########
new_img_1 = fix_img.copy()
new_img_2 = fix_img.copy()
new_img_3 = fix_img.copy()
new_img_1[:,:,0] = 0 # making R channel zero ####For BLUE channel#####
new_img_1[:,:,1] = 0 #making G channel zero
new_img_2[:,:,1] = 0####For RED color Channel####
new_img_2[:,:,2] = 0
new_img_3[:,:,0] = 0###For GREEN Channel####
new_img_3[:,:,2] = 0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment