The algorithm of segmentation of brain tumors in MRI images is proposed. In the iteration of the computation algorithm, the outputs of the base neural networks are used as input data for a new trained neural network, which in the future serves as a unifier in order to distinguish scar tissue or non-affected tissue from tumor cells. This approach has a complex generalization, but, thus, it is possible to improve the quality of segmentation of the tumor by a combination of neural networks. The components of the algorithm are basic classifiers that will extract complex functions of the regularities (often implicit) from the data stream, and the unifier will become a classifier that aggregates these functions. At the aggregation level, the data is derived from the classifiers, and the aggregation of the single output. When iterating the computation algorithm, the outputs of the basic classifiers are used as input data for the new trained neural network, which later acts as a unifier. The key idea of the algorithm is that the individual result for each classifier is determined based on the models previously trained, then the voxel is classified as part of the tumor if at least one of the classifiers determines it as a tumor. Further, the result of segmentation of the basic classifiers falls on the input of the already trained meta-classifier, which makes the final decision regarding the voxel's belonging to the image to the tumor cells. In this case, a special algorithm is used. The pixel algorithm proposes to classify pixels in adjacent areas based on gray levels. This method uses local information - the values of the gray levels of adjacent pixels, or, global information - the total distribution of the gray levels of adjacent pixels. The gray levels reflect the intensity of the light in each pixel. At the level of input data and manipulations with them there is an input to the input of the neural network for training.