Аннотация:Automatic layers recognition of the wall of the stomach and colon on whole slide images is an extremely urgent task in digital pathology as it can be used for automatic determining the depth of invasion of the digestive tract tumors. In this paper we propose a new CNN-based method of automatic tissue type recognition on whole slide histological images. We also describe an effective pipeline of training that uses 2 different training datasets. The proposed method of automatic tissue type recognition achieved 0.929 accuracy and 0.903 balanced accuracy on CRC-VAL-HE-7K dataset for 9-types classification and 0.98 accuracy and 0.926 balanced accuracy on the test subset of whole slide images from PATH-DT-MSU dataset for 5-types classification. The developed method makes it possible to classify the areas corresponding to the gastric own mucous glands in the lamina propria and also to distinguish the tubular structures of a highly differentiated gastric adenocarcinoma with normal glands.Keywords: Deep Learning, Image Segmentation, Histology, Pathology, Whole Slide Images, Tissue Recognition