application_vnd.jupyter.stderr_output_2.png text_plain_output_1.png image_output_1.png
import cv2

import cv2

import matplotlib.pyplot as plt

import matplotlib.pyplot as plt

import os

import os

import random

import random
labels = [1, 2, 3]
count = 0
for l in labels:
    train_files = ['../input/train/Type_' + str(l) + '/' + f for f in os.listdir('../input/train/Type_' + str(l) + '/')]
    random_file = random.choice(train_files)
    im = cv2.imread(random_file)
    print('{} : {}'.format(random_file, im.shape))
    plt.subplot(1, 4, count + 1).set_title(labels[l])
    plt.imshow(cv2.cvtColor(im, cv2.COLOR_BGR2RGB))
    plt.axis('off')
    count += 1